@sentry/cloudflare 10.44.0 → 10.45.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2,12 +2,12 @@ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
2
2
 
3
3
  const async = require('./async.js');
4
4
  const instrument = require('./instrument.js');
5
- const hono = require('./integrations/hono.js');
6
5
  const instrumentEmail = require('./instrumentations/worker/instrumentEmail.js');
7
6
  const instrumentFetch = require('./instrumentations/worker/instrumentFetch.js');
8
7
  const instrumentQueue = require('./instrumentations/worker/instrumentQueue.js');
9
8
  const instrumentScheduled = require('./instrumentations/worker/instrumentScheduled.js');
10
9
  const instrumentTail = require('./instrumentations/worker/instrumentTail.js');
10
+ const hono = require('./integrations/hono.js');
11
11
 
12
12
  /**
13
13
  * Wrapper for Cloudflare handlers.
@@ -1 +1 @@
1
- {"version":3,"file":"withSentry.js","sources":["../../src/withSentry.ts"],"sourcesContent":["import { setAsyncLocalStorageAsyncContextStrategy } from './async';\nimport type { CloudflareOptions } from './client';\nimport { isInstrumented, markAsInstrumented } from './instrument';\nimport { getHonoIntegration } from './integrations/hono';\nimport { instrumentExportedHandlerEmail } from './instrumentations/worker/instrumentEmail';\nimport { instrumentExportedHandlerFetch } from './instrumentations/worker/instrumentFetch';\nimport { instrumentExportedHandlerQueue } from './instrumentations/worker/instrumentQueue';\nimport { instrumentExportedHandlerScheduled } from './instrumentations/worker/instrumentScheduled';\nimport { instrumentExportedHandlerTail } from './instrumentations/worker/instrumentTail';\n\n/**\n * Wrapper for Cloudflare handlers.\n *\n * Initializes the SDK and wraps the handler with Sentry instrumentation.\n *\n * Automatically instruments the `fetch` method of the handler.\n *\n * @param optionsCallback Function that returns the options for the SDK initialization.\n * @param handler {ExportedHandler} The handler to wrap.\n * @returns The wrapped handler.\n */\nexport function withSentry<\n Env = unknown,\n QueueHandlerMessage = unknown,\n CfHostMetadata = unknown,\n T extends ExportedHandler<Env, QueueHandlerMessage, CfHostMetadata> = ExportedHandler<\n Env,\n QueueHandlerMessage,\n CfHostMetadata\n >,\n>(optionsCallback: (env: Env) => CloudflareOptions | undefined, handler: T): T {\n setAsyncLocalStorageAsyncContextStrategy();\n\n try {\n instrumentExportedHandlerFetch(handler, optionsCallback);\n instrumentHonoErrorHandler(handler);\n instrumentExportedHandlerScheduled(handler, optionsCallback);\n instrumentExportedHandlerEmail(handler, optionsCallback);\n instrumentExportedHandlerQueue(handler, optionsCallback);\n instrumentExportedHandlerTail(handler, optionsCallback);\n // This is here because Miniflare sometimes cannot get instrumented\n } catch {\n // Do not console anything here, we don't want to spam the console with errors\n }\n\n return handler;\n}\n\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nfunction instrumentHonoErrorHandler<T extends ExportedHandler<any, any, any>>(handler: T): void {\n if (\n 'onError' in handler &&\n 'errorHandler' in handler &&\n typeof handler.errorHandler === 'function' &&\n !isInstrumented(handler.errorHandler)\n ) {\n handler.errorHandler = new Proxy(handler.errorHandler, {\n apply(target, thisArg, args) {\n const [err, context] = args;\n\n getHonoIntegration()?.handleHonoException(err, context);\n\n return Reflect.apply(target, thisArg, args);\n },\n });\n\n markAsInstrumented(handler.errorHandler);\n }\n}\n"],"names":["setAsyncLocalStorageAsyncContextStrategy","instrumentExportedHandlerFetch","instrumentExportedHandlerScheduled","instrumentExportedHandlerEmail","instrumentExportedHandlerQueue","instrumentExportedHandlerTail","isInstrumented","getHonoIntegration","markAsInstrumented"],"mappings":";;;;;;;;;;;AAUA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACO,SAAS;;AAShB,CAAE,eAAe,EAA+C,OAAO,EAAQ;AAC/E,EAAEA,8CAAwC,EAAE;;AAE5C,EAAE,IAAI;AACN,IAAIC,8CAA8B,CAAC,OAAO,EAAE,eAAe,CAAC;AAC5D,IAAI,0BAA0B,CAAC,OAAO,CAAC;AACvC,IAAIC,sDAAkC,CAAC,OAAO,EAAE,eAAe,CAAC;AAChE,IAAIC,8CAA8B,CAAC,OAAO,EAAE,eAAe,CAAC;AAC5D,IAAIC,8CAA8B,CAAC,OAAO,EAAE,eAAe,CAAC;AAC5D,IAAIC,4CAA6B,CAAC,OAAO,EAAE,eAAe,CAAC;AAC3D;AACA,EAAE,EAAE,MAAM;AACV;AACA,EAAE;;AAEF,EAAE,OAAO,OAAO;AAChB;;AAEA;AACA,SAAS,0BAA0B,CAA2C,OAAO,EAAW;AAChG,EAAE;AACF,IAAI,SAAA,IAAa,OAAA;AACjB,IAAI,cAAA,IAAkB,OAAA;AACtB,IAAI,OAAO,OAAO,CAAC,YAAA,KAAiB,UAAA;AACpC,IAAI,CAACC,yBAAc,CAAC,OAAO,CAAC,YAAY;AACxC,IAAI;AACJ,IAAI,OAAO,CAAC,YAAA,GAAe,IAAI,KAAK,CAAC,OAAO,CAAC,YAAY,EAAE;AAC3D,MAAM,KAAK,CAAC,MAAM,EAAE,OAAO,EAAE,IAAI,EAAE;AACnC,QAAQ,MAAM,CAAC,GAAG,EAAE,OAAO,CAAA,GAAI,IAAI;;AAEnC,QAAQC,uBAAkB,EAAE,EAAE,mBAAmB,CAAC,GAAG,EAAE,OAAO,CAAC;;AAE/D,QAAQ,OAAO,OAAO,CAAC,KAAK,CAAC,MAAM,EAAE,OAAO,EAAE,IAAI,CAAC;AACnD,MAAM,CAAC;AACP,KAAK,CAAC;;AAEN,IAAIC,6BAAkB,CAAC,OAAO,CAAC,YAAY,CAAC;AAC5C,EAAE;AACF;;;;"}
1
+ {"version":3,"file":"withSentry.js","sources":["../../src/withSentry.ts"],"sourcesContent":["import type { env } from 'cloudflare:workers';\nimport { setAsyncLocalStorageAsyncContextStrategy } from './async';\nimport type { CloudflareOptions } from './client';\nimport { isInstrumented, markAsInstrumented } from './instrument';\nimport { instrumentExportedHandlerEmail } from './instrumentations/worker/instrumentEmail';\nimport { instrumentExportedHandlerFetch } from './instrumentations/worker/instrumentFetch';\nimport { instrumentExportedHandlerQueue } from './instrumentations/worker/instrumentQueue';\nimport { instrumentExportedHandlerScheduled } from './instrumentations/worker/instrumentScheduled';\nimport { instrumentExportedHandlerTail } from './instrumentations/worker/instrumentTail';\nimport { getHonoIntegration } from './integrations/hono';\n\n/**\n * Wrapper for Cloudflare handlers.\n *\n * Initializes the SDK and wraps the handler with Sentry instrumentation.\n *\n * Automatically instruments the `fetch` method of the handler.\n *\n * @param optionsCallback Function that returns the options for the SDK initialization.\n * @param handler {ExportedHandler} The handler to wrap.\n * @returns The wrapped handler.\n */\nexport function withSentry<\n Env = typeof env,\n QueueHandlerMessage = unknown,\n CfHostMetadata = unknown,\n T extends ExportedHandler<Env, QueueHandlerMessage, CfHostMetadata> = ExportedHandler<\n Env,\n QueueHandlerMessage,\n CfHostMetadata\n >,\n>(optionsCallback: (env: Env) => CloudflareOptions | undefined, handler: T): T {\n setAsyncLocalStorageAsyncContextStrategy();\n\n try {\n instrumentExportedHandlerFetch(handler, optionsCallback);\n instrumentHonoErrorHandler(handler);\n instrumentExportedHandlerScheduled(handler, optionsCallback);\n instrumentExportedHandlerEmail(handler, optionsCallback);\n instrumentExportedHandlerQueue(handler, optionsCallback);\n instrumentExportedHandlerTail(handler, optionsCallback);\n // This is here because Miniflare sometimes cannot get instrumented\n } catch {\n // Do not console anything here, we don't want to spam the console with errors\n }\n\n return handler;\n}\n\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nfunction instrumentHonoErrorHandler<T extends ExportedHandler<any, any, any>>(handler: T): void {\n if (\n 'onError' in handler &&\n 'errorHandler' in handler &&\n typeof handler.errorHandler === 'function' &&\n !isInstrumented(handler.errorHandler)\n ) {\n handler.errorHandler = new Proxy(handler.errorHandler, {\n apply(target, thisArg, args) {\n const [err, context] = args;\n\n getHonoIntegration()?.handleHonoException(err, context);\n\n return Reflect.apply(target, thisArg, args);\n },\n });\n\n markAsInstrumented(handler.errorHandler);\n }\n}\n"],"names":["setAsyncLocalStorageAsyncContextStrategy","instrumentExportedHandlerFetch","instrumentExportedHandlerScheduled","instrumentExportedHandlerEmail","instrumentExportedHandlerQueue","instrumentExportedHandlerTail","isInstrumented","getHonoIntegration","markAsInstrumented"],"mappings":";;;;;;;;;;;AAWA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACO,SAAS;;AAShB,CAAE,eAAe,EAA+C,OAAO,EAAQ;AAC/E,EAAEA,8CAAwC,EAAE;;AAE5C,EAAE,IAAI;AACN,IAAIC,8CAA8B,CAAC,OAAO,EAAE,eAAe,CAAC;AAC5D,IAAI,0BAA0B,CAAC,OAAO,CAAC;AACvC,IAAIC,sDAAkC,CAAC,OAAO,EAAE,eAAe,CAAC;AAChE,IAAIC,8CAA8B,CAAC,OAAO,EAAE,eAAe,CAAC;AAC5D,IAAIC,8CAA8B,CAAC,OAAO,EAAE,eAAe,CAAC;AAC5D,IAAIC,4CAA6B,CAAC,OAAO,EAAE,eAAe,CAAC;AAC3D;AACA,EAAE,EAAE,MAAM;AACV;AACA,EAAE;;AAEF,EAAE,OAAO,OAAO;AAChB;;AAEA;AACA,SAAS,0BAA0B,CAA2C,OAAO,EAAW;AAChG,EAAE;AACF,IAAI,SAAA,IAAa,OAAA;AACjB,IAAI,cAAA,IAAkB,OAAA;AACtB,IAAI,OAAO,OAAO,CAAC,YAAA,KAAiB,UAAA;AACpC,IAAI,CAACC,yBAAc,CAAC,OAAO,CAAC,YAAY;AACxC,IAAI;AACJ,IAAI,OAAO,CAAC,YAAA,GAAe,IAAI,KAAK,CAAC,OAAO,CAAC,YAAY,EAAE;AAC3D,MAAM,KAAK,CAAC,MAAM,EAAE,OAAO,EAAE,IAAI,EAAE;AACnC,QAAQ,MAAM,CAAC,GAAG,EAAE,OAAO,CAAA,GAAI,IAAI;;AAEnC,QAAQC,uBAAkB,EAAE,EAAE,mBAAmB,CAAC,GAAG,EAAE,OAAO,CAAC;;AAE/D,QAAQ,OAAO,OAAO,CAAC,KAAK,CAAC,MAAM,EAAE,OAAO,EAAE,IAAI,CAAC;AACnD,MAAM,CAAC;AACP,KAAK,CAAC;;AAEN,IAAIC,6BAAkB,CAAC,OAAO,CAAC,YAAY,CAAC;AAC5C,EAAE;AACF;;;;"}
@@ -1 +1 @@
1
- {"type":"module","version":"10.44.0","sideEffects":false}
1
+ {"type":"module","version":"10.45.0","sideEffects":false}
@@ -1,11 +1,11 @@
1
1
  import { setAsyncLocalStorageAsyncContextStrategy } from './async.js';
2
2
  import { isInstrumented, markAsInstrumented } from './instrument.js';
3
- import { getHonoIntegration } from './integrations/hono.js';
4
3
  import { instrumentExportedHandlerEmail } from './instrumentations/worker/instrumentEmail.js';
5
4
  import { instrumentExportedHandlerFetch } from './instrumentations/worker/instrumentFetch.js';
6
5
  import { instrumentExportedHandlerQueue } from './instrumentations/worker/instrumentQueue.js';
7
6
  import { instrumentExportedHandlerScheduled } from './instrumentations/worker/instrumentScheduled.js';
8
7
  import { instrumentExportedHandlerTail } from './instrumentations/worker/instrumentTail.js';
8
+ import { getHonoIntegration } from './integrations/hono.js';
9
9
 
10
10
  /**
11
11
  * Wrapper for Cloudflare handlers.
@@ -1 +1 @@
1
- {"version":3,"file":"withSentry.js","sources":["../../src/withSentry.ts"],"sourcesContent":["import { setAsyncLocalStorageAsyncContextStrategy } from './async';\nimport type { CloudflareOptions } from './client';\nimport { isInstrumented, markAsInstrumented } from './instrument';\nimport { getHonoIntegration } from './integrations/hono';\nimport { instrumentExportedHandlerEmail } from './instrumentations/worker/instrumentEmail';\nimport { instrumentExportedHandlerFetch } from './instrumentations/worker/instrumentFetch';\nimport { instrumentExportedHandlerQueue } from './instrumentations/worker/instrumentQueue';\nimport { instrumentExportedHandlerScheduled } from './instrumentations/worker/instrumentScheduled';\nimport { instrumentExportedHandlerTail } from './instrumentations/worker/instrumentTail';\n\n/**\n * Wrapper for Cloudflare handlers.\n *\n * Initializes the SDK and wraps the handler with Sentry instrumentation.\n *\n * Automatically instruments the `fetch` method of the handler.\n *\n * @param optionsCallback Function that returns the options for the SDK initialization.\n * @param handler {ExportedHandler} The handler to wrap.\n * @returns The wrapped handler.\n */\nexport function withSentry<\n Env = unknown,\n QueueHandlerMessage = unknown,\n CfHostMetadata = unknown,\n T extends ExportedHandler<Env, QueueHandlerMessage, CfHostMetadata> = ExportedHandler<\n Env,\n QueueHandlerMessage,\n CfHostMetadata\n >,\n>(optionsCallback: (env: Env) => CloudflareOptions | undefined, handler: T): T {\n setAsyncLocalStorageAsyncContextStrategy();\n\n try {\n instrumentExportedHandlerFetch(handler, optionsCallback);\n instrumentHonoErrorHandler(handler);\n instrumentExportedHandlerScheduled(handler, optionsCallback);\n instrumentExportedHandlerEmail(handler, optionsCallback);\n instrumentExportedHandlerQueue(handler, optionsCallback);\n instrumentExportedHandlerTail(handler, optionsCallback);\n // This is here because Miniflare sometimes cannot get instrumented\n } catch {\n // Do not console anything here, we don't want to spam the console with errors\n }\n\n return handler;\n}\n\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nfunction instrumentHonoErrorHandler<T extends ExportedHandler<any, any, any>>(handler: T): void {\n if (\n 'onError' in handler &&\n 'errorHandler' in handler &&\n typeof handler.errorHandler === 'function' &&\n !isInstrumented(handler.errorHandler)\n ) {\n handler.errorHandler = new Proxy(handler.errorHandler, {\n apply(target, thisArg, args) {\n const [err, context] = args;\n\n getHonoIntegration()?.handleHonoException(err, context);\n\n return Reflect.apply(target, thisArg, args);\n },\n });\n\n markAsInstrumented(handler.errorHandler);\n }\n}\n"],"names":[],"mappings":";;;;;;;;;AAUA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACO,SAAS;;AAShB,CAAE,eAAe,EAA+C,OAAO,EAAQ;AAC/E,EAAE,wCAAwC,EAAE;;AAE5C,EAAE,IAAI;AACN,IAAI,8BAA8B,CAAC,OAAO,EAAE,eAAe,CAAC;AAC5D,IAAI,0BAA0B,CAAC,OAAO,CAAC;AACvC,IAAI,kCAAkC,CAAC,OAAO,EAAE,eAAe,CAAC;AAChE,IAAI,8BAA8B,CAAC,OAAO,EAAE,eAAe,CAAC;AAC5D,IAAI,8BAA8B,CAAC,OAAO,EAAE,eAAe,CAAC;AAC5D,IAAI,6BAA6B,CAAC,OAAO,EAAE,eAAe,CAAC;AAC3D;AACA,EAAE,EAAE,MAAM;AACV;AACA,EAAE;;AAEF,EAAE,OAAO,OAAO;AAChB;;AAEA;AACA,SAAS,0BAA0B,CAA2C,OAAO,EAAW;AAChG,EAAE;AACF,IAAI,SAAA,IAAa,OAAA;AACjB,IAAI,cAAA,IAAkB,OAAA;AACtB,IAAI,OAAO,OAAO,CAAC,YAAA,KAAiB,UAAA;AACpC,IAAI,CAAC,cAAc,CAAC,OAAO,CAAC,YAAY;AACxC,IAAI;AACJ,IAAI,OAAO,CAAC,YAAA,GAAe,IAAI,KAAK,CAAC,OAAO,CAAC,YAAY,EAAE;AAC3D,MAAM,KAAK,CAAC,MAAM,EAAE,OAAO,EAAE,IAAI,EAAE;AACnC,QAAQ,MAAM,CAAC,GAAG,EAAE,OAAO,CAAA,GAAI,IAAI;;AAEnC,QAAQ,kBAAkB,EAAE,EAAE,mBAAmB,CAAC,GAAG,EAAE,OAAO,CAAC;;AAE/D,QAAQ,OAAO,OAAO,CAAC,KAAK,CAAC,MAAM,EAAE,OAAO,EAAE,IAAI,CAAC;AACnD,MAAM,CAAC;AACP,KAAK,CAAC;;AAEN,IAAI,kBAAkB,CAAC,OAAO,CAAC,YAAY,CAAC;AAC5C,EAAE;AACF;;;;"}
1
+ {"version":3,"file":"withSentry.js","sources":["../../src/withSentry.ts"],"sourcesContent":["import type { env } from 'cloudflare:workers';\nimport { setAsyncLocalStorageAsyncContextStrategy } from './async';\nimport type { CloudflareOptions } from './client';\nimport { isInstrumented, markAsInstrumented } from './instrument';\nimport { instrumentExportedHandlerEmail } from './instrumentations/worker/instrumentEmail';\nimport { instrumentExportedHandlerFetch } from './instrumentations/worker/instrumentFetch';\nimport { instrumentExportedHandlerQueue } from './instrumentations/worker/instrumentQueue';\nimport { instrumentExportedHandlerScheduled } from './instrumentations/worker/instrumentScheduled';\nimport { instrumentExportedHandlerTail } from './instrumentations/worker/instrumentTail';\nimport { getHonoIntegration } from './integrations/hono';\n\n/**\n * Wrapper for Cloudflare handlers.\n *\n * Initializes the SDK and wraps the handler with Sentry instrumentation.\n *\n * Automatically instruments the `fetch` method of the handler.\n *\n * @param optionsCallback Function that returns the options for the SDK initialization.\n * @param handler {ExportedHandler} The handler to wrap.\n * @returns The wrapped handler.\n */\nexport function withSentry<\n Env = typeof env,\n QueueHandlerMessage = unknown,\n CfHostMetadata = unknown,\n T extends ExportedHandler<Env, QueueHandlerMessage, CfHostMetadata> = ExportedHandler<\n Env,\n QueueHandlerMessage,\n CfHostMetadata\n >,\n>(optionsCallback: (env: Env) => CloudflareOptions | undefined, handler: T): T {\n setAsyncLocalStorageAsyncContextStrategy();\n\n try {\n instrumentExportedHandlerFetch(handler, optionsCallback);\n instrumentHonoErrorHandler(handler);\n instrumentExportedHandlerScheduled(handler, optionsCallback);\n instrumentExportedHandlerEmail(handler, optionsCallback);\n instrumentExportedHandlerQueue(handler, optionsCallback);\n instrumentExportedHandlerTail(handler, optionsCallback);\n // This is here because Miniflare sometimes cannot get instrumented\n } catch {\n // Do not console anything here, we don't want to spam the console with errors\n }\n\n return handler;\n}\n\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nfunction instrumentHonoErrorHandler<T extends ExportedHandler<any, any, any>>(handler: T): void {\n if (\n 'onError' in handler &&\n 'errorHandler' in handler &&\n typeof handler.errorHandler === 'function' &&\n !isInstrumented(handler.errorHandler)\n ) {\n handler.errorHandler = new Proxy(handler.errorHandler, {\n apply(target, thisArg, args) {\n const [err, context] = args;\n\n getHonoIntegration()?.handleHonoException(err, context);\n\n return Reflect.apply(target, thisArg, args);\n },\n });\n\n markAsInstrumented(handler.errorHandler);\n }\n}\n"],"names":[],"mappings":";;;;;;;;;AAWA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACO,SAAS;;AAShB,CAAE,eAAe,EAA+C,OAAO,EAAQ;AAC/E,EAAE,wCAAwC,EAAE;;AAE5C,EAAE,IAAI;AACN,IAAI,8BAA8B,CAAC,OAAO,EAAE,eAAe,CAAC;AAC5D,IAAI,0BAA0B,CAAC,OAAO,CAAC;AACvC,IAAI,kCAAkC,CAAC,OAAO,EAAE,eAAe,CAAC;AAChE,IAAI,8BAA8B,CAAC,OAAO,EAAE,eAAe,CAAC;AAC5D,IAAI,8BAA8B,CAAC,OAAO,EAAE,eAAe,CAAC;AAC5D,IAAI,6BAA6B,CAAC,OAAO,EAAE,eAAe,CAAC;AAC3D;AACA,EAAE,EAAE,MAAM;AACV;AACA,EAAE;;AAEF,EAAE,OAAO,OAAO;AAChB;;AAEA;AACA,SAAS,0BAA0B,CAA2C,OAAO,EAAW;AAChG,EAAE;AACF,IAAI,SAAA,IAAa,OAAA;AACjB,IAAI,cAAA,IAAkB,OAAA;AACtB,IAAI,OAAO,OAAO,CAAC,YAAA,KAAiB,UAAA;AACpC,IAAI,CAAC,cAAc,CAAC,OAAO,CAAC,YAAY;AACxC,IAAI;AACJ,IAAI,OAAO,CAAC,YAAA,GAAe,IAAI,KAAK,CAAC,OAAO,CAAC,YAAY,EAAE;AAC3D,MAAM,KAAK,CAAC,MAAM,EAAE,OAAO,EAAE,IAAI,EAAE;AACnC,QAAQ,MAAM,CAAC,GAAG,EAAE,OAAO,CAAA,GAAI,IAAI;;AAEnC,QAAQ,kBAAkB,EAAE,EAAE,mBAAmB,CAAC,GAAG,EAAE,OAAO,CAAC;;AAE/D,QAAQ,OAAO,OAAO,CAAC,KAAK,CAAC,MAAM,EAAE,OAAO,EAAE,IAAI,CAAC;AACnD,MAAM,CAAC;AACP,KAAK,CAAC;;AAEN,IAAI,kBAAkB,CAAC,OAAO,CAAC,YAAY,CAAC;AAC5C,EAAE;AACF;;;;"}
@@ -1,3 +1,4 @@
1
+ import type { env } from 'cloudflare:workers';
1
2
  import type { CloudflareOptions } from './client';
2
3
  /**
3
4
  * Wrapper for Cloudflare handlers.
@@ -10,5 +11,5 @@ import type { CloudflareOptions } from './client';
10
11
  * @param handler {ExportedHandler} The handler to wrap.
11
12
  * @returns The wrapped handler.
12
13
  */
13
- export declare function withSentry<Env = unknown, QueueHandlerMessage = unknown, CfHostMetadata = unknown, T extends ExportedHandler<Env, QueueHandlerMessage, CfHostMetadata> = ExportedHandler<Env, QueueHandlerMessage, CfHostMetadata>>(optionsCallback: (env: Env) => CloudflareOptions | undefined, handler: T): T;
14
+ export declare function withSentry<Env = typeof env, QueueHandlerMessage = unknown, CfHostMetadata = unknown, T extends ExportedHandler<Env, QueueHandlerMessage, CfHostMetadata> = ExportedHandler<Env, QueueHandlerMessage, CfHostMetadata>>(optionsCallback: (env: Env) => CloudflareOptions | undefined, handler: T): T;
14
15
  //# sourceMappingURL=withSentry.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"withSentry.d.ts","sourceRoot":"","sources":["../../src/withSentry.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,UAAU,CAAC;AASlD;;;;;;;;;;GAUG;AACH,wBAAgB,UAAU,CACxB,GAAG,GAAG,OAAO,EACb,mBAAmB,GAAG,OAAO,EAC7B,cAAc,GAAG,OAAO,EACxB,CAAC,SAAS,eAAe,CAAC,GAAG,EAAE,mBAAmB,EAAE,cAAc,CAAC,GAAG,eAAe,CACnF,GAAG,EACH,mBAAmB,EACnB,cAAc,CACf,EACD,eAAe,EAAE,CAAC,GAAG,EAAE,GAAG,KAAK,iBAAiB,GAAG,SAAS,EAAE,OAAO,EAAE,CAAC,GAAG,CAAC,CAgB7E"}
1
+ {"version":3,"file":"withSentry.d.ts","sourceRoot":"","sources":["../../src/withSentry.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,oBAAoB,CAAC;AAE9C,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,UAAU,CAAC;AASlD;;;;;;;;;;GAUG;AACH,wBAAgB,UAAU,CACxB,GAAG,GAAG,OAAO,GAAG,EAChB,mBAAmB,GAAG,OAAO,EAC7B,cAAc,GAAG,OAAO,EACxB,CAAC,SAAS,eAAe,CAAC,GAAG,EAAE,mBAAmB,EAAE,cAAc,CAAC,GAAG,eAAe,CACnF,GAAG,EACH,mBAAmB,EACnB,cAAc,CACf,EACD,eAAe,EAAE,CAAC,GAAG,EAAE,GAAG,KAAK,iBAAiB,GAAG,SAAS,EAAE,OAAO,EAAE,CAAC,GAAG,CAAC,CAgB7E"}
@@ -1,3 +1,4 @@
1
+ import { env } from 'cloudflare:workers';
1
2
  import { CloudflareOptions } from './client';
2
3
  /**
3
4
  * Wrapper for Cloudflare handlers.
@@ -10,5 +11,5 @@ import { CloudflareOptions } from './client';
10
11
  * @param handler {ExportedHandler} The handler to wrap.
11
12
  * @returns The wrapped handler.
12
13
  */
13
- export declare function withSentry<Env = unknown, QueueHandlerMessage = unknown, CfHostMetadata = unknown, T extends ExportedHandler<Env, QueueHandlerMessage, CfHostMetadata> = ExportedHandler<Env, QueueHandlerMessage, CfHostMetadata>>(optionsCallback: (env: Env) => CloudflareOptions | undefined, handler: T): T;
14
+ export declare function withSentry<Env = typeof env, QueueHandlerMessage = unknown, CfHostMetadata = unknown, T extends ExportedHandler<Env, QueueHandlerMessage, CfHostMetadata> = ExportedHandler<Env, QueueHandlerMessage, CfHostMetadata>>(optionsCallback: (env: Env) => CloudflareOptions | undefined, handler: T): T;
14
15
  //# sourceMappingURL=withSentry.d.ts.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sentry/cloudflare",
3
- "version": "10.44.0",
3
+ "version": "10.45.0",
4
4
  "description": "Official Sentry SDK for Cloudflare Workers and Pages",
5
5
  "repository": "git://github.com/getsentry/sentry-javascript.git",
6
6
  "homepage": "https://github.com/getsentry/sentry-javascript/tree/master/packages/cloudflare",
@@ -50,7 +50,7 @@
50
50
  },
51
51
  "dependencies": {
52
52
  "@opentelemetry/api": "^1.9.0",
53
- "@sentry/core": "10.44.0"
53
+ "@sentry/core": "10.45.0"
54
54
  },
55
55
  "peerDependencies": {
56
56
  "@cloudflare/workers-types": "^4.x"