-
Notifications
You must be signed in to change notification settings - Fork 28
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
Watch mode not always working #156
Comments
Hello @kevin-st, Thanks for reporting the issue! I'll try to investigate with the repositories you provided me, so please yes add me to the private one 👍 Also, did you notice anything else not working as expected on the watcher or any improvements that would improve the DX? If that's the case I could probably tackle both the bug + the improvements if you have some :) Thanks! |
I added you to the repository. It's a pretty old one which is no longer being maintained, so you may encounter quite a lot of warnings when installing everything. The application is setup with Frontity, a React framework which used WordPress as a headless CMS. It was pretty good, but the Frontity team no longer works on the framework itself; they have moved onto working on the core of Wordpress directly. That reminds me though - I'm not sure how you'll test the repo, but the problem with Frontity no longer being maintained is that it only works up until React 17 and node v16 iirc, but this is normally only a requirement if you want to run the application, which is not really the situation here I think. Just let me know should this be a problem for you, because I can always check some other repositories if this is the case. To install the project:
That should be everything to get started. Result: when saving the file, the graph doesn't refresh. In terms of DX/other issues I don't really have anything useful to say atm, I'm okay with how everything is setup, apart from finding out what the cause of this issue is that is 😛 |
Hello @kevin-st, Thanks for adding me to the repository, I just cloned the repository and booted my Windows machine to troubleshoot that. Good news is that I'm able to reproduce the problem both on Windows and MacOS. Also, it seems that switching from
to
shows that latter works on both operating systems so it might not be a |
Hello @kevin-st, I tested a little bit and it does not seem to be linked to the way skott is attaching watch mode, but the way @parcel/watcher deals with the ignore list. skott is providing In your project, you have a
and when I remove the
So it seems that having watcher.subscribe(() => {}, {
ignoreList: [
"!**/*.{js,jsx,mjs,cjs,ts,tsx}",
".vscode/*",
"!.vscode/settings.json",
"!.vscode/tasks.json",
"!.vscode/launch.json",
"!.vscode/extensions.json"
]
}); is making the watcher discarding everything from the watch mode. In that regard, I might take a closer look at @parcel/watcher way of working with Short-term, what you can do is to make skott avoid grabbing the
doing
Note: |
I can confirm what you said. If I remove all negated directives from the I understand this is something out of your control, so hopefully they manage to provide a fix for this. |
Summary
Yesterday I was running skott with the
--watch
flag in the terminal until I noticed that it was not refreshing. I tested bothdisplay-mode="file-tree"
and"webapp"
, but neither were working. To rule out it was a Windows only issue, I went to a colleague who works on mac; we tested it on another repository, but they had the same issue.I then tested my skott example repository (https://github.com/kevin-st/skott-example) on the branch
watch-mode
(by just commenting some import statement), only to find out that it is working there.Then I asked yet another colleague and tested it again on some other repository and on their repo it worked without problems.
All repositories vary in size and amount of circular dependencies, but I don't think it has anything to do with this.
Conclusion: We tested 4 different repositories, of which two work as expected.
Reproduction steps
watch-mode
branch;npm install
;./node_modules/.bin/skott ./packages/index.ts --watch
and apply a change to the file (e.g. commenting out one of the import statements).Result: The graph changes.
Details
From what we've found out, we saw that skott's using
@parcel/watcher
to watch the changes? In that case it might be possible that issue is not related to skott, but we're not certain of that.Standard questions
Please answer these questions to help us investigate your issue more quickly:
skott
installed version?node -v
)?The text was updated successfully, but these errors were encountered: