Closed naraklearn closed 4 years ago
Hi @naraklearn,
Are both machines using the same Node version? Can you please share the output of ng version
from both machines?
Angular: 8.2 Environment : Windows 10 Node : v10.17.0
Environment : Windows 7 Node: v10.15.3
Angular: 9.1 Environment: Mac Node: v10.16.3 Environment: Windows Node: v10.15.3
What might be the root cause for this issue?
I am seeing that the node version and the packages installed are not the same version, those 2 can cause different file hashes.
npm ci
or yarn frozen-lockfile
)@alan-agius4 Thanks! above mentioned solutions worked for us.
This issue has been automatically locked due to inactivity. Please file a new issue if you are encountering a similar or related problem.
Read more about our automatic conversation locking policy.
This action has been performed automatically by a bot.
Versions
angular : 8.2 & 9.1 angular-cli: 8.3 & 9.1 OS: windows 7 & 10 64bit
Repro steps
Create a site with ng new Add a lazy path with loadChildren ng build --prod Use same source code in differnt machine ng build --prod compare these two dist with same source code(no change)
Observed behavior
Same issue occurred in angular V8.2 & 9.1 versions(attached screenshot of differences in hashes for same source code). Currently production build is in angular 8.2 1) When run in different drives in same machine with same source code, Every time production build happens the hashes in the chunks does not change as no change in the source code – working as expected 2) when run in different computer machine with same source code, production build happens the hashes in the chunks changes when comparing between dist in windows 7 and dist in windows 9 though there is no changes in source code.
Desired behavior
when run in different computer machine with same source code, Every --prod build should not change the hashes in the chunks because no change made in existing code base.
what is recommended way to achieve desired behavior?
if customizing the angular-cli/webpack package is alternate approach, what is the recommended options? angular 8.2 dist comparison: Angular 9.1 dist comparison: