-
Notifications
You must be signed in to change notification settings - Fork 11
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
SvelteKit SDK: Cannot find package '$env' imported from @arcjet/sveltekit/index.js #982
Comments
davidmytton
added
sveltekit
Related to the SvelteKit SDK.
bug
Something isn't working
node
Related to the Node SDK.
labels
Jun 15, 2024
I'm wondering how SvelteKit creates/replaces the |
This issue doesn't surface in our example so it might be related to |
I was finally able to get this to trigger in our sveltekit example too. |
trunk-io bot
pushed a commit
that referenced
this issue
Jun 17, 2024
🤖 I have created a release *beep* *boop* --- <details><summary>@arcjet/analyze: 1.0.0-alpha.17</summary> ## [1.0.0-alpha.17](https://github.com/arcjet/arcjet-js/compare/v1.0.0-alpha.16...@arcjet/analyze-v1.0.0-alpha.17) (2024-06-17) ### 🧹 Miscellaneous Chores * **@arcjet/analyze:** Synchronize arcjet-js versions ### Dependencies * The following workspace dependencies were updated * dependencies * @arcjet/protocol bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * devDependencies * @arcjet/eslint-config bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/rollup-config bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/tsconfig bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 </details> <details><summary>@arcjet/bun: 1.0.0-alpha.17</summary> ## [1.0.0-alpha.17](https://github.com/arcjet/arcjet-js/compare/v1.0.0-alpha.16...@arcjet/bun-v1.0.0-alpha.17) (2024-06-17) ### 🧹 Miscellaneous Chores * **@arcjet/bun:** Synchronize arcjet-js versions ### Dependencies * The following workspace dependencies were updated * dependencies * @arcjet/env bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/headers bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/ip bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/logger bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/protocol bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * arcjet bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * devDependencies * @arcjet/eslint-config bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/rollup-config bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/tsconfig bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 </details> <details><summary>@arcjet/decorate: 1.0.0-alpha.17</summary> ## [1.0.0-alpha.17](https://github.com/arcjet/arcjet-js/compare/v1.0.0-alpha.16...@arcjet/decorate-v1.0.0-alpha.17) (2024-06-17) ### 🧹 Miscellaneous Chores * **@arcjet/decorate:** Synchronize arcjet-js versions ### Dependencies * The following workspace dependencies were updated * dependencies * @arcjet/protocol bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/sprintf bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * devDependencies * @arcjet/eslint-config bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/rollup-config bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/tsconfig bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 </details> <details><summary>@arcjet/duration: 1.0.0-alpha.17</summary> ## [1.0.0-alpha.17](https://github.com/arcjet/arcjet-js/compare/v1.0.0-alpha.16...@arcjet/duration-v1.0.0-alpha.17) (2024-06-17) ### 🧹 Miscellaneous Chores * **@arcjet/duration:** Synchronize arcjet-js versions ### Dependencies * The following workspace dependencies were updated * devDependencies * @arcjet/eslint-config bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/rollup-config bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/tsconfig bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 </details> <details><summary>@arcjet/env: 1.0.0-alpha.17</summary> ## [1.0.0-alpha.17](https://github.com/arcjet/arcjet-js/compare/v1.0.0-alpha.16...@arcjet/env-v1.0.0-alpha.17) (2024-06-17) ### 🧹 Miscellaneous Chores * **@arcjet/env:** Synchronize arcjet-js versions ### Dependencies * The following workspace dependencies were updated * devDependencies * @arcjet/eslint-config bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/rollup-config bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/tsconfig bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 </details> <details><summary>@arcjet/eslint-config: 1.0.0-alpha.17</summary> ## [1.0.0-alpha.17](https://github.com/arcjet/arcjet-js/compare/v1.0.0-alpha.16...@arcjet/eslint-config-v1.0.0-alpha.17) (2024-06-17) ### 📦 Dependencies * Bump eslint-config-turbo from 2.0.3 to 2.0.4 ([#983](#983)) ([8383a31](8383a31)) </details> <details><summary>@arcjet/headers: 1.0.0-alpha.17</summary> ## [1.0.0-alpha.17](https://github.com/arcjet/arcjet-js/compare/v1.0.0-alpha.16...@arcjet/headers-v1.0.0-alpha.17) (2024-06-17) ### 🧹 Miscellaneous Chores * **@arcjet/headers:** Synchronize arcjet-js versions ### Dependencies * The following workspace dependencies were updated * devDependencies * @arcjet/eslint-config bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/rollup-config bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/tsconfig bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 </details> <details><summary>@arcjet/ip: 1.0.0-alpha.17</summary> ## [1.0.0-alpha.17](https://github.com/arcjet/arcjet-js/compare/v1.0.0-alpha.16...@arcjet/ip-v1.0.0-alpha.17) (2024-06-17) ### 🧹 Miscellaneous Chores * **@arcjet/ip:** Synchronize arcjet-js versions ### Dependencies * The following workspace dependencies were updated * devDependencies * @arcjet/eslint-config bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/rollup-config bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/tsconfig bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 </details> <details><summary>@arcjet/logger: 1.0.0-alpha.17</summary> ## [1.0.0-alpha.17](https://github.com/arcjet/arcjet-js/compare/v1.0.0-alpha.16...@arcjet/logger-v1.0.0-alpha.17) (2024-06-17) ### 🧹 Miscellaneous Chores * **@arcjet/logger:** Synchronize arcjet-js versions ### Dependencies * The following workspace dependencies were updated * dependencies * @arcjet/sprintf bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * devDependencies * @arcjet/eslint-config bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/rollup-config bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/tsconfig bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 </details> <details><summary>@arcjet/next: 1.0.0-alpha.17</summary> ## [1.0.0-alpha.17](https://github.com/arcjet/arcjet-js/compare/v1.0.0-alpha.16...@arcjet/next-v1.0.0-alpha.17) (2024-06-17) ### 🧹 Miscellaneous Chores * **@arcjet/next:** Synchronize arcjet-js versions ### Dependencies * The following workspace dependencies were updated * dependencies * @arcjet/env bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/headers bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/ip bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/logger bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/protocol bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * arcjet bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * devDependencies * @arcjet/eslint-config bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/rollup-config bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/tsconfig bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 </details> <details><summary>@arcjet/node: 1.0.0-alpha.17</summary> ## [1.0.0-alpha.17](https://github.com/arcjet/arcjet-js/compare/v1.0.0-alpha.16...@arcjet/node-v1.0.0-alpha.17) (2024-06-17) ### 🧹 Miscellaneous Chores * **@arcjet/node:** Synchronize arcjet-js versions ### Dependencies * The following workspace dependencies were updated * dependencies * @arcjet/env bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/headers bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/ip bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/logger bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/protocol bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * arcjet bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * devDependencies * @arcjet/eslint-config bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/rollup-config bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/tsconfig bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 </details> <details><summary>@arcjet/protocol: 1.0.0-alpha.17</summary> ## [1.0.0-alpha.17](https://github.com/arcjet/arcjet-js/compare/v1.0.0-alpha.16...@arcjet/protocol-v1.0.0-alpha.17) (2024-06-17) ### 🧹 Miscellaneous Chores * **@arcjet/protocol:** Synchronize arcjet-js versions ### Dependencies * The following workspace dependencies were updated * devDependencies * @arcjet/eslint-config bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/rollup-config bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/tsconfig bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 </details> <details><summary>@arcjet/rollup-config: 1.0.0-alpha.17</summary> ## [1.0.0-alpha.17](https://github.com/arcjet/arcjet-js/compare/v1.0.0-alpha.16...@arcjet/rollup-config-v1.0.0-alpha.17) (2024-06-17) ### 🧹 Miscellaneous Chores * **@arcjet/rollup-config:** Synchronize arcjet-js versions ### Dependencies * The following workspace dependencies were updated * devDependencies * @arcjet/eslint-config bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/tsconfig bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 </details> <details><summary>@arcjet/runtime: 1.0.0-alpha.17</summary> ## [1.0.0-alpha.17](https://github.com/arcjet/arcjet-js/compare/v1.0.0-alpha.16...@arcjet/runtime-v1.0.0-alpha.17) (2024-06-17) ### 🧹 Miscellaneous Chores * **@arcjet/runtime:** Synchronize arcjet-js versions ### Dependencies * The following workspace dependencies were updated * devDependencies * @arcjet/eslint-config bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/rollup-config bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/tsconfig bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 </details> <details><summary>@arcjet/sprintf: 1.0.0-alpha.17</summary> ## [1.0.0-alpha.17](https://github.com/arcjet/arcjet-js/compare/v1.0.0-alpha.16...@arcjet/sprintf-v1.0.0-alpha.17) (2024-06-17) ### 🧹 Miscellaneous Chores * **@arcjet/sprintf:** Synchronize arcjet-js versions ### Dependencies * The following workspace dependencies were updated * devDependencies * @arcjet/eslint-config bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/rollup-config bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/tsconfig bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 </details> <details><summary>@arcjet/sveltekit: 1.0.0-alpha.17</summary> ## [1.0.0-alpha.17](https://github.com/arcjet/arcjet-js/compare/v1.0.0-alpha.16...@arcjet/sveltekit-v1.0.0-alpha.17) (2024-06-17) ### 🪲 Bug Fixes * **sveltekit:** Load environment variables from process.env ([#989](#989)) ([375eaa9](375eaa9)), closes [#982](#982) ### Dependencies * The following workspace dependencies were updated * dependencies * @arcjet/env bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/headers bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/ip bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/logger bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/protocol bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/runtime bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * arcjet bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * devDependencies * @arcjet/eslint-config bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/rollup-config bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/tsconfig bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 </details> <details><summary>@arcjet/tsconfig: 1.0.0-alpha.17</summary> ## [1.0.0-alpha.17](https://github.com/arcjet/arcjet-js/compare/v1.0.0-alpha.16...@arcjet/tsconfig-v1.0.0-alpha.17) (2024-06-17) ### 🧹 Miscellaneous Chores * **@arcjet/tsconfig:** Synchronize arcjet-js versions </details> <details><summary>arcjet: 1.0.0-alpha.17</summary> ## [1.0.0-alpha.17](v1.0.0-alpha.16...arcjet-v1.0.0-alpha.17) (2024-06-17) ### 🧹 Miscellaneous Chores * **arcjet:** Synchronize arcjet-js versions ### Dependencies * The following workspace dependencies were updated * dependencies * @arcjet/analyze bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/duration bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/headers bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/protocol bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/runtime bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * devDependencies * @arcjet/eslint-config bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/rollup-config bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 * @arcjet/tsconfig bumped from 1.0.0-alpha.16 to 1.0.0-alpha.17 </details> <details><summary>1.0.0-alpha.17</summary> ## [1.0.0-alpha.17](v1.0.0-alpha.16...v1.0.0-alpha.17) (2024-06-17) ### 🪲 Bug Fixes * **sveltekit:** Load environment variables from process.env ([#989](#989)) ([375eaa9](375eaa9)), closes [#982](#982) ### 📦 Dependencies * Bump eslint-config-turbo from 2.0.3 to 2.0.4 ([#983](#983)) ([8383a31](8383a31)) * **example:** Bump ai from 3.1.35 to 3.1.36 in /examples/nextjs-14-openai in the dependencies group ([#984](#984)) ([08d4b57](08d4b57)) * **example:** Bump the dependencies group across 1 directory with 5 updates ([#991](#991)) ([593833d](593833d)) * **example:** Bump the dependencies group in /examples/nextjs-14-react-hook-form with 2 updates ([#985](#985)) ([c259fb3](c259fb3)) ### 🧹 Miscellaneous Chores * **examples:** Update .env file with ARCJET_ENV when NODE_ENV isn't set ([#988](#988)) ([6f7ca62](6f7ca62)) </details> --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please).
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Reported in #886 (comment), the Sveltekit adapter is not working with both Node and Bun (which is the runtime of the original report).
Reproduce - Node
Follow the SvelteKit setup guide:
Then follow our SvelteKit getting started guide to install
npm i @arcjet/sveltekit
and create an API route atsrc/routes/arcjet/+server.ts
Then
npm run dev
and loading the route errors:Reproduce - Bun
Follow the Bun Sveltekit guide:
Then follow our SvelteKit getting started guide to install
bun install @arcjet/sveltekit
and you get a similar error:The text was updated successfully, but these errors were encountered: