@@ -11,7 +11,7 @@ load("//npm/private:npm_import.bzl", "npm_import_lib", "npm_import_links_lib")
1111load ("//npm/private:npm_translate_lock.bzl" , "npm_translate_lock_lib" , "npm_translate_lock_rule" )
1212load ("//npm/private:npm_translate_lock_helpers.bzl" , npm_translate_lock_helpers = "helpers" )
1313load ("//npm/private:npm_translate_lock_macro_helpers.bzl" , macro_helpers = "helpers" )
14- load ("//npm/private:npm_translate_lock_state.bzl" , "npm_translate_lock_state" )
14+ load ("//npm/private:npm_translate_lock_state.bzl" , "npm_translate_lock_state" , _DEFAULT_ROOT_PACKAGE = "DEFAULT_ROOT_PACKAGE" )
1515load ("//npm/private:npmrc.bzl" , "parse_npmrc" )
1616load ("//npm/private:pnpm_extension.bzl" , "DEFAULT_PNPM_REPO_NAME" , "resolve_pnpm_repositories" )
1717load ("//npm/private:transitive_closure.bzl" , "translate_to_transitive_closure" )
@@ -220,7 +220,7 @@ WARNING: Cannot determine home directory in order to load home `.npmrc` file in
220220 replace_packages = replace_packages ,
221221 patched_dependencies = state .patched_dependencies (),
222222 only_built_dependencies = state .only_built_dependencies (),
223- root_package = attr .pnpm_lock .package ,
223+ root_package = attr .pnpm_lock .package if attr . root_package == _DEFAULT_ROOT_PACKAGE else attr . root_package ,
224224 rctx_name = attr .name ,
225225 attr = attr ,
226226 all_lifecycle_hooks = lifecycle_hooks ,
0 commit comments