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

Why is it that when the project content is not changed, many files are modified after each build? #4016

Closed
4 tasks done
Perrywzp opened this issue Jul 3, 2024 · 4 comments
Assignees

Comments

@Perrywzp
Copy link

Perrywzp commented Jul 3, 2024

Describe the bug

Why is it that when the project content is not changed, many files are modified after each build?
like app.[hash].js chunk.[hash].js metadata.[hash].js
like this
image

Reproduction

...

Expected behavior

can dont change that files after build, when we didnt change any files in the project.

System Info

win10

Additional context

No response

Validations

@Perrywzp Perrywzp added the bug: pending triage Maybe a bug, waiting for confirmation label Jul 3, 2024
@brc-dd
Copy link
Member

brc-dd commented Jul 3, 2024

Because they need to be fingerprinted to allow immutable caching. Even if a single character in a file is changed, the hash of all files that depend on that file will change.

@brc-dd brc-dd removed the bug: pending triage Maybe a bug, waiting for confirmation label Jul 3, 2024
@brc-dd brc-dd closed this as not planned Won't fix, can't repro, duplicate, stale Jul 3, 2024
@Perrywzp
Copy link
Author

Perrywzp commented Jul 4, 2024

but i didn`t change any file。but when repeat build this project , the resource has changed.

@brc-dd brc-dd reopened this Jul 4, 2024
@brc-dd
Copy link
Member

brc-dd commented Jul 4, 2024

Sorry. Did you rename or move any file? Can you share your repo or create some dummy one to show the example? Can you share those two metadata files?

@Perrywzp
Copy link
Author

Perrywzp commented Jul 4, 2024

i think you can try init a clean project , create sidebar like under picture.
image
and add metadata props in themconfig or not. then try repeat build , compare the resource , you will find a lot of changed files。like html or like metadata.[hash].js

@brc-dd brc-dd added the bug label Jul 4, 2024
@brc-dd brc-dd self-assigned this Jul 4, 2024
@brc-dd brc-dd closed this as completed in e302328 Jul 4, 2024
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jul 12, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants