Error in package exports
@tbeseda is already working on this.
Since Jan 5, 2023.
Assessment
This issue has not been assessed yet.
Description
Hi there!
I tried the fastify example on https://enhance.dev/docs/learn/deployment/fastify and getting a package export error from the arc-plugin-enhance package.
Here is the error I am getting:
node:internal/errors:464
ErrorCaptureStackTrace(err);
^
Error [ERR_PACKAGE_PATH_NOT_EXPORTED]: Package subpath './src/http/any-catchall/index.mjs' is not defined by "exports" in /node_modules/@enhance/arc-plugin-enhance/package.json imported from /node_modules/@enhance/fastify-plugin/index.mjs
at new NodeError (node:internal/errors:371:5)
at throwExportsNotFound (node:internal/modules/esm/resolve:440:9)
at packageExportsResolve (node:internal/modules/esm/resolve:692:3)
at packageResolve (node:internal/modules/esm/resolve:873:14)
at moduleResolve (node:internal/modules/esm/resolve:929:18)
at defaultResolve (node:internal/modules/esm/resolve:1044:11)
at ESMLoader.resolve (node:internal/modules/esm/loader:422:30)
at ESMLoader.getModuleJob (node:internal/modules/esm/loader:222:40)
at ModuleWrap.<anonymous> (node:internal/modules/esm/module_job:76:40)
at link (node:internal/modules/esm/module_job:75:36) {
code: 'ERR_PACKAGE_PATH_NOT_EXPORTED'
}
I kind of fixed it locally by adding "./src/http/any-catchall/index.mjs": "./src/http/any-catchall/index.mjs" to the exports entry in the package.json file but wondered if this is the best way to do this?
Anyway, I am having a really good time playing with enhance! Nice work!
- Dominant language
- JavaScript
- Stars
- 4
- Forks
- 0
- PR merge metrics
- No merged PRs in 30d
Getting set up
- No Dockerfile or Docker Compose file
- No pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from enhance-dev/fastify-plugin
-
Difficulty 4/5 3-5 days Newbie friendliness 35/100
-
Difficulty 3/5 1-2 days Newbie friendliness 38/100
-
Difficulty 3/5 1-2 days Newbie friendliness 25/100
enhance-dev/fastify-plugin#1 · 4 comments · 1 reaction ·
All issues in enhance-dev/fastify-plugin
Similar issues
-
[Bug] Composer can submit an IME confirmation when keyCode is 229 but isComposing is falsePossibly taken A pull request linked to this issue is open or already merged. Open
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
apache/rocketmq-dashboard#6067 ·
Maintainers usually reply within 4 days
-
severity: low
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
luainkernel/lunatik#1853 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
Maintainers usually reply within 1 day
-
factory-active factory-automatic harness/claude-code task-identify-harness-labels-done task-identify-issue-type-done
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
Maintainers usually reply within 1 day