-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Can't return a View on OSX when npm or bower packages have been installed #2348
Comments
@adriaanp Could you please share with us your project code so that we investigate? |
Looks like a Mono issue. |
Sure here is the repo: https://github.com/adriaanp/gholfreg If you just do "dnu restore" and "dnx src kestrel" you should be able to hit the home page. if you do "npm install" to install gulp etc. and then "gulp " to install bower packages. Then I'm getting the exception above, but hitting the other Test actions does not throw the exception. |
It is a mono issue. export MONO_MANAGED_WATCHER=false and see if it works |
It's a known issue on Mono: http://www.mono-project.com/docs/about-mono/releases/3.12.0/ |
yes the MONO_MANAGED_WATCHER works. Just for interest sake why is node_modules and wwwroot stuff being watched ? |
No idea, I don't think anybody debugged it. |
@pranavkm Please investigate why these files are being watched. |
Just another note loading a view takes a considerable amount of time on first load, but not for actions that returns json. |
This is still an issue for me, I have to export for it to load ok. |
@martinalderson when you say ("I have to export") do you mean the known Are you seeing any issues with that workaround in place? |
Yes. It means I have to restart the server (it can't watch for file changes). Mono core bug: https://bugzilla.xamarin.com/show_bug.cgi?id=28693 They are looking for better repro, though doing some more digging looks like 4.1.0 will fix it. |
@sornaks Could you please work to create a better repro for this Mono issue and add it to the bugzilla issue?: https://bugzilla.xamarin.com/show_bug.cgi?id=28693 |
Seeing the same issue as @adriaanp. Everything will run fine until I perform |
@danroth27 I added some additional reproduction information to Issue 508 on the aspnet project. |
This is tracked as an external issue here - https://github.com/aspnet/External/issues/2. So closing this. |
That page 404s for me. Is this solved in Mono 4.2? |
So, looks like it is fixed in Mono 4.2.0 from homebrew on OS X. I can now make changes .cshtml files and refresh the browser and changes immediately appear. However, changing .cs files requires a full restart of the kestrel server. I thought it would automatically watch files and rebuild in ASP.NET5? |
Kestrel doesn't auto restart at this point. Currently auto restart is just supported in VS. |
Is there a timescale for that support in Kestrel? |
Not sure why this is marked closed, it is definitely still an issue. I'm using: VS Code 0.10.1 (latest) I created a new web site using "yo aspnet" (MVC, no identity/auth) and dnx ran perfectly. Then I installed the ESLint extension ("npm install eslint" from my workspace folder). This created a new "node_modules" folder with over 2800 files. Since then, dnx throws the "kqueue() FileSystemWatcher has reached the maximum number of files to watch" exception on every request. The MONO_MANAGED_WATCHER workaround did fix it, but of course broke my ability to quickly edit and reload. |
Having this issue too with The /cc @davidfowl |
Having the same issue using Mono 4.2.1 and dnx-mono-1.0.0-rc1-update1 Export env variable makes it work. |
The /cc @davidfowl |
Definitely still an issue with mono 4.2.1 as the workaround is needed with that version. |
Mono 4.2.1 still has this issue, that's for sure.
I just downloaded the latest mdk alpha from the Mono download archive and the issue is now gone!
Output from
|
@anderssonjohan I updated mono using the latest mdk alpha package and that fixed it for me as well. Thanks! |
Running on Mono and OSX I'm getting the following when returning a View from my controller action.
If I return an object or a string, then it works fine.
I'm using npm to install gulp and bower to install bower components, when removing the npm installed and bower installed files then the exception is not thrown, meaning that somehow these files get used / watched in a way that does not make sense to be watched?
I've played with and increase the ulimit setting for max files to open 1000000 and still get the same exception.
On Windows everything works fine.
The text was updated successfully, but these errors were encountered: