Skip to content

Fix cache location for npm ci#550

Closed
zhenyavinogradov wants to merge 1 commit intonpm:latestfrom
zhenyavinogradov:patch-1
Closed

Fix cache location for npm ci#550
zhenyavinogradov wants to merge 1 commit intonpm:latestfrom
zhenyavinogradov:patch-1

Conversation

@zhenyavinogradov
Copy link
Copy Markdown
Contributor

When you set <cache> directory in npm config, npm ci has been using <cache> for storing the cache instead of <cache>/_cacache

When you set `<cache>` directory in npm config, `npm ci` has been using `<cache>` for storing the cache instead of `<cache>/_cacache`
@ruyadorno ruyadorno closed this in fd0a802 Jan 9, 2020
This was referenced Jan 10, 2020
Jah-yee pushed a commit to Jah-yee/cli that referenced this pull request Apr 16, 2026
…#550)

* feat: handle SIGTERM in +watch and +subscribe for clean shutdown

Add shared shutdown_signal() helper that merges SIGINT and SIGTERM
into a single future. Replace tokio::signal::ctrl_c() in both watch
and subscribe pull loops so they exit cleanly under Kubernetes,
Docker, and systemd.

On non-Unix platforms, only SIGINT (Ctrl+C) is handled.

* fix: register SIGTERM handler once via persistent background task

Use OnceLock + tokio::sync::Notify so the signal handler stays active
for the process lifetime. Eliminates the race window between loop
iterations where a SIGTERM would bypass the handler.

* fix: graceful fallback when SIGTERM registration fails

Replace expect() with match: if signal(SIGTERM) fails, log a warning
and fall back to SIGINT-only. Prevents silent task death that would
hang all shutdown_signal() callers indefinitely.

* fix: prevent spurious shutdown from ignored ctrl_c errors

Use Ok(_) pattern matching in select! branches and expect() for
standalone ctrl_c().await calls. Previously .ok() silently swallowed
errors, causing notify_waiters() to fire immediately.

* fix: handle ctrl_c error in select! to avoid losing SIGINT branch

Bind the full Result from ctrl_c() and expect() on it instead of
pattern matching Ok(_), which silently dropped the branch on Err.

---------

Co-authored-by: jpoehnelt-bot <jpoehnelt-bot@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pr: needs tests requires tests before merging

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants