Skip to content

Commit

Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor: remove deprecated lifecycle_hooks_no_sandbox from npm_import (
Browse files Browse the repository at this point in the history
gregmagolan committed Apr 9, 2024
1 parent 42f72e1 commit 70aeb37
Showing 3 changed files with 1 addition and 14 deletions.
4 changes: 1 addition & 3 deletions docs/npm_import.md

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion npm/extensions.bzl
Original file line number Diff line number Diff line change
@@ -206,7 +206,6 @@ def _npm_import_bzlmod(i):
lifecycle_hooks = i.lifecycle_hooks,
lifecycle_hooks_env = i.lifecycle_hooks_env,
lifecycle_hooks_execution_requirements = i.lifecycle_hooks_execution_requirements,
lifecycle_hooks_no_sandbox = i.lifecycle_hooks_no_sandbox,
lifecycle_hooks_use_default_shell_env = i.lifecycle_hooks_use_default_shell_env,
link_packages = i.link_packages,
link_workspace = i.link_workspace,
10 changes: 0 additions & 10 deletions npm/private/npm_import.bzl
Original file line number Diff line number Diff line change
@@ -920,8 +920,6 @@ def npm_import(
dev = False,
register_copy_directory_toolchains = True,
register_copy_to_directory_toolchains = True,
# TODO(2.0): remove lifecycle_hooks_no_sandbox from npm_import
lifecycle_hooks_no_sandbox = None,
**kwargs):
"""Import a single npm package into Bazel.
@@ -1170,10 +1168,6 @@ def npm_import(
register_copy_to_directory_toolchains: if True, `@aspect_bazel_lib//lib:repositories.bzl` `register_copy_to_directory_toolchains()` is called if the toolchain is not already registered
lifecycle_hooks_no_sandbox: If True, adds "no-sandbox" to `lifecycle_hooks_execution_requirements`.
Deprecated. Add "no-sandbox" to `lifecycle_hooks_execution_requirements` instead.
**kwargs: Internal use only
"""

@@ -1216,10 +1210,6 @@ def npm_import(
extract_full_archive = extract_full_archive,
)

if lifecycle_hooks_no_sandbox:
if "no-sandbox" not in lifecycle_hooks_execution_requirements:
lifecycle_hooks_execution_requirements.append("no-sandbox")

has_custom_postinstall = not (not custom_postinstall)
has_lifecycle_hooks = not (not lifecycle_hooks)

0 comments on commit 70aeb37

Please sign in to comment.