-
Notifications
You must be signed in to change notification settings - Fork 235
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[BUG] The watch
feature in 0.13.1 is now not working
#232
Comments
Hello there. Do you mind sharing your configuration setup. Depending on your configuration, the "current dir" may not be one of the dirs which Trunk even attempts to watch. |
Hi! I have a similar setup and this happens to me too. I'm trying to serve the todomvc example from
I've also tried this with |
My |
The correct command should be simply cd examples/todomvc
trunk serve Also by default, trunk only watches files inside the current working directory, so changing yew source will not trigger a build. |
Hi, @lukechu10! Yeah, my first attempt was to just run it with |
Trunk does watch recursively: https://github.com/thedodd/trunk/blob/v0.13.1/src/watch.rs#L141 So, this is interesting because if I checkout yewstack/yew on master, cd into @teenjuna @deities-online && @teenjuna what are you using to make modifications to the files? Mind performing the following experiment for me:
Keep me posted on that experiment. I am trying to find out why things are behaving differently for you in this case. |
@thedodd, Here is a demonstration: Screen.Recording.2021-08-25.at.21.46.23.mov |
It seems to be caused by the editor(neovim).
trunk re-build.
nothing happen.
trunk re-build. Note: my neovim version is same as @teenjuna 's. |
Maybe this is related to #238 |
As a temporary solution one can run
Seems like |
Here is the difference between filesystem events with
|
I'm running into this issue with neovim as well. However, what's odd is that in my case every now and then |
@danielnehrig noted in #331 that the |
Same issue here pretty much,
Hope this helps to resolve this, if you need more details feel free to ask Edit: |
@JulianusIV I can confirm the same behavior on the exact same system. |
Some platforms don't support precise notification kinds and instead report `All` as an event kind. This is what the notification system reports when it doesn't know what else to report. It's also the kind that's used in "imprecise" mode. This fixes watching on Windows, and may address issues reported in trunk-rs#232. Signed-off-by: Sean Cross <sean@xobs.io>
I noticed on Windows that watch events were frequently reported as I created a patch that adds this as an acceptable type. It fixes watching for me on Windows, and I would be interested to see if it improves things on other platforms. |
The PR is #620 |
I think it's worth mentioning there had been a number of fixes on |
I encountered the same problem on windows with vscode, and switching to trunk-ng solved the problem for me. Thank you ctron :) |
i tested it with your solution,it's correct! |
This fix got merged to trunk now too. It should be part of the next trunk release. |
Released with trunk 0.18.0 |
the
watch
feature in 0.13.1 is now not working. OS: MacOS BigSurtrunk watch
trunk serve
are not be notified while files under current dir has been modified.Source Code Version:
The text was updated successfully, but these errors were encountered: