Skip to content
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

Fix multiple grammars not always recompile issue #789 #790

merged 1 commit into from
Feb 9, 2023


Copy link

@huacnlee huacnlee commented Feb 9, 2023

Closes #789

@huacnlee huacnlee requested a review from a team as a code owner February 9, 2023 06:55
@huacnlee huacnlee requested review from tomtau and removed request for a team February 9, 2023 06:55
Copy link

@tomtau tomtau left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, so the root cause was that only a single path was passed to that function at a time which prevented regenerating the other paths (only one of them was tracked)?

Copy link
Member Author

huacnlee commented Feb 9, 2023

Yes, I have tested these changes with cargo watch -x test.

I also test that behavior (Before and After changes) with cargo test or cargo build, which does not appear.

So, it's looks like this bug only appears in cargo watch.

Copy link
Member Author

huacnlee commented Feb 9, 2023

I realize that maybe we don't need set all of pest file contents as a value, just only give a file updated at or a content md5. When the .pest files has changed, it's also can trigger change events.

Ignore that, it not a serious problem. And fs::metadata modified might not be available on all platforms.

Copy link

Looks like a solid fix to me.

@tomtau tomtau merged commit ac89744 into pest-parser:master Feb 9, 2023
@huacnlee huacnlee deleted the fix-789 branch February 10, 2023 01:04
Copy link

jayhale commented Feb 12, 2023

Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
None yet

Successfully merging this pull request may close these issues.

Multiple grammars not always recompiled
4 participants