-
Notifications
You must be signed in to change notification settings - Fork 128
Weird behaviour with Angular #74
Comments
Hmm very weird. Only thing I can think of is that maybe |
I just tried it, but it doesn't change anything, and even if it did, it would be weird that it's only needed in this prebuilt right? Something I did notice though is that this seems to be only happening on my machine, on an iMac (El Capitan too) this does not happen, and electron-prebuilt does its job. I already thought it could be related to broken npm packages, but I removed everything and installed everything again, no change. |
The only difference between running your app with electron-packager vs electron-prebuilt is that prebuilt spawns the electron process from the command line, and packager runs it using a mac application. There will be some differences such as your PATH and
If you can reproduce this by running electron yourself from the CLI then its probably some weird electron bug |
I opened electron-prebuilts Electron executable using the CLI, and its the exact same behaviour. Again, if I download the prebuilt from the releases page and open it from the CLI (the exact same way), it does work. However, I noticed that if I copy the Electron.app from electron-prebuilt to somewhere else, like my Downloads folder, it does not show this behaviour, so it seems like it makes a difference in where it runs. |
@maxrimue can you try one last thing:
im curious if theres a difference between 1 and 2 (it might be related to how i'm unzipping in electron-prebuilt) |
Well, no. Both behave weird now. Another Electron.app prebuilt I downloaded and placed in /Applications works though, and zips I download always get unzipped by Safari when downloading, so it's not the zipping that's not working, as two prebuilts that behave differently were unzipped the same way. |
Got exactly the same problem here. Initially I thought my code was bad, but I also tried the angular-material demo app (material-start) and it behaves just as silly in electron. As soon as I start electron from the CLI, there is some strange behaviour. But if I drag and drop my project folder into the Electron window, the app is fine. EDIT: Did you try running "electron my-app" from outside the project folder (Not like "electron ."). This seems to fix my problems. |
@Shigawire While your problem does sound the same, I cannot fix mine with your solution, perhaps these are just different results of the same bug? Can you provide some information what software you use, like which prebuilt and which OS? |
@maxrimue Sorry for the late reply. I am running OSX 10.11.1, Electron Prebuilt 0.36.2. |
I'm having the exact issue. I simply use this project and added a button to open a dialog on it : http://develephant.github.io/Amy/ |
Hi, I'm having the same issue. It's not reproducable:
it only occurs when using electron-prebuilt on osx (10.11.3) - it's also the same for electron-prebuilt 0.36.11 & 0.37.2.
|
I believe this bug has been solved with electron-prebuilt 1.1.1 |
@lincolnwan Unfortunately, this bug is still present in electron-prebuilt@1.2.1 for me. Here is an example electron app I've put together to test whether someone is affected by this bug: |
@maxrimue maybe my guess was too naive.. I used to be affected by this bug but just suddenly everything runs smooth, no mater on 1.1.1 or 1.2.1. I have no idea what did the magic that fixed it. |
I just tried out @lincolnwan's repo and was unable to reproduce the issue. See a short video here: https://cloudup.com/cc1zgZanP8V I suspect this was fixed in a recent version of Electron or its Chromium dependency. Gonna close this out, but if anyone is still having problems, feel free to comment. |
@zeke Unfortunately, I'm still having this problem. I too created a demo repo to test for this here, it uses the most current Electron and Angular 1 deps and for me still shows the weird behaviour. It doesn't however surprise me that it didn't occur for you, it always seemed like something that would only appear on a few machines. |
@maxrimue so you only experience this issue when launching your app directly with
Are you able to capture a CPU profile in the dev tools and see what is happening during this lag? |
@kevinsawicki Exactly. I also just went ahead and upgraded Electron and Angular1 in my aforementioned demo repository and this problem still occurs. I captured a CPU profile using the DevTools and it seems like the "gap" in which nothing happens Electron is in "idle", at least that's what it says. You can find the profile here. On the left, you can see the stack that opens the dialog and on the right the stack that closes it, in between mostly just "idle": |
+1 same problem with angular and angular material and dialog. It's fine in the build version. |
The electron-prebuilt repo is being retired and its code has been moved into the electron/electron repo. For the sake of historical transparency, we will leave GitHub Issues enabled on this repository, but if you are still affected by the issue reported here, please open a new issue on electron/electron repo and reference this issue from it so people can get the full context. The electron repository has a large and active contributor community, so your issue is more likely to get the attention it deserves there. Thanks! |
I've been encountering a weird problem. I've written a little Angular + Material Design script that does some animations here and there. When I run that script in Firefox, Chrome and Safari, everything works. Even when I compile an Electron app with the Angular Script using electron-packager, or run it in a prebuilt provided on GitHub Releases page for Electron, it works. However, if I install electron-prebuilt from npm and run the script with it, it shows weird behaviour. For example, a dialog opens correctly, but takes really long to close, and after that, the interface remains unusable for some time, it's as if Angular is waiting and blocking interaction.
Here's a video showing the behaviour in Chrome:
https://drive.google.com/file/d/0B3S33WrzEUwMV3ladTFkc1RIYWc/view?usp=sharing
And here's one showing it in Electron using electron-prebuilt:
https://drive.google.com/file/d/0B3S33WrzEUwMZnREdHJiUE0wV1k/view?usp=sharing
The script is the exact same, it does not have bugs, and several electron-prebuilt versions were tested, all behave the exact same. OS is El Capitan, computer is MacBook Pro 13" early 15, most recent versions of Chrome, electron-prebuilt and Angular + Dependencies were used.
The text was updated successfully, but these errors were encountered: