-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Closed
Labels
Description
What version of Wrangler are you using?
2.1.6
What operating system are you using?
Windows (Git Bash/MINGW)
Describe the Bug
Summary
I am unable to resolve any packages in Cloudflare workers despite them being listed on https://workers.cloudflare.com/works and working locally through wrangler.
I followed the official guide to integrate Sentry as middleware.
Repo/branch
https://github.com/aensley/liturgy-day/tree/add-sentry-2
Source
Build Error
09:39:43.463 | Cloning repository...
-- | --
09:39:44.397 | From https://github.com/aensley/liturgy-day
09:39:44.397 | * branch 12f431856ec80533f29ffa5bc08320ad6dd7d464 -> FETCH_HEAD
09:39:44.397 | ย
09:39:44.443 | HEAD is now at 12f4318 add wrangler?
09:39:44.443 | ย
09:39:44.551 | ย
09:39:44.573 | Success: Finished cloning repository files
09:39:45.069 | No build command specified. Skipping build step.
09:39:45.559 | ๐ง 'wrangler pages <command>' is a beta command. Please report any issues to https://github.com/cloudflare/wrangler2/issues/new/choose
09:39:45.625 | โ [ERROR] Could not resolve "@cloudflare/pages-plugin-sentry"
09:39:45.625 | ย
09:39:45.625 | ../../../buildhome/repo/functions/_middleware.ts:1:25:
09:39:45.625 | 1 โ import sentryPlugin from '@cloudflare/pages-plugin-sentry'
09:39:45.626 | โต ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
09:39:45.626 | ย
09:39:45.626 | You can mark the path "@cloudflare/pages-plugin-sentry" as external to exclude it from the bundle, which will remove this error.
09:39:45.627 | ย
09:39:45.630 | 1 error(s) and 0 warning(s) when compiling Worker.
09:39:45.631 | ย
09:39:45.718 | ๏ฟฝ[31mโ ๏ฟฝ[41;31m[๏ฟฝ[41;97mERROR๏ฟฝ[41;31m]๏ฟฝ[0m ๏ฟฝ[1mBuild failed with 1 error:๏ฟฝ[0m
09:39:45.718 | ย
09:39:45.718 | ../../../buildhome/repo/functions/_middleware.ts:1:25: ERROR: Could not resolve "@cloudflare/pages-plugin-sentry"
09:39:45.718 | ย
09:39:45.718 | ย
09:39:45.718 | ๏ฟฝ[32mIf you think this is a bug then please create an issue at https://github.com/cloudflare/wrangler2/issues/new/choose๏ฟฝ[0m
09:39:45.727 | Failed building Pages Functions from /functions.
09:39:46.537 | Failed: an internal error occurredLocal output (successful)
me@my-computer MINGW64 ~/Workspaces/liturgy-day (add-sentry-2)
$ npx wrangler pages dev src --binding SENTRY_DSN="https://xxxxxxxxxxxxx@xxxxxxx.ingest.sentry.io/xxxxxxxxx" --binding ENVIRONMENT="local"
๐ง 'wrangler pages <command>' is a beta command. Please report any issues to https://github.com/cloudflare/wrangler2/issues/new/choose
Compiling worker to "C:\Users\me\AppData\Local\Temp\functionsWorker-0.9120506640895183.js"...
Compiled Worker successfully.
โฒ [WARNING] Passing --inspect is unnecessary, now you can always connect to devtools.
โญโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโฎ
โ [b] open a browser, [d] open Devtools, [c] clear console, [x] to exit โ
โฐโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโฏ
Debugger listening on ws://0.0.0.0:9229/972d75ea-2273-4625-8023-a5817c6a81ab
For help, see: https://nodejs.org/en/docs/inspector
[pages:wrn] Parsed 2 valid header rules.
[pages:wrn] Service bindings are experimental. There may be breaking changes in the future.
[pages:inf] Worker reloaded! (195.16KiB)
[pages:inf] Listening on 0.0.0.0:8788
[pages:inf] Updated `Request.cf` object cache!
GET /api/day/2022-09-26 200 OK (19.75ms)mikob
