Once the user is in this scenario, both package-lock.json and /node_modules/ must be deleted in order to get the correct behavior from npm install if you delete either one but not the other, npm install will return you to the unexpected state. "integrity ": "sha512-Wu1VHeILBK8KAWJUAiSZQX94GmOE45Rg6/538fKwiloUu21KncEkYGPqob2oSZ5mUT73vLGrHQjKw3KMPwfDzg= " # A reviewer skimming the most obvious version number change will see that the is-odd requires section correctly indicates 5.0.0 # However, the is-number entry in dependencies is incorrectly still referencing 6.0.0 > git diff package-lock.jsonÄiff -git a/package-lock.json b/package-lock.json # Actual behavior: package-lock.json is only partially updated. # Actual behavior: the installed version of is-number remains 6.0.0, not 5.0.0 > rg '\"version\" '. > git add package *.json & git commit -m 'before override ' # Now edit package.json adding "overrides": # Expected behavior: npm install should update the lockfile and installed versions such that the override to v5.0.0 is satisfied > npm install > mkdir npm-cli-4232-repro & cd npm-cli-4232-repro & git init & npm init -y # Baseline setup, all as expected > node -version
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |