Skip to content

install: improve isOnly(Dev,Optional)#206

Closed
larsgw wants to merge 1 commit intonpm:release-nextfrom
larsgw:patch-23
Closed

install: improve isOnly(Dev,Optional)#206
larsgw wants to merge 1 commit intonpm:release-nextfrom
larsgw:patch-23

Conversation

@larsgw
Copy link
Copy Markdown
Contributor

@larsgw larsgw commented Jul 1, 2019

Instead of creating a new set each time a new node gets visited, so that
its siblings do not have it in seen, just remove the node from the
original set right after all child nodes are visited.

See #76

Instead of creating a new set each time a new node gets visited, so that 
its siblings do not have it in `seen`, just remove the node from the 
original set right after all child nodes are visited.

See npm#76
@larsgw larsgw requested a review from a team as a code owner July 1, 2019 23:52
@isaacs isaacs added the semver:patch semver patch level for changes label Jul 2, 2019
@isaacs
Copy link
Copy Markdown
Contributor

isaacs commented Jul 2, 2019

This will be in 6.10.1. Thanks!

isaacs pushed a commit that referenced this pull request Jul 2, 2019
Instead of creating a new set each time a new node gets visited, so that
its siblings do not have it in `seen`, just remove the node from the
original set right after all child nodes are visited.

See #76

Credit: @larsgw

PR-URL: #206
Close: #206
Reviewed-by: @isaacs
@isaacs isaacs mentioned this pull request Jul 2, 2019
isaacs pushed a commit that referenced this pull request Jul 3, 2019
Instead of creating a new set each time a new node gets visited, so that
its siblings do not have it in `seen`, just remove the node from the
original set right after all child nodes are visited.

See #76

Credit: @larsgw

PR-URL: #206
Close: #206
Reviewed-by: @isaacs
@DanielRuf
Copy link
Copy Markdown

I guess we can close this.

@larsgw larsgw closed this Jul 6, 2019
Jah-yee pushed a commit to Jah-yee/cli that referenced this pull request Apr 16, 2026
* fix: isolate flaky auth tests from host ADC credentials

Fixes npm#206

Both test_load_credentials_no_options and
test_get_token_env_var_empty_falls_through now override HOME to a
temp dir and clear GOOGLE_APPLICATION_CREDENTIALS, preventing the
well-known ADC path from matching on CI runners that have gcloud
credentials.

* refactor: use RAII EnvVarGuard for panic-safe env var cleanup in tests

- Introduce EnvVarGuard struct that saves/restores env vars on Drop
- Replace all manual save/restore patterns in auth tests
- Fix bug where test_get_token_env_var_empty_falls_through did not
  restore GOOGLE_WORKSPACE_CLI_TOKEN
- Ensures cleanup runs even if a test panics

* fix: use var_os/OsString in EnvVarGuard for non-UTF-8 safety

---------

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

semver:patch semver patch level for changes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants