Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bug: [ERR_PACKAGE_PATH_NOT_EXPORTED]: Package subpath './screenshot' is not defined by "exports" in …/node_modules/@stencil/core/package.json #5906

Closed
3 tasks done
ryuran opened this issue Jul 25, 2024 · 1 comment · Fixed by #5909 · May be fixed by AnirudhJalagam/ionic-frameworkss#2
Assignees
Labels
Bug: Validated This PR or Issue is verified to be a bug within Stencil

Comments

@ryuran
Copy link

ryuran commented Jul 25, 2024

Prerequisites

Stencil Version

>= v4.19.0

Current Behavior

If we set a screenshot cnnector like told by the documentation https://stenciljs.com/docs/screenshot-connector
When run test with screensot : stencil test --e2e --screenshot

This error appear

[ERR_PACKAGE_PATH_NOT_EXPORTED]: Package subpath './screenshot' is not defined by "exports" in …/node_modules/@stencil/core/package.json

Expected Behavior

Run screenshot test as before without this error message.

System Info

System: node 18.18.2
    Platform: darwin (23.5.0)
   CPU Model: Apple M1 Pro (10 cpus)
    Compiler: …/node_modules/@stencil/core/compiler/stencil.js
       Build: 1719938890
     Stencil: 4.19.2 🏉
  TypeScript: 5.4.5
      Rollup: 2.56.3
      Parse5: 7.1.2
      jQuery: 4.0.0-pre
      Terser: 5.31.1

Steps to Reproduce

Add a screenshot connector like the doc say https://stenciljs.com/docs/screenshot-connector#methods
Then run the command
run stencil test --e2e --screenshot

Code Reproduction URL

https://github.com/ryuran/stencil-bugs/tree/screeshot-export-bug

Additional Information

The connector try to import const { ScreenshotLocalConnector } = require('@stencil/core/screenshot'); but @stencil/core/screenshot is not exposed by @stencil/core package.json

@ionitron-bot ionitron-bot bot added the triage label Jul 25, 2024
@christian-bromann christian-bromann self-assigned this Jul 25, 2024
@christian-bromann christian-bromann added the Bug: Validated This PR or Issue is verified to be a bug within Stencil label Jul 25, 2024
@ionitron-bot ionitron-bot bot removed the triage label Jul 25, 2024
@christian-bromann
Copy link
Member

@ryuran thanks for reporting. This was a regression and I opened a PR to resolve the bug.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug: Validated This PR or Issue is verified to be a bug within Stencil
Projects
None yet
2 participants