package self-reference works without a flag in node v12.16 #31754
Labels
confirmed-bug
Issues with confirmed bugs.
esm
Issues and PRs related to the ECMAScript Modules implementation.
module
Issues and PRs related to the module subsystem.
Repro: clone https://github.com/ljharb/has-package-exports
It has a dev dep of
"has-package-exports": "file:."
, so that in every node version, i canrequire('has-package-exports')
from within the package, and it works.In node v13.6 and v12.15,
node test
passes without issuing(node:96292) ExperimentalWarning: Package name self resolution is an experimental feature. This feature could change at any time
as a warning.In node v13.7, the warning is correctly issued, and the local dev dep is byassed.
However, in node v12.16, without passing any flags, the warning is issued and the local dev dep is bypassed. v12.16 and v12.15 should behave identically with respect to this feature, regardless of the presence of "exports" in package.json.
cc @nodejs/modules-active-members
The text was updated successfully, but these errors were encountered: