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

Cache seems invalidated because of a suspicious date #3979

Open
MangelMaxime opened this issue Dec 17, 2024 Discussed in #3978 · 2 comments
Open

Cache seems invalidated because of a suspicious date #3979

MangelMaxime opened this issue Dec 17, 2024 Discussed in #3978 · 2 comments

Comments

@MangelMaxime
Copy link
Member

Discussed in #3978

Originally posted by joprice December 17, 2024
I'm curious whether the current behavior I'm seeing is correct when rebuilding after a single line change. I find that when I run fable with a command like

dotnet fable cli/Cli.fsproj -e .fs.js -o cli/js --runScript "notifications"

the first build takes about 15s. The second is less than a second and finishes with Skipped compilation because all generated files are up-to-date!,

but after a single line change, I see output that seems to indicate the entire project is being recompiled (Compiled 221/224, etc), including files in the fable_modules folder, which, of course, I didn't modify. The time taken is the same as the full recompile, which makes me think that build caching only works for the exact same input, and not on incremental changes, or my environment or build is somehow misconfigured causing this.

Is this to be expected and if so, is there any way to improve it? It's my main frustration right now working with fable, so I'd be willing to contribute some time if it could help.

@MangelMaxime
Copy link
Member Author

One thing that surprise me, is I am pretty sure in the past Fable was able to only recompile the file depend on the changed file.

But it seems like now, it always recompile everything all the time.

@alfonsogarciacaro Do you confirm that in the past, watch mode was able to be more selective?

@MangelMaxime
Copy link
Member Author

I think the fast compilation I had in mind in the past is thanks to:

I think I know what the problem is. In watch mode Fable only compiles files with modifications.

#3184 (comment)

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

No branches or pull requests

1 participant