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: don't fail immediately if cache dir is not accessible #5197

Merged
merged 1 commit into from
Jul 21, 2022

Conversation

lukekarrys
Copy link
Contributor

This also changes all the log messages about not being able to create
initial directories and files to log.verbose since we know run those
commands on init. There are a lot of valid reasons why those might fail,
and we don't want to show a warning for them every time.

Fixes: #4769
Fixes: #4838
Fixes: #4996

@lukekarrys lukekarrys requested a review from a team as a code owner July 20, 2022 14:30
@lukekarrys lukekarrys marked this pull request as draft July 20, 2022 14:44
@lukekarrys
Copy link
Contributor Author

Need to add a test for this, obviously. 😶‍🌫️

@npm-cli-bot
Copy link
Collaborator

npm-cli-bot commented Jul 20, 2022

no statistically significant performance changes detected

timing results
app-large clean lock-only cache-only cache-only
peer-deps
modules-only no-lock no-cache no-modules no-clean no-clean
audit
npm@8 42.893 ±7.21 17.217 ±0.30 15.602 ±0.21 19.056 ±2.30 2.571 ±0.12 2.638 ±0.07 2.072 ±0.02 10.832 ±0.37 2.065 ±0.07 3.434 ±0.48
#5197 45.685 ±0.82 17.918 ±0.12 15.719 ±0.04 19.138 ±1.18 2.689 ±0.03 2.607 ±0.02 2.131 ±0.05 10.915 ±0.23 2.146 ±0.01 3.368 ±0.35
app-medium clean lock-only cache-only cache-only
peer-deps
modules-only no-lock no-cache no-modules no-clean no-clean
audit
npm@8 27.559 ±0.88 13.271 ±0.10 11.660 ±0.34 13.051 ±0.49 2.414 ±0.11 2.397 ±0.08 2.164 ±0.00 7.922 ±0.16 2.017 ±0.04 2.905 ±0.02
#5197 27.391 ±1.15 13.307 ±0.22 11.742 ±0.23 12.873 ±0.49 2.378 ±0.07 2.461 ±0.03 2.162 ±0.06 8.051 ±0.24 2.048 ±0.04 2.820 ±0.01

This also changes all the log messages about not being able to create
initial directories and files to `log.verbose` since we know run those
commands on init. There are a lot of valid reasons why those might fail,
and we don't want to show a warning for them every time.

Fixes: #4769
Fixes: #4838
Fixes: #4996
@lukekarrys lukekarrys merged commit 9905d0e into latest Jul 21, 2022
@lukekarrys lukekarrys deleted the lk/readonly branch July 21, 2022 16:40
@vojty
Copy link

vojty commented Jul 27, 2022

Could you please release a new version with this?

@wraithgar
Copy link
Member

@vojty releases happen weekly on Wednesday. https://github.com/npm/cli/wiki/Release-Process-(v8)

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