girder-sentry 5.0.2.dev2__tar.gz → 5.0.2.dev6__tar.gz
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.
- {girder_sentry-5.0.2.dev2 → girder_sentry-5.0.2.dev6}/PKG-INFO +1 -1
- girder_sentry-5.0.2.dev6/girder_sentry/web_client/dist/girder-plugin-sentry.umd.cjs +7 -0
- {girder_sentry-5.0.2.dev2 → girder_sentry-5.0.2.dev6}/girder_sentry.egg-info/PKG-INFO +1 -1
- girder_sentry-5.0.2.dev2/girder_sentry/web_client/dist/girder-plugin-sentry.umd.cjs +0 -7
- {girder_sentry-5.0.2.dev2 → girder_sentry-5.0.2.dev6}/MANIFEST.in +0 -0
- {girder_sentry-5.0.2.dev2 → girder_sentry-5.0.2.dev6}/girder_sentry/__init__.py +0 -0
- {girder_sentry-5.0.2.dev2 → girder_sentry-5.0.2.dev6}/girder_sentry/rest.py +0 -0
- {girder_sentry-5.0.2.dev2 → girder_sentry-5.0.2.dev6}/girder_sentry/settings.py +0 -0
- {girder_sentry-5.0.2.dev2 → girder_sentry-5.0.2.dev6}/girder_sentry/web_client/dist/style.css +0 -0
- {girder_sentry-5.0.2.dev2 → girder_sentry-5.0.2.dev6}/girder_sentry.egg-info/SOURCES.txt +0 -0
- {girder_sentry-5.0.2.dev2 → girder_sentry-5.0.2.dev6}/girder_sentry.egg-info/dependency_links.txt +0 -0
- {girder_sentry-5.0.2.dev2 → girder_sentry-5.0.2.dev6}/girder_sentry.egg-info/entry_points.txt +0 -0
- {girder_sentry-5.0.2.dev2 → girder_sentry-5.0.2.dev6}/girder_sentry.egg-info/not-zip-safe +0 -0
- {girder_sentry-5.0.2.dev2 → girder_sentry-5.0.2.dev6}/girder_sentry.egg-info/requires.txt +0 -0
- {girder_sentry-5.0.2.dev2 → girder_sentry-5.0.2.dev6}/girder_sentry.egg-info/top_level.txt +0 -0
- {girder_sentry-5.0.2.dev2 → girder_sentry-5.0.2.dev6}/plugin.cmake +0 -0
- {girder_sentry-5.0.2.dev2 → girder_sentry-5.0.2.dev6}/pyproject.toml +0 -0
- {girder_sentry-5.0.2.dev2 → girder_sentry-5.0.2.dev6}/setup.cfg +0 -0
- {girder_sentry-5.0.2.dev2 → girder_sentry-5.0.2.dev6}/setup.py +0 -0
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
(function(e){typeof define==`function`&&define.amd?define([],e):e()})(function(){var e=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),t=typeof __SENTRY_DEBUG__>`u`||__SENTRY_DEBUG__,n=globalThis,r=`10.47.0`;function i(){return a(n),n}function a(e){let t=e.__SENTRY__=e.__SENTRY__||{};return t.version=t.version||`10.47.0`,t[r]=t[`10.47.0`]||{}}function o(e,t,i=n){let a=i.__SENTRY__=i.__SENTRY__||{},o=a[r]=a[`10.47.0`]||{};return o[e]||(o[e]=t())}var s=[`debug`,`info`,`warn`,`error`,`log`,`assert`,`trace`],c=`Sentry Logger `,l={};function u(e){if(!(`console`in n))return e();let t=n.console,r={},i=Object.keys(l);i.forEach(e=>{let n=l[e];r[e]=t[e],t[e]=n});try{return e()}finally{i.forEach(e=>{t[e]=r[e]})}}function d(){ie().enabled=!0}function f(){ie().enabled=!1}function p(){return ie().enabled}function ee(...e){re(`log`,...e)}function te(...e){re(`warn`,...e)}function ne(...e){re(`error`,...e)}function re(e,...r){t&&p()&&u(()=>{n.console[e](`${c}[${e}]:`,...r)})}function ie(){return t?o(`loggerSettings`,()=>({enabled:!1})):{enabled:!1}}var m={enable:d,disable:f,isEnabled:p,log:ee,warn:te,error:ne},ae=50,oe=/\(error: (.*)\)/,se=/captureMessage|captureException/;function ce(...e){let t=e.sort((e,t)=>e[0]-t[0]).map(e=>e[1]);return(e,n=0,r=0)=>{let i=[],a=e.split(`
|
|
2
|
+
`);for(let e=n;e<a.length;e++){let n=a[e];n.length>1024&&(n=n.slice(0,1024));let o=oe.test(n)?n.replace(oe,`$1`):n;if(!o.match(/\S*Error: /)){for(let e of t){let t=e(o);if(t){i.push(t);break}}if(i.length>=ae+r)break}}return ue(i.slice(r))}}function le(e){return Array.isArray(e)?ce(...e):e}function ue(e){if(!e.length)return[];let t=Array.from(e);return/sentryWrapped/.test(de(t).function||``)&&t.pop(),t.reverse(),se.test(de(t).function||``)&&(t.pop(),se.test(de(t).function||``)&&t.pop()),t.slice(0,ae).map(e=>({...e,filename:e.filename||de(t).filename,function:e.function||`?`}))}function de(e){return e[e.length-1]||{}}var fe=`<anonymous>`;function h(e){try{return!e||typeof e!=`function`?fe:e.name||fe}catch{return fe}}function pe(e){let t=e.exception;if(t){let e=[];try{return t.values.forEach(t=>{t.stacktrace.frames&&e.push(...t.stacktrace.frames)}),e}catch{return}}}function me(e){return`__v_isVNode`in e&&e.__v_isVNode?`[VueVNode]`:`[VueViewModel]`}var he={},ge={};function g(e,t){he[e]=he[e]||[],he[e].push(t)}function _(e,n){if(!ge[e]){ge[e]=!0;try{n()}catch(n){t&&m.error(`Error while instrumenting ${e}`,n)}}}function v(e,n){let r=e&&he[e];if(r)for(let i of r)try{i(n)}catch(n){t&&m.error(`Error while triggering instrumentation handler.\nType: ${e}\nName: ${h(i)}\nError:`,n)}}var _e=null;function ve(e){let t=`error`;g(t,e),_(t,ye)}function ye(){_e=n.onerror,n.onerror=function(e,t,n,r,i){return v(`error`,{column:r,error:i,line:n,msg:e,url:t}),_e?_e.apply(this,arguments):!1},n.onerror.__SENTRY_INSTRUMENTED__=!0}var be=null;function xe(e){let t=`unhandledrejection`;g(t,e),_(t,Se)}function Se(){be=n.onunhandledrejection,n.onunhandledrejection=function(e){return v(`unhandledrejection`,e),be?be.apply(this,arguments):!0},n.onunhandledrejection.__SENTRY_INSTRUMENTED__=!0}var Ce=Object.prototype.toString;function y(e){switch(Ce.call(e)){case`[object Error]`:case`[object Exception]`:case`[object DOMException]`:case`[object WebAssembly.Exception]`:return!0;default:return w(e,Error)}}function b(e,t){return Ce.call(e)===`[object ${t}]`}function we(e){return b(e,`ErrorEvent`)}function Te(e){return b(e,`DOMError`)}function Ee(e){return b(e,`DOMException`)}function x(e){return b(e,`String`)}function De(e){return typeof e==`object`&&!!e&&`__sentry_template_string__`in e&&`__sentry_template_values__`in e}function Oe(e){return e===null||De(e)||typeof e!=`object`&&typeof e!=`function`}function S(e){return b(e,`Object`)}function ke(e){return typeof Event<`u`&&w(e,Event)}function Ae(e){return typeof Element<`u`&&w(e,Element)}function je(e){return b(e,`RegExp`)}function C(e){return!!(e?.then&&typeof e.then==`function`)}function Me(e){return S(e)&&`nativeEvent`in e&&`preventDefault`in e&&`stopPropagation`in e}function w(e,t){try{return e instanceof t}catch{return!1}}function Ne(e){return!!(typeof e==`object`&&e&&(e.__isVue||e._isVue||e.__v_isVNode))}function Pe(e){return typeof Request<`u`&&w(e,Request)}var Fe=n,Ie=80;function Le(e,t={}){if(!e)return`<unknown>`;try{let n=e,r=[],i=0,a=0,o,s=Array.isArray(t)?t:t.keyAttrs,c=!Array.isArray(t)&&t.maxStringLength||Ie;for(;n&&i++<5&&(o=Re(n,s),!(o===`html`||i>1&&a+r.length*3+o.length>=c));)r.push(o),a+=o.length,n=n.parentNode;return r.reverse().join(` > `)}catch{return`<unknown>`}}function Re(e,t){let n=e,r=[];if(!n?.tagName)return``;if(Fe.HTMLElement&&n instanceof HTMLElement&&n.dataset){if(n.dataset.sentryComponent)return n.dataset.sentryComponent;if(n.dataset.sentryElement)return n.dataset.sentryElement}r.push(n.tagName.toLowerCase());let i=t?.length?t.filter(e=>n.getAttribute(e)).map(e=>[e,n.getAttribute(e)]):null;if(i?.length)i.forEach(e=>{r.push(`[${e[0]}="${e[1]}"]`)});else{n.id&&r.push(`#${n.id}`);let e=n.className;if(e&&x(e)){let t=e.split(/\s+/);for(let e of t)r.push(`.${e}`)}}for(let e of[`aria-label`,`type`,`name`,`title`,`alt`]){let t=n.getAttribute(e);t&&r.push(`[${e}="${t}"]`)}return r.join(``)}function ze(){try{return Fe.document.location.href}catch{return``}}function Be(e){if(!Fe.HTMLElement)return null;let t=e;for(let e=0;e<5;e++){if(!t)return null;if(t instanceof HTMLElement){if(t.dataset.sentryComponent)return t.dataset.sentryComponent;if(t.dataset.sentryElement)return t.dataset.sentryElement}t=t.parentNode}return null}function T(e,n,r){if(!(n in e))return;let i=e[n];if(typeof i!=`function`)return;let a=r(i);typeof a==`function`&&Ve(a,i);try{e[n]=a}catch{t&&m.log(`Failed to replace method "${n}" in object`,e)}}function E(e,n,r){try{Object.defineProperty(e,n,{value:r,writable:!0,configurable:!0})}catch{t&&m.log(`Failed to add non-enumerable property "${n}" to object`,e)}}function Ve(e,t){try{e.prototype=t.prototype=t.prototype||{},E(e,`__sentry_original__`,t)}catch{}}function He(e){return e.__sentry_original__}function Ue(e){if(y(e))return{message:e.message,name:e.name,stack:e.stack,...Ge(e)};if(ke(e)){let t={type:e.type,target:We(e.target),currentTarget:We(e.currentTarget),...Ge(e)};return typeof CustomEvent<`u`&&w(e,CustomEvent)&&(t.detail=e.detail),t}else return e}function We(e){try{return Ae(e)?Le(e):Object.prototype.toString.call(e)}catch{return`<unknown>`}}function Ge(e){return typeof e==`object`&&e?Object.fromEntries(Object.entries(e)):{}}function Ke(e){let t=Object.keys(Ue(e));return t.sort(),t[0]?t.join(`, `):`[object has no keys]`}var D;function qe(e){if(D!==void 0)return D?D(e):e();let t=Symbol.for(`__SENTRY_SAFE_RANDOM_ID_WRAPPER__`),r=n;return t in r&&typeof r[t]==`function`?(D=r[t],D(e)):(D=null,e())}function Je(){return qe(()=>Math.random())}function Ye(){return qe(()=>Date.now())}function Xe(e,t=0){return typeof e!=`string`||t===0||e.length<=t?e:`${e.slice(0,t)}...`}function Ze(e,t){if(!Array.isArray(e))return``;let n=[];for(let t=0;t<e.length;t++){let r=e[t];try{Ne(r)?n.push(me(r)):n.push(String(r))}catch{n.push(`[value cannot be serialized]`)}}return n.join(t)}function Qe(e,t,n=!1){return x(e)?je(t)?t.test(e):x(t)?n?e===t:e.includes(t):!1:!1}function $e(e,t=[],n=!1){return t.some(t=>Qe(e,t,n))}function et(){let e=n;return e.crypto||e.msCrypto}var tt;function nt(){return Je()*16}function O(e=et()){try{if(e?.randomUUID)return qe(()=>e.randomUUID()).replace(/-/g,``)}catch{}return tt||=`10000000100040008000100000000000`,tt.replace(/[018]/g,e=>(e^(nt()&15)>>e/4).toString(16))}function rt(e){return e.exception?.values?.[0]}function k(e){let{message:t,event_id:n}=e;if(t)return t;let r=rt(e);return r?r.type&&r.value?`${r.type}: ${r.value}`:r.type||r.value||n||`<unknown>`:n||`<unknown>`}function it(e,t,n){let r=e.exception=e.exception||{},i=r.values=r.values||[],a=i[0]=i[0]||{};a.value||=t||``,a.type||=n||`Error`}function A(e,t){let n=rt(e);if(!n)return;let r={type:`generic`,handled:!0},i=n.mechanism;if(n.mechanism={...r,...i,...t},t&&`data`in t){let e={...i?.data,...t.data};n.mechanism.data=e}}function at(e){if(ot(e))return!0;try{E(e,`__sentry_captured__`,!0)}catch{}return!1}function ot(e){try{return e.__sentry_captured__}catch{}}var st=1e3;function j(){return Ye()/st}function ct(){let{performance:e}=n;if(!e?.now||!e.timeOrigin)return j;let t=e.timeOrigin;return()=>(t+qe(()=>e.now()))/st}var lt;function M(){return(lt??=ct())()}function ut(e){let t=M(),n={sid:O(),init:!0,timestamp:t,started:t,duration:0,status:`ok`,errors:0,ignoreDuration:!1,toJSON:()=>ft(n)};return e&&N(n,e),n}function N(e,t={}){if(t.user&&(!e.ipAddress&&t.user.ip_address&&(e.ipAddress=t.user.ip_address),!e.did&&!t.did&&(e.did=t.user.id||t.user.email||t.user.username)),e.timestamp=t.timestamp||M(),t.abnormal_mechanism&&(e.abnormal_mechanism=t.abnormal_mechanism),t.ignoreDuration&&(e.ignoreDuration=t.ignoreDuration),t.sid&&(e.sid=t.sid.length===32?t.sid:O()),t.init!==void 0&&(e.init=t.init),!e.did&&t.did&&(e.did=`${t.did}`),typeof t.started==`number`&&(e.started=t.started),e.ignoreDuration)e.duration=void 0;else if(typeof t.duration==`number`)e.duration=t.duration;else{let t=e.timestamp-e.started;e.duration=t>=0?t:0}t.release&&(e.release=t.release),t.environment&&(e.environment=t.environment),!e.ipAddress&&t.ipAddress&&(e.ipAddress=t.ipAddress),!e.userAgent&&t.userAgent&&(e.userAgent=t.userAgent),typeof t.errors==`number`&&(e.errors=t.errors),t.status&&(e.status=t.status)}function dt(e,t){let n={};t?n={status:t}:e.status===`ok`&&(n={status:`exited`}),N(e,n)}function ft(e){return{sid:`${e.sid}`,init:e.init,started:new Date(e.started*1e3).toISOString(),timestamp:new Date(e.timestamp*1e3).toISOString(),status:e.status,errors:e.errors,did:typeof e.did==`number`||typeof e.did==`string`?`${e.did}`:void 0,duration:e.duration,abnormal_mechanism:e.abnormal_mechanism,attrs:{release:e.release,environment:e.environment,ip_address:e.ipAddress,user_agent:e.userAgent}}}function P(e,t,n=2){if(!t||typeof t!=`object`||n<=0)return t;if(e&&Object.keys(t).length===0)return e;let r={...e};for(let e in t)Object.prototype.hasOwnProperty.call(t,e)&&(r[e]=P(r[e],t[e],n-1));return r}function pt(){return O()}function mt(){return O().substring(16)}var ht=`_sentrySpan`;function gt(e,t){t?E(e,ht,t):delete e[ht]}function _t(e){return e[ht]}var vt=100,F=class e{constructor(){this._notifyingListeners=!1,this._scopeListeners=[],this._eventProcessors=[],this._breadcrumbs=[],this._attachments=[],this._user={},this._tags={},this._attributes={},this._extra={},this._contexts={},this._sdkProcessingMetadata={},this._propagationContext={traceId:pt(),sampleRand:Je()}}clone(){let t=new e;return t._breadcrumbs=[...this._breadcrumbs],t._tags={...this._tags},t._attributes={...this._attributes},t._extra={...this._extra},t._contexts={...this._contexts},this._contexts.flags&&(t._contexts.flags={values:[...this._contexts.flags.values]}),t._user=this._user,t._level=this._level,t._session=this._session,t._transactionName=this._transactionName,t._fingerprint=this._fingerprint,t._eventProcessors=[...this._eventProcessors],t._attachments=[...this._attachments],t._sdkProcessingMetadata={...this._sdkProcessingMetadata},t._propagationContext={...this._propagationContext},t._client=this._client,t._lastEventId=this._lastEventId,t._conversationId=this._conversationId,gt(t,_t(this)),t}setClient(e){this._client=e}setLastEventId(e){this._lastEventId=e}getClient(){return this._client}lastEventId(){return this._lastEventId}addScopeListener(e){this._scopeListeners.push(e)}addEventProcessor(e){return this._eventProcessors.push(e),this}setUser(e){return this._user=e||{email:void 0,id:void 0,ip_address:void 0,username:void 0},this._session&&N(this._session,{user:e}),this._notifyScopeListeners(),this}getUser(){return this._user}setConversationId(e){return this._conversationId=e||void 0,this._notifyScopeListeners(),this}setTags(e){return this._tags={...this._tags,...e},this._notifyScopeListeners(),this}setTag(e,t){return this.setTags({[e]:t})}setAttributes(e){return this._attributes={...this._attributes,...e},this._notifyScopeListeners(),this}setAttribute(e,t){return this.setAttributes({[e]:t})}removeAttribute(e){return e in this._attributes&&(delete this._attributes[e],this._notifyScopeListeners()),this}setExtras(e){return this._extra={...this._extra,...e},this._notifyScopeListeners(),this}setExtra(e,t){return this._extra={...this._extra,[e]:t},this._notifyScopeListeners(),this}setFingerprint(e){return this._fingerprint=e,this._notifyScopeListeners(),this}setLevel(e){return this._level=e,this._notifyScopeListeners(),this}setTransactionName(e){return this._transactionName=e,this._notifyScopeListeners(),this}setContext(e,t){return t===null?delete this._contexts[e]:this._contexts[e]=t,this._notifyScopeListeners(),this}setSession(e){return e?this._session=e:delete this._session,this._notifyScopeListeners(),this}getSession(){return this._session}update(t){if(!t)return this;let n=typeof t==`function`?t(this):t,{tags:r,attributes:i,extra:a,user:o,contexts:s,level:c,fingerprint:l=[],propagationContext:u,conversationId:d}=(n instanceof e?n.getScopeData():S(n)?t:void 0)||{};return this._tags={...this._tags,...r},this._attributes={...this._attributes,...i},this._extra={...this._extra,...a},this._contexts={...this._contexts,...s},o&&Object.keys(o).length&&(this._user=o),c&&(this._level=c),l.length&&(this._fingerprint=l),u&&(this._propagationContext=u),d&&(this._conversationId=d),this}clear(){return this._breadcrumbs=[],this._tags={},this._attributes={},this._extra={},this._user={},this._contexts={},this._level=void 0,this._transactionName=void 0,this._fingerprint=void 0,this._session=void 0,this._conversationId=void 0,gt(this,void 0),this._attachments=[],this.setPropagationContext({traceId:pt(),sampleRand:Je()}),this._notifyScopeListeners(),this}addBreadcrumb(e,t){let n=typeof t==`number`?t:vt;if(n<=0)return this;let r={timestamp:j(),...e,message:e.message?Xe(e.message,2048):e.message};return this._breadcrumbs.push(r),this._breadcrumbs.length>n&&(this._breadcrumbs=this._breadcrumbs.slice(-n),this._client?.recordDroppedEvent(`buffer_overflow`,`log_item`)),this._notifyScopeListeners(),this}getLastBreadcrumb(){return this._breadcrumbs[this._breadcrumbs.length-1]}clearBreadcrumbs(){return this._breadcrumbs=[],this._notifyScopeListeners(),this}addAttachment(e){return this._attachments.push(e),this}clearAttachments(){return this._attachments=[],this}getScopeData(){return{breadcrumbs:this._breadcrumbs,attachments:this._attachments,contexts:this._contexts,tags:this._tags,attributes:this._attributes,extra:this._extra,user:this._user,level:this._level,fingerprint:this._fingerprint||[],eventProcessors:this._eventProcessors,propagationContext:this._propagationContext,sdkProcessingMetadata:this._sdkProcessingMetadata,transactionName:this._transactionName,span:_t(this),conversationId:this._conversationId}}setSDKProcessingMetadata(e){return this._sdkProcessingMetadata=P(this._sdkProcessingMetadata,e,2),this}setPropagationContext(e){return this._propagationContext=e,this}getPropagationContext(){return this._propagationContext}captureException(e,n){let r=n?.event_id||O();if(!this._client)return t&&m.warn(`No client configured on scope - will not capture exception!`),r;let i=Error(`Sentry syntheticException`);return this._client.captureException(e,{originalException:e,syntheticException:i,...n,event_id:r},this),r}captureMessage(e,n,r){let i=r?.event_id||O();if(!this._client)return t&&m.warn(`No client configured on scope - will not capture message!`),i;let a=r?.syntheticException??Error(e);return this._client.captureMessage(e,n,{originalException:e,syntheticException:a,...r,event_id:i},this),i}captureEvent(e,n){let r=e.event_id||n?.event_id||O();return this._client?(this._client.captureEvent(e,{...n,event_id:r},this),r):(t&&m.warn(`No client configured on scope - will not capture event!`),r)}_notifyScopeListeners(){this._notifyingListeners||=(this._notifyingListeners=!0,this._scopeListeners.forEach(e=>{e(this)}),!1)}};function yt(){return o(`defaultCurrentScope`,()=>new F)}function bt(){return o(`defaultIsolationScope`,()=>new F)}var xt=e=>e instanceof Promise&&!e[St],St=Symbol(`chained PromiseLike`),Ct=(e,t,n)=>{let r=e.then(e=>(t(e),e),e=>{throw n(e),e});return xt(r)&&xt(e)?r:wt(e,r)},wt=(e,t)=>{let n=!1;for(let r in e){if(r in t)continue;n=!0;let i=e[r];typeof i==`function`?Object.defineProperty(t,r,{value:(...t)=>i.apply(e,t),enumerable:!0,configurable:!0,writable:!0}):t[r]=i}return n&&Object.assign(t,{[St]:!0}),t},Tt=class{constructor(e,t){let n;n=e||new F;let r;r=t||new F,this._stack=[{scope:n}],this._isolationScope=r}withScope(e){let t=this._pushScope(),n;try{n=e(t)}catch(e){throw this._popScope(),e}return C(n)?Ct(n,()=>this._popScope(),()=>this._popScope()):(this._popScope(),n)}getClient(){return this.getStackTop().client}getScope(){return this.getStackTop().scope}getIsolationScope(){return this._isolationScope}getStackTop(){return this._stack[this._stack.length-1]}_pushScope(){let e=this.getScope().clone();return this._stack.push({client:this.getClient(),scope:e}),e}_popScope(){return this._stack.length<=1?!1:!!this._stack.pop()}};function I(){let e=a(i());return e.stack=e.stack||new Tt(yt(),bt())}function Et(e){return I().withScope(e)}function Dt(e,t){let n=I();return n.withScope(()=>(n.getStackTop().scope=e,t(e)))}function Ot(e){return I().withScope(()=>e(I().getIsolationScope()))}function kt(){return{withIsolationScope:Ot,withScope:Et,withSetScope:Dt,withSetIsolationScope:(e,t)=>Ot(t),getCurrentScope:()=>I().getScope(),getIsolationScope:()=>I().getIsolationScope()}}function At(e){let t=a(e);return t.acs?t.acs:kt()}var jt;function Mt(){return jt?.()}function L(){return At(i()).getCurrentScope()}function R(){return At(i()).getIsolationScope()}function Nt(){return o(`globalScope`,()=>new F)}function Pt(...e){let t=At(i());if(e.length===2){let[n,r]=e;return n?t.withSetScope(n,r):t.withScope(r)}return t.withScope(e[0])}function z(){return L().getClient()}function Ft(e){let t=Mt();if(t)return{trace_id:t.traceId,span_id:t.spanId};let{traceId:n,parentSpanId:r,propagationSpanId:i}=e.getPropagationContext(),a={trace_id:n,span_id:i||mt()};return r&&(a.parent_span_id=r),a}var It=`sentry.source`,Lt=`sentry.op`,Rt=`sentry.origin`,zt=`sentry.profile_id`,Bt=`sentry.exclusive_time`,Vt=`gen_ai.conversation.id`,Ht=`_sentryScope`,Ut=`_sentryIsolationScope`;function Wt(e){if(e){if(typeof e==`object`&&`deref`in e&&typeof e.deref==`function`)try{return e.deref()}catch{return}return e}}function Gt(e){let t=e;return{scope:t[Ht],isolationScope:Wt(t[Ut])}}function Kt(e){let t=qt(e);if(!t)return;let n=Object.entries(t).reduce((e,[t,n])=>{if(t.startsWith(`sentry-`)){let r=t.slice(7);e[r]=n}return e},{});if(Object.keys(n).length>0)return n}function qt(e){if(!(!e||!x(e)&&!Array.isArray(e)))return Array.isArray(e)?e.reduce((e,t)=>{let n=Jt(t);return Object.entries(n).forEach(([t,n])=>{e[t]=n}),e},{}):Jt(e)}function Jt(e){return e.split(`,`).map(e=>{let t=e.indexOf(`=`);return t===-1?[]:[e.slice(0,t),e.slice(t+1)].map(e=>{try{return decodeURIComponent(e.trim())}catch{return}})}).reduce((e,[t,n])=>(t&&n&&(e[t]=n),e),{})}var Yt=/^o(\d+)\./,Xt=/^(?:(\w+):)\/\/(?:(\w+)(?::(\w+)?)?@)((?:\[[:.%\w]+\]|[\w.-]+))(?::(\d+))?\/(.+)/;function Zt(e){return e===`http`||e===`https`}function B(e,t=!1){let{host:n,path:r,pass:i,port:a,projectId:o,protocol:s,publicKey:c}=e;return`${s}://${c}${t&&i?`:${i}`:``}@${n}${a?`:${a}`:``}/${r&&`${r}/`}${o}`}function Qt(e){let t=Xt.exec(e);if(!t){u(()=>{console.error(`Invalid Sentry Dsn: ${e}`)});return}let[n,r,i=``,a=``,o=``,s=``]=t.slice(1),c=``,l=s,d=l.split(`/`);if(d.length>1&&(c=d.slice(0,-1).join(`/`),l=d.pop()),l){let e=l.match(/^\d+/);e&&(l=e[0])}return $t({host:a,pass:i,path:c,projectId:l,port:o,protocol:n,publicKey:r})}function $t(e){return{protocol:e.protocol,publicKey:e.publicKey||``,pass:e.pass||``,host:e.host,port:e.port||``,path:e.path||``,projectId:e.projectId}}function en(e){if(!t)return!0;let{port:n,projectId:r,protocol:i}=e;return[`protocol`,`publicKey`,`host`,`projectId`].find(t=>e[t]?!1:(m.error(`Invalid Sentry Dsn: ${t} missing`),!0))?!1:r.match(/^\d+$/)?Zt(i)?n&&isNaN(parseInt(n,10))?(m.error(`Invalid Sentry Dsn: Invalid port ${n}`),!1):!0:(m.error(`Invalid Sentry Dsn: Invalid protocol ${i}`),!1):(m.error(`Invalid Sentry Dsn: Invalid projectId ${r}`),!1)}function tn(e){return e.match(Yt)?.[1]}function nn(e){let t=e.getOptions(),{host:n}=e.getDsn()||{},r;return t.orgId?r=String(t.orgId):n&&(r=tn(n)),r}function rn(e){let t=typeof e==`string`?Qt(e):$t(e);if(!(!t||!en(t)))return t}function an(e){if(typeof e==`boolean`)return Number(e);let t=typeof e==`string`?parseFloat(e):e;if(!(typeof t!=`number`||isNaN(t)||t<0||t>1))return t}var on=!1;function sn(e){let{spanId:t,traceId:n,isRemote:r}=e.spanContext(),i=r?t:dn(e).parent_span_id,a=Gt(e).scope;return{parent_span_id:i,span_id:r?a?.getPropagationContext().propagationSpanId||mt():t,trace_id:n}}function cn(e){if(e&&e.length>0)return e.map(({context:{spanId:e,traceId:t,traceFlags:n,...r},attributes:i})=>({span_id:e,trace_id:t,sampled:n===1,attributes:i,...r}))}function ln(e){return typeof e==`number`?un(e):Array.isArray(e)?e[0]+e[1]/1e9:e instanceof Date?un(e.getTime()):M()}function un(e){return e>9999999999?e/1e3:e}function dn(e){if(pn(e))return e.getSpanJSON();let{spanId:t,traceId:n}=e.spanContext();if(fn(e)){let{attributes:r,startTime:i,name:a,endTime:o,status:s,links:c}=e;return{span_id:t,trace_id:n,data:r,description:a,parent_span_id:`parentSpanId`in e?e.parentSpanId:`parentSpanContext`in e?e.parentSpanContext?.spanId:void 0,start_timestamp:ln(i),timestamp:ln(o)||void 0,status:hn(s),op:r[Lt],origin:r[Rt],links:cn(c)}}return{span_id:t,trace_id:n,start_timestamp:0,data:{}}}function fn(e){let t=e;return!!t.attributes&&!!t.startTime&&!!t.name&&!!t.endTime&&!!t.status}function pn(e){return typeof e.getSpanJSON==`function`}function mn(e){let{traceFlags:t}=e.spanContext();return t===1}function hn(e){if(!(!e||e.code===0))return e.code===1?`ok`:e.message||`internal_error`}var gn=`_sentryRootSpan`;function _n(e){return e[gn]||e}function vn(){on||=(u(()=>{console.warn("[Sentry] Returning null from `beforeSendSpan` is disallowed. To drop certain spans, configure the respective integrations directly or use `ignoreSpans`.")}),!0)}function yn(e){if(typeof __SENTRY_TRACING__==`boolean`&&!__SENTRY_TRACING__)return!1;let t=e||z()?.getOptions();return!!t&&(t.tracesSampleRate!=null||!!t.tracesSampler)}function bn(e){m.log(`Ignoring span ${e.op} - ${e.description} because it matches \`ignoreSpans\`.`)}function xn(e,n){if(!n?.length||!e.description)return!1;for(let r of n){if(Cn(r)){if(Qe(e.description,r))return t&&bn(e),!0;continue}if(!r.name&&!r.op)continue;let n=r.name?Qe(e.description,r.name):!0,i=r.op?e.op&&Qe(e.op,r.op):!0;if(n&&i)return t&&bn(e),!0}return!1}function Sn(e,t){let n=t.parent_span_id,r=t.span_id;if(n)for(let t of e)t.parent_span_id===r&&(t.parent_span_id=n)}function Cn(e){return typeof e==`string`||e instanceof RegExp}var wn=`production`,Tn=`_frozenDsc`;function En(e,t){let n=t.getOptions(),{publicKey:r}=t.getDsn()||{},i={environment:n.environment||`production`,release:n.release,public_key:r,trace_id:e,org_id:nn(t)};return t.emit(`createDsc`,i),i}function Dn(e,t){let n=t.getPropagationContext();return n.dsc||En(n.traceId,e)}function On(e){let t=z();if(!t)return{};let n=_n(e),r=dn(n),i=r.data,a=n.spanContext().traceState,o=a?.get(`sentry.sample_rate`)??i[`sentry.sample_rate`]??i[`sentry.previous_trace_sample_rate`];function s(e){return(typeof o==`number`||typeof o==`string`)&&(e.sample_rate=`${o}`),e}let c=n[Tn];if(c)return s(c);let l=a?.get(`sentry.dsc`),u=l&&Kt(l);if(u)return s(u);let d=En(e.spanContext().traceId,t),f=i[It],p=r.description;return f!==`url`&&p&&(d.transaction=p),yn()&&(d.sampled=String(mn(n)),d.sample_rand=a?.get(`sentry.sample_rand`)??Gt(n).scope?.getPropagationContext().sampleRand.toString()),s(d),t.emit(`createDsc`,d,n),d}function V(e,t=100,n=1/0){try{return An(``,e,t,n)}catch(e){return{ERROR:`**non-serializable** (${e})`}}}function kn(e,t=3,n=100*1024){let r=V(e,t);return Pn(r)>n?kn(e,t-1,n):r}function An(e,t,n=1/0,r=1/0,i=Fn()){let[a,o]=i;if(t==null||[`boolean`,`string`].includes(typeof t)||typeof t==`number`&&Number.isFinite(t))return t;let s=jn(e,t);if(!s.startsWith(`[object `))return s;if(t.__sentry_skip_normalization__)return t;let c=typeof t.__sentry_override_normalization_depth__==`number`?t.__sentry_override_normalization_depth__:n;if(c===0)return s.replace(`object `,``);if(a(t))return`[Circular ~]`;let l=t;if(l&&typeof l.toJSON==`function`)try{return An(``,l.toJSON(),c-1,r,i)}catch{}let u=Array.isArray(t)?[]:{},d=0,f=Ue(t);for(let e in f){if(!Object.prototype.hasOwnProperty.call(f,e))continue;if(d>=r){u[e]=`[MaxProperties ~]`;break}let t=f[e];u[e]=An(e,t,c-1,r,i),d++}return o(t),u}function jn(e,t){try{if(e===`domain`&&t&&typeof t==`object`&&t._events)return`[Domain]`;if(e===`domainEmitter`)return`[DomainEmitter]`;if(typeof global<`u`&&t===global)return`[Global]`;if(typeof window<`u`&&t===window)return`[Window]`;if(typeof document<`u`&&t===document)return`[Document]`;if(Ne(t))return me(t);if(Me(t))return`[SyntheticEvent]`;if(typeof t==`number`&&!Number.isFinite(t))return`[${t}]`;if(typeof t==`function`)return`[Function: ${h(t)}]`;if(typeof t==`symbol`)return`[${String(t)}]`;if(typeof t==`bigint`)return`[BigInt: ${String(t)}]`;let n=Mn(t);return/^HTML(\w*)Element$/.test(n)?`[HTMLElement: ${n}]`:`[object ${n}]`}catch(e){return`**non-serializable** (${e})`}}function Mn(e){let t=Object.getPrototypeOf(e);return t?.constructor?t.constructor.name:`null prototype`}function Nn(e){return~-encodeURI(e).split(/%..|./).length}function Pn(e){return Nn(JSON.stringify(e))}function Fn(){let e=new WeakSet;function t(t){return e.has(t)?!0:(e.add(t),!1)}function n(t){e.delete(t)}return[t,n]}function H(e,t=[]){return[e,t]}function In(e,t){let[n,r]=e;return[n,[...r,t]]}function Ln(e,t){let n=e[1];for(let e of n){let n=e[0].type;if(t(e,n))return!0}return!1}function Rn(e,t){return Ln(e,(e,n)=>t.includes(n))}function zn(e){let t=a(n);return t.encodePolyfill?t.encodePolyfill(e):new TextEncoder().encode(e)}function Bn(e){let[t,n]=e,r=JSON.stringify(t);function i(e){typeof r==`string`?r=typeof e==`string`?r+e:[zn(r),e]:r.push(typeof e==`string`?zn(e):e)}for(let e of n){let[t,n]=e;if(i(`\n${JSON.stringify(t)}\n`),typeof n==`string`||n instanceof Uint8Array)i(n);else{let e;try{e=JSON.stringify(n)}catch{e=JSON.stringify(V(n))}i(e)}}return typeof r==`string`?r:Vn(r)}function Vn(e){let t=e.reduce((e,t)=>e+t.length,0),n=new Uint8Array(t),r=0;for(let t of e)n.set(t,r),r+=t.length;return n}function Hn(e){let t=typeof e.data==`string`?zn(e.data):e.data;return[{type:`attachment`,length:t.length,filename:e.filename,content_type:e.contentType,attachment_type:e.attachmentType},t]}var Un={sessions:`session`,event:`error`,client_report:`internal`,user_report:`default`,profile_chunk:`profile`,replay_event:`replay`,replay_recording:`replay`,check_in:`monitor`,raw_security:`security`,log:`log_item`,trace_metric:`metric`};function Wn(e){return e in Un}function Gn(e){return Wn(e)?Un[e]:e}function Kn(e){if(!e?.sdk)return;let{name:t,version:n}=e.sdk;return{name:t,version:n}}function qn(e,t,n,r){let i=e.sdkProcessingMetadata?.dynamicSamplingContext;return{event_id:e.event_id,sent_at:new Date().toISOString(),...t&&{sdk:t},...!!n&&r&&{dsn:B(r)},...i&&{trace:i}}}function Jn(e,t){if(!t)return e;let n=e.sdk||{};return e.sdk={...n,name:n.name||t.name,version:n.version||t.version,integrations:[...e.sdk?.integrations||[],...t.integrations||[]],packages:[...e.sdk?.packages||[],...t.packages||[]],settings:e.sdk?.settings||t.settings?{...e.sdk?.settings,...t.settings}:void 0},e}function Yn(e,t,n,r){let i=Kn(n);return H({sent_at:new Date().toISOString(),...i&&{sdk:i},...!!r&&t&&{dsn:B(t)}},[`aggregates`in e?[{type:`sessions`},e]:[{type:`session`},e.toJSON()]])}function Xn(e,t,n,r){let i=Kn(n),a=e.type&&e.type!==`replay_event`?e.type:`event`;Jn(e,n?.sdk);let o=qn(e,i,r,t);return delete e.sdkProcessingMetadata,H(o,[[{type:a},e]])}var Zn=0,Qn=1,$n=2;function U(e){return new tr(t=>{t(e)})}function er(e){return new tr((t,n)=>{n(e)})}var tr=class e{constructor(e){this._state=Zn,this._handlers=[],this._runExecutor(e)}then(t,n){return new e((e,r)=>{this._handlers.push([!1,n=>{if(!t)e(n);else try{e(t(n))}catch(e){r(e)}},t=>{if(!n)r(t);else try{e(n(t))}catch(e){r(e)}}]),this._executeHandlers()})}catch(e){return this.then(e=>e,e)}finally(t){return new e((e,n)=>{let r,i;return this.then(e=>{i=!1,r=e,t&&t()},e=>{i=!0,r=e,t&&t()}).then(()=>{if(i){n(r);return}e(r)})})}_executeHandlers(){if(this._state===Zn)return;let e=this._handlers.slice();this._handlers=[],e.forEach(e=>{e[0]||=(this._state===Qn&&e[1](this._value),this._state===$n&&e[2](this._value),!0)})}_runExecutor(e){let t=(e,t)=>{if(this._state===Zn){if(C(t)){t.then(n,r);return}this._state=e,this._value=t,this._executeHandlers()}},n=e=>{t(Qn,e)},r=e=>{t($n,e)};try{e(n,r)}catch(e){r(e)}}};function nr(e,t,n,r=0){try{let i=rr(t,n,e,r);return C(i)?i:U(i)}catch(e){return er(e)}}function rr(e,n,r,i){let a=r[i];if(!e||!a)return e;let o=a({...e},n);return t&&o===null&&m.log(`Event processor "${a.id||`?`}" dropped event`),C(o)?o.then(e=>rr(e,n,r,i+1)):rr(o,n,r,i+1)}var W,ir,ar,G;function or(e){let t=n._sentryDebugIds,r=n._debugIds;if(!t&&!r)return{};let i=t?Object.keys(t):[],a=r?Object.keys(r):[];if(G&&i.length===ir&&a.length===ar)return G;ir=i.length,ar=a.length,G={},W||={};let o=(t,n)=>{for(let r of t){let t=n[r],i=W?.[r];if(i&&G&&t)G[i[0]]=t,W&&(W[r]=[i[0],t]);else if(t){let n=e(r);for(let e=n.length-1;e>=0;e--){let i=n[e]?.filename;if(i&&G&&W){G[i]=t,W[r]=[i,t];break}}}}};return t&&o(i,t),r&&o(a,r),G}function sr(e,t){let{fingerprint:n,span:r,breadcrumbs:i,sdkProcessingMetadata:a}=t;ur(e,t),r&&pr(e,r),mr(e,n),dr(e,i),fr(e,a)}function cr(e,t){let{extra:n,tags:r,attributes:i,user:a,contexts:o,level:s,sdkProcessingMetadata:c,breadcrumbs:l,fingerprint:u,eventProcessors:d,attachments:f,propagationContext:p,transactionName:ee,span:te}=t;K(e,`extra`,n),K(e,`tags`,r),K(e,`attributes`,i),K(e,`user`,a),K(e,`contexts`,o),e.sdkProcessingMetadata=P(e.sdkProcessingMetadata,c,2),s&&(e.level=s),ee&&(e.transactionName=ee),te&&(e.span=te),l.length&&(e.breadcrumbs=[...e.breadcrumbs,...l]),u.length&&(e.fingerprint=[...e.fingerprint,...u]),d.length&&(e.eventProcessors=[...e.eventProcessors,...d]),f.length&&(e.attachments=[...e.attachments,...f]),e.propagationContext={...e.propagationContext,...p}}function K(e,t,n){e[t]=P(e[t],n,1)}function lr(e,t){let n=Nt().getScopeData();return e&&cr(n,e.getScopeData()),t&&cr(n,t.getScopeData()),n}function ur(e,t){let{extra:n,tags:r,user:i,contexts:a,level:o,transactionName:s}=t;Object.keys(n).length&&(e.extra={...n,...e.extra}),Object.keys(r).length&&(e.tags={...r,...e.tags}),Object.keys(i).length&&(e.user={...i,...e.user}),Object.keys(a).length&&(e.contexts={...a,...e.contexts}),o&&(e.level=o),s&&e.type!==`transaction`&&(e.transaction=s)}function dr(e,t){let n=[...e.breadcrumbs||[],...t];e.breadcrumbs=n.length?n:void 0}function fr(e,t){e.sdkProcessingMetadata={...e.sdkProcessingMetadata,...t}}function pr(e,t){e.contexts={trace:sn(t),...e.contexts},e.sdkProcessingMetadata={dynamicSamplingContext:On(t),...e.sdkProcessingMetadata};let n=dn(_n(t)).description;n&&!e.transaction&&e.type===`transaction`&&(e.transaction=n)}function mr(e,t){e.fingerprint=e.fingerprint?Array.isArray(e.fingerprint)?e.fingerprint:[e.fingerprint]:[],t&&(e.fingerprint=e.fingerprint.concat(t)),e.fingerprint.length||delete e.fingerprint}function hr(e,t,n,r,i,a){let{normalizeDepth:o=3,normalizeMaxBreadth:s=1e3}=e,c={...t,event_id:t.event_id||n.event_id||O(),timestamp:t.timestamp||j()},l=n.integrations||e.integrations.map(e=>e.name);gr(c,e),yr(c,l),i&&i.emit(`applyFrameMetadata`,t),t.type===void 0&&_r(c,e.stackParser);let u=xr(r,n.captureContext);n.mechanism&&A(c,n.mechanism);let d=i?i.getEventProcessors():[],f=lr(a,u),p=[...n.attachments||[],...f.attachments];p.length&&(n.attachments=p),sr(c,f);let ee=[...d,...f.eventProcessors];return(n.data&&n.data.__sentry__===!0?U(c):nr(ee,c,n)).then(e=>(e&&vr(e),typeof o==`number`&&o>0?br(e,o,s):e))}function gr(e,t){let{environment:n,release:r,dist:i,maxValueLength:a}=t;e.environment=e.environment||n||`production`,!e.release&&r&&(e.release=r),!e.dist&&i&&(e.dist=i);let o=e.request;o?.url&&a&&(o.url=Xe(o.url,a)),a&&e.exception?.values?.forEach(e=>{e.value&&=Xe(e.value,a)})}function _r(e,t){let n=or(t);e.exception?.values?.forEach(e=>{e.stacktrace?.frames?.forEach(e=>{e.filename&&(e.debug_id=n[e.filename])})})}function vr(e){let t={};if(e.exception?.values?.forEach(e=>{e.stacktrace?.frames?.forEach(e=>{e.debug_id&&(e.abs_path?t[e.abs_path]=e.debug_id:e.filename&&(t[e.filename]=e.debug_id),delete e.debug_id)})}),Object.keys(t).length===0)return;e.debug_meta=e.debug_meta||{},e.debug_meta.images=e.debug_meta.images||[];let n=e.debug_meta.images;Object.entries(t).forEach(([e,t])=>{n.push({type:`sourcemap`,code_file:e,debug_id:t})})}function yr(e,t){t.length>0&&(e.sdk=e.sdk||{},e.sdk.integrations=[...e.sdk.integrations||[],...t])}function br(e,t,n){if(!e)return null;let r={...e,...e.breadcrumbs&&{breadcrumbs:e.breadcrumbs.map(e=>({...e,...e.data&&{data:V(e.data,t,n)}}))},...e.user&&{user:V(e.user,t,n)},...e.contexts&&{contexts:V(e.contexts,t,n)},...e.extra&&{extra:V(e.extra,t,n)}};return e.contexts?.trace&&r.contexts&&(r.contexts.trace=e.contexts.trace,e.contexts.trace.data&&(r.contexts.trace.data=V(e.contexts.trace.data,t,n))),e.spans&&(r.spans=e.spans.map(e=>({...e,...e.data&&{data:V(e.data,t,n)}}))),e.contexts?.flags&&r.contexts&&(r.contexts.flags=V(e.contexts.flags,3,n)),r}function xr(e,t){if(!t)return e;let n=e?e.clone():new F;return n.update(t),n}function Sr(e){if(e)return Cr(e)||Tr(e)?{captureContext:e}:e}function Cr(e){return e instanceof F||typeof e==`function`}var wr=[`user`,`level`,`extra`,`contexts`,`tags`,`fingerprint`,`propagationContext`];function Tr(e){return Object.keys(e).some(e=>wr.includes(e))}function Er(e,t){return L().captureException(e,Sr(t))}function Dr(e,t){return L().captureEvent(e,t)}function Or(e){let t=R(),{user:r}=lr(t,L()),{userAgent:i}=n.navigator||{},a=ut({user:r,...i&&{userAgent:i},...e}),o=t.getSession();return o?.status===`ok`&&N(o,{status:`exited`}),kr(),t.setSession(a),a}function kr(){let e=R(),t=L().getSession()||e.getSession();t&&dt(t),Ar(),e.setSession()}function Ar(){let e=R(),t=z(),n=e.getSession();n&&t&&t.captureSession(n)}function jr(e=!1){if(e){kr();return}Ar()}function Mr(e){let t=e.protocol?`${e.protocol}:`:``,n=e.port?`:${e.port}`:``;return`${t}//${e.host}${n}${e.path?`/${e.path}`:``}/api/`}function Nr(e){return`${Mr(e)}${e.projectId}/envelope/`}function Pr(e,t){let n={sentry_version:`7`};return e.publicKey&&(n.sentry_key=e.publicKey),t&&(n.sentry_client=`${t.name}/${t.version}`),new URLSearchParams(n).toString()}function Fr(e,t,n){return t||`${Nr(e)}?${Pr(e,n)}`}var Ir=[];function Lr(e){let t={};return e.forEach(e=>{let{name:n}=e,r=t[n];r&&!r.isDefaultInstance&&e.isDefaultInstance||(t[n]=e)}),Object.values(t)}function Rr(e){let t=e.defaultIntegrations||[],n=e.integrations;t.forEach(e=>{e.isDefaultInstance=!0});let r;if(Array.isArray(n))r=[...t,...n];else if(typeof n==`function`){let e=n(t);r=Array.isArray(e)?e:[e]}else r=t;return Lr(r)}function zr(e,t){let n={};return t.forEach(t=>{t&&Vr(e,t,n)}),n}function Br(e,t){for(let n of t)n?.afterAllSetup&&n.afterAllSetup(e)}function Vr(e,n,r){if(r[n.name]){t&&m.log(`Integration skipped because it was already installed: ${n.name}`);return}if(r[n.name]=n,!Ir.includes(n.name)&&typeof n.setupOnce==`function`&&(n.setupOnce(),Ir.push(n.name)),n.setup&&typeof n.setup==`function`&&n.setup(e),typeof n.preprocessEvent==`function`){let t=n.preprocessEvent.bind(n);e.on(`preprocessEvent`,(n,r)=>t(n,r,e))}if(typeof n.processEvent==`function`){let t=n.processEvent.bind(n),r=Object.assign((n,r)=>t(n,r,e),{id:n.name});e.addEventProcessor(r)}t&&m.log(`Integration installed: ${n.name}`)}function q(e){return e}function Hr(e){return[{type:`log`,item_count:e.length,content_type:`application/vnd.sentry.items.log+json`},{items:e}]}function Ur(e,t,n,r){let i={};return t?.sdk&&(i.sdk={name:t.sdk.name,version:t.sdk.version}),n&&r&&(i.dsn=B(r)),H(i,[Hr(e)])}function Wr(e,t){let n=t??Gr(e)??[];if(n.length===0)return;let r=e.getOptions(),i=Ur(n,r._metadata,r.tunnel,e.getDsn());Kr().set(e,[]),e.emit(`flushLogs`),e.sendEnvelope(i)}function Gr(e){return Kr().get(e)}function Kr(){return o(`clientToLogBufferMap`,()=>new WeakMap)}function qr(e){return[{type:`trace_metric`,item_count:e.length,content_type:`application/vnd.sentry.items.trace-metric+json`},{items:e}]}function Jr(e,t,n,r){let i={};return t?.sdk&&(i.sdk={name:t.sdk.name,version:t.sdk.version}),n&&r&&(i.dsn=B(r)),H(i,[qr(e)])}function Yr(e,t){let n=t??Xr(e)??[];if(n.length===0)return;let r=e.getOptions(),i=Jr(n,r._metadata,r.tunnel,e.getDsn());Zr().set(e,[]),e.emit(`flushMetrics`),e.sendEnvelope(i)}function Xr(e){return Zr().get(e)}function Zr(){return o(`clientToMetricBufferMap`,()=>new WeakMap)}function Qr(e){return typeof e==`object`&&typeof e.unref==`function`&&e.unref(),e}var $r=Symbol.for(`SentryBufferFullError`);function ei(e=100){let t=new Set;function n(){return t.size<e}function r(e){t.delete(e)}function i(e){if(!n())return er($r);let i=e();return t.add(i),i.then(()=>r(i),()=>r(i)),i}function a(e){if(!t.size)return U(!0);let n=Promise.allSettled(Array.from(t)).then(()=>!0);if(!e)return n;let r=[n,new Promise(t=>Qr(setTimeout(()=>t(!1),e)))];return Promise.race(r)}return{get $(){return Array.from(t)},add:i,drain:a}}var ti=60*1e3;function ni(e,t=Ye()){let n=parseInt(`${e}`,10);if(!isNaN(n))return n*1e3;let r=Date.parse(`${e}`);return isNaN(r)?ti:r-t}function ri(e,t){return e[t]||e.all||0}function ii(e,t,n=Ye()){return ri(e,t)>n}function ai(e,{statusCode:t,headers:n},r=Ye()){let i={...e},a=n?.[`x-sentry-rate-limits`],o=n?.[`retry-after`];if(a)for(let e of a.trim().split(`,`)){let[t,n,,,a]=e.split(`:`,5),o=parseInt(t,10),s=(isNaN(o)?60:o)*1e3;if(!n)i.all=r+s;else for(let e of n.split(`;`))e===`metric_bucket`?(!a||a.split(`;`).includes(`custom`))&&(i[e]=r+s):i[e]=r+s}else o?i.all=r+ni(o,r):t===429&&(i.all=r+60*1e3);return i}function oi(e,n,r=ei(e.bufferSize||64)){let i={},a=e=>r.drain(e);function o(a){let o=[];if(Ln(a,(t,n)=>{let r=Gn(n);ii(i,r)?e.recordDroppedEvent(`ratelimit_backoff`,r):o.push(t)}),o.length===0)return Promise.resolve({});let s=H(a[0],o),c=n=>{if(Rn(s,[`client_report`])){t&&m.warn(`Dropping client report. Will not send outcomes (reason: ${n}).`);return}Ln(s,(t,r)=>{e.recordDroppedEvent(n,Gn(r))})};return r.add(()=>n({body:Bn(s)}).then(e=>e.statusCode===413?(t&&m.error(`Sentry responded with status code 413. Envelope was discarded due to exceeding size limits.`),c(`send_error`),e):(t&&e.statusCode!==void 0&&(e.statusCode<200||e.statusCode>=300)&&m.warn(`Sentry responded with status code ${e.statusCode} to sent event.`),i=ai(i,e),e),e=>{throw c(`network_error`),t&&m.error(`Encountered error running transport request:`,e),e})).then(e=>e,e=>{if(e===$r)return t&&m.error(`Skipped sending event because buffer is full.`),c(`queue_overflow`),Promise.resolve({});throw e})}return{send:o,flush:a}}function si(e,t,n){let r=[{type:`client_report`},{timestamp:n||j(),discarded_events:e}];return H(t?{dsn:t}:{},[r])}function ci(e){let t=[];e.message&&t.push(e.message);try{let n=e.exception.values[e.exception.values.length-1];n?.value&&(t.push(n.value),n.type&&t.push(`${n.type}: ${n.value}`))}catch{}return t}function li(e){let{trace_id:t,parent_span_id:n,span_id:r,status:i,origin:a,data:o,op:s}=e.contexts?.trace??{};return{data:o??{},description:e.transaction,op:s,parent_span_id:n,span_id:r??``,start_timestamp:e.start_timestamp??0,status:i,timestamp:e.timestamp,trace_id:t??``,origin:a,profile_id:o?.[zt],exclusive_time:o?.[Bt],measurements:e.measurements,is_segment:!0}}function ui(e){return{type:`transaction`,timestamp:e.timestamp,start_timestamp:e.start_timestamp,transaction:e.description,contexts:{trace:{trace_id:e.trace_id,span_id:e.span_id,parent_span_id:e.parent_span_id,op:e.op,status:e.status,origin:e.origin,data:{...e.data,...e.profile_id&&{"sentry.profile_id":e.profile_id},...e.exclusive_time&&{"sentry.exclusive_time":e.exclusive_time}}}},measurements:e.measurements}}var di=`Not capturing exception because it's already been captured.`,fi=`Discarded session because of missing or non-string release`,pi=Symbol.for(`SentryInternalError`),mi=Symbol.for(`SentryDoNotSendEventError`),hi=5e3;function gi(e){return{message:e,[pi]:!0}}function _i(e){return{message:e,[mi]:!0}}function vi(e){return!!e&&typeof e==`object`&&pi in e}function yi(e){return!!e&&typeof e==`object`&&mi in e}function bi(e,t,n,r,i){let a=0,o,s=!1;e.on(n,()=>{a=0,clearTimeout(o),s=!1}),e.on(t,t=>{a+=r(t),a>=8e5?i(e):s||(s=!0,o=Qr(setTimeout(()=>{i(e)},hi)))}),e.on(`flush`,()=>{i(e)})}var xi=class{constructor(e){if(this._options=e,this._integrations={},this._numProcessing=0,this._outcomes={},this._hooks={},this._eventProcessors=[],this._promiseBuffer=ei(e.transportOptions?.bufferSize??64),e.dsn?this._dsn=rn(e.dsn):t&&m.warn(`No DSN provided, client will not send events.`),this._dsn){let t=Fr(this._dsn,e.tunnel,e._metadata?e._metadata.sdk:void 0);this._transport=e.transport({tunnel:this._options.tunnel,recordDroppedEvent:this.recordDroppedEvent.bind(this),...e.transportOptions,url:t})}this._options.enableLogs=this._options.enableLogs??this._options._experiments?.enableLogs,this._options.enableLogs&&bi(this,`afterCaptureLog`,`flushLogs`,Oi,Wr),(this._options.enableMetrics??this._options._experiments?.enableMetrics??!0)&&bi(this,`afterCaptureMetric`,`flushMetrics`,Di,Yr)}captureException(e,n,r){let i=O();if(at(e))return t&&m.log(di),i;let a={event_id:i,...n};return this._process(()=>this.eventFromException(e,a).then(e=>this._captureEvent(e,a,r)).then(e=>e),`error`),a.event_id}captureMessage(e,t,n,r){let i={event_id:O(),...n},a=De(e)?e:String(e),o=Oe(e),s=o?this.eventFromMessage(a,t,i):this.eventFromException(e,i);return this._process(()=>s.then(e=>this._captureEvent(e,i,r)),o?`unknown`:`error`),i.event_id}captureEvent(e,n,r){let i=O();if(n?.originalException&&at(n.originalException))return t&&m.log(di),i;let a={event_id:i,...n},o=e.sdkProcessingMetadata||{},s=o.capturedSpanScope,c=o.capturedSpanIsolationScope,l=Si(e.type);return this._process(()=>this._captureEvent(e,a,s||r,c),l),a.event_id}captureSession(e){this.sendSession(e),N(e,{init:!1})}getDsn(){return this._dsn}getOptions(){return this._options}getSdkMetadata(){return this._options._metadata}getTransport(){return this._transport}async flush(e){let t=this._transport;if(!t)return!0;this.emit(`flush`);let n=await this._isClientDoneProcessing(e),r=await t.flush(e);return n&&r}async close(e){Wr(this);let t=await this.flush(e);return this.getOptions().enabled=!1,this.emit(`close`),t}getEventProcessors(){return this._eventProcessors}addEventProcessor(e){this._eventProcessors.push(e)}init(){(this._isEnabled()||this._options.integrations.some(({name:e})=>e.startsWith(`Spotlight`)))&&this._setupIntegrations()}getIntegrationByName(e){return this._integrations[e]}addIntegration(e){let t=this._integrations[e.name];Vr(this,e,this._integrations),t||Br(this,[e])}sendEvent(e,t={}){this.emit(`beforeSendEvent`,e,t);let n=Xn(e,this._dsn,this._options._metadata,this._options.tunnel);for(let e of t.attachments||[])n=In(n,Hn(e));this.sendEnvelope(n).then(t=>this.emit(`afterSendEvent`,e,t))}sendSession(e){let{release:n,environment:r=wn}=this._options;if(`aggregates`in e){let i=e.attrs||{};if(!i.release&&!n){t&&m.warn(fi);return}i.release=i.release||n,i.environment=i.environment||r,e.attrs=i}else{if(!e.release&&!n){t&&m.warn(fi);return}e.release=e.release||n,e.environment=e.environment||r}this.emit(`beforeSendSession`,e);let i=Yn(e,this._dsn,this._options._metadata,this._options.tunnel);this.sendEnvelope(i)}recordDroppedEvent(e,n,r=1){if(this._options.sendClientReports){let i=`${e}:${n}`;t&&m.log(`Recording outcome: "${i}"${r>1?` (${r} times)`:``}`),this._outcomes[i]=(this._outcomes[i]||0)+r}}on(e,t){let n=this._hooks[e]=this._hooks[e]||new Set,r=(...e)=>t(...e);return n.add(r),()=>{n.delete(r)}}emit(e,...t){let n=this._hooks[e];n&&n.forEach(e=>e(...t))}async sendEnvelope(e){if(this.emit(`beforeEnvelope`,e),this._isEnabled()&&this._transport)try{return await this._transport.send(e)}catch(e){return t&&m.error(`Error while sending envelope:`,e),{}}return t&&m.error(`Transport disabled`),{}}dispose(){}_setupIntegrations(){let{integrations:e}=this._options;this._integrations=zr(this,e),Br(this,e)}_updateSessionFromEvent(e,t){let n=t.level===`fatal`,r=!1,i=t.exception?.values;if(i){r=!0,n=!1;for(let e of i)if(e.mechanism?.handled===!1){n=!0;break}}let a=e.status===`ok`;(a&&e.errors===0||a&&n)&&(N(e,{...n&&{status:`crashed`},errors:e.errors||Number(r||n)}),this.captureSession(e))}async _isClientDoneProcessing(e){let t=0;for(;!e||t<e;){if(await new Promise(e=>setTimeout(e,1)),!this._numProcessing)return!0;t++}return!1}_isEnabled(){return this.getOptions().enabled!==!1&&this._transport!==void 0}_prepareEvent(e,t,n,r){let i=this.getOptions(),a=Object.keys(this._integrations);return!t.integrations&&a?.length&&(t.integrations=a),this.emit(`preprocessEvent`,e,t),e.type||r.setLastEventId(e.event_id||t.event_id),hr(i,e,t,n,this,r).then(e=>e===null?e:(this.emit(`postprocessEvent`,e,t),e.contexts={trace:{...e.contexts?.trace,...Ft(n)},...e.contexts},e.sdkProcessingMetadata={dynamicSamplingContext:Dn(this,n),...e.sdkProcessingMetadata},e))}_captureEvent(e,n={},r=L(),i=R()){return t&&Ti(e)&&m.log(`Captured error event \`${ci(e)[0]||`<unknown>`}\``),this._processEvent(e,n,r,i).then(e=>e.event_id,e=>{t&&(yi(e)?m.log(e.message):vi(e)?m.warn(e.message):m.warn(e))})}_processEvent(e,t,n,r){let i=this.getOptions(),{sampleRate:a}=i,o=Ei(e),s=Ti(e),c=`before send for type \`${e.type||`error`}\``,l=a===void 0?void 0:an(a);if(s&&typeof l==`number`&&Je()>l)return this.recordDroppedEvent(`sample_rate`,`error`),er(_i(`Discarding event because it's not included in the random sample (sampling rate = ${a})`));let u=Si(e.type);return this._prepareEvent(e,t,n,r).then(e=>{if(e===null)throw this.recordDroppedEvent(`event_processor`,u),_i("An event processor returned `null`, will not send event.");return t.data?.__sentry__===!0?e:Ci(wi(this,i,e,t),c)}).then(i=>{if(i===null){if(this.recordDroppedEvent(`before_send`,u),o){let t=1+(e.spans||[]).length;this.recordDroppedEvent(`before_send`,`span`,t)}throw _i(`${c} returned \`null\`, will not send event.`)}let a=n.getSession()||r.getSession();if(s&&a&&this._updateSessionFromEvent(a,i),o){let e=(i.sdkProcessingMetadata?.spanCountBeforeProcessing||0)-(i.spans?i.spans.length:0);e>0&&this.recordDroppedEvent(`before_send`,`span`,e)}let l=i.transaction_info;return o&&l&&i.transaction!==e.transaction&&(i.transaction_info={...l,source:`custom`}),this.sendEvent(i,t),i}).then(null,e=>{throw yi(e)||vi(e)?e:(this.captureException(e,{mechanism:{handled:!1,type:`internal`},data:{__sentry__:!0},originalException:e}),gi(`Event processing pipeline threw an error, original event will not be sent. Details have been sent as a new event.\nReason: ${e}`))})}_process(e,t){this._numProcessing++,this._promiseBuffer.add(e).then(e=>(this._numProcessing--,e),e=>(this._numProcessing--,e===$r&&this.recordDroppedEvent(`queue_overflow`,t),e))}_clearOutcomes(){let e=this._outcomes;return this._outcomes={},Object.entries(e).map(([e,t])=>{let[n,r]=e.split(`:`);return{reason:n,category:r,quantity:t}})}_flushOutcomes(){t&&m.log(`Flushing outcomes...`);let e=this._clearOutcomes();if(e.length===0){t&&m.log(`No outcomes to send`);return}if(!this._dsn){t&&m.log(`No dsn provided, will not send outcomes`);return}t&&m.log(`Sending outcomes:`,e);let n=si(e,this._options.tunnel&&B(this._dsn));this.sendEnvelope(n)}};function Si(e){return e===`replay_event`?`replay`:e||`error`}function Ci(e,t){let n=`${t} must return \`null\` or a valid event.`;if(C(e))return e.then(e=>{if(!S(e)&&e!==null)throw gi(n);return e},e=>{throw gi(`${t} rejected with ${e}`)});if(!S(e)&&e!==null)throw gi(n);return e}function wi(e,t,n,r){let{beforeSend:i,beforeSendTransaction:a,beforeSendSpan:o,ignoreSpans:s}=t,c=n;if(Ti(c)&&i)return i(c,r);if(Ei(c)){if(o||s){let t=li(c);if(s?.length&&xn(t,s))return null;if(o){let e=o(t);e?c=P(n,ui(e)):vn()}if(c.spans){let t=[],n=c.spans;for(let e of n){if(s?.length&&xn(e,s)){Sn(n,e);continue}if(o){let n=o(e);n?t.push(n):(vn(),t.push(e))}else t.push(e)}let r=c.spans.length-t.length;r&&e.recordDroppedEvent(`before_send`,`span`,r),c.spans=t}}if(a){if(c.spans){let e=c.spans.length;c.sdkProcessingMetadata={...n.sdkProcessingMetadata,spanCountBeforeProcessing:e}}return a(c,r)}}return c}function Ti(e){return e.type===void 0}function Ei(e){return e.type===`transaction`}function Di(e){let t=0;return e.name&&(t+=e.name.length*2),t+=8,t+ki(e.attributes)}function Oi(e){let t=0;return e.message&&(t+=e.message.length*2),t+ki(e.attributes)}function ki(e){if(!e)return 0;let t=0;return Object.values(e).forEach(e=>{Array.isArray(e)?t+=e.length*Ai(e[0]):Oe(e)?t+=Ai(e):t+=100}),t}function Ai(e){return typeof e==`string`?e.length*2:typeof e==`number`?8:typeof e==`boolean`?4:0}function ji(e){return y(e)&&`__sentry_fetch_url_host__`in e&&typeof e.__sentry_fetch_url_host__==`string`}function Mi(e){return ji(e)?`${e.message} (${e.__sentry_fetch_url_host__})`:e.message}function Ni(e,n){n.debug===!0&&(t?m.enable():u(()=>{console.warn("[Sentry] Cannot initialize SDK with `debug` option using a non-debug bundle.")})),L().update(n.initialScope);let r=new e(n);return Pi(r),r.init(),r}function Pi(e){L().setClient(e)}function Fi(e){if(!e)return{};let t=e.match(/^(([^:/?#]+):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?$/);if(!t)return{};let n=t[6]||``,r=t[8]||``;return{host:t[4],path:t[5],protocol:t[2],search:n,hash:r,relative:t[5]+n+r}}function Ii(e,t=!0){if(e.startsWith(`data:`)){let n=e.match(/^data:([^;,]+)/),r=n?n[1]:`text/plain`,i=e.includes(`;base64,`),a=e.indexOf(`,`),o=``;if(t&&a!==-1){let t=e.slice(a+1);o=t.length>10?`${t.slice(0,10)}... [truncated]`:t}return`data:${r}${i?`,base64`:``}${o?`,${o}`:``}`}return e}function Li(e){`aggregates`in e?e.attrs?.ip_address===void 0&&(e.attrs={...e.attrs,ip_address:`{{auto}}`}):e.ipAddress===void 0&&(e.ipAddress=`{{auto}}`)}function Ri(e,t,n=[t],i=`npm`){let a=(e._metadata=e._metadata||{}).sdk=e._metadata.sdk||{};a.name||(a.name=`sentry.javascript.${t}`,a.packages=n.map(e=>({name:`${i}:@sentry/${e}`,version:r})),a.version=r)}var zi=100;function J(e,t){let n=z(),r=R();if(!n)return;let{beforeBreadcrumb:i=null,maxBreadcrumbs:a=zi}=n.getOptions();if(a<=0)return;let o={timestamp:j(),...e},s=i?u(()=>i(o,t)):o;s!==null&&(n.emit&&n.emit(`beforeAddBreadcrumb`,s,t),r.addBreadcrumb(s,a))}var Bi,Vi=`FunctionToString`,Hi=new WeakMap,Ui=q((()=>({name:Vi,setupOnce(){Bi=Function.prototype.toString;try{Function.prototype.toString=function(...e){let t=He(this),n=Hi.has(z())&&t!==void 0?t:this;return Bi.apply(n,e)}}catch{}},setup(e){Hi.set(e,!0)}}))),Wi=[/^Script error\.?$/,/^Javascript error: Script error\.? on line 0$/,/^ResizeObserver loop completed with undelivered notifications.$/,/^Cannot redefine property: googletag$/,/^Can't find variable: gmo$/,/^undefined is not an object \(evaluating 'a\.[A-Z]'\)$/,/can't redefine non-configurable property "solana"/,/vv\(\)\.getRestrictions is not a function/,/Can't find variable: _AutofillCallbackHandler/,/Object Not Found Matching Id:\d+, MethodName:simulateEvent/,/^Java exception was raised during method invocation$/],Gi=`EventFilters`,Ki=q((e={})=>{let t;return{name:Gi,setup(n){t=Ji(e,n.getOptions())},processEvent(n,r,i){return t||=Ji(e,i.getOptions()),Yi(n,t)?null:n}}}),qi=q(((e={})=>({...Ki(e),name:`InboundFilters`})));function Ji(e={},t={}){return{allowUrls:[...e.allowUrls||[],...t.allowUrls||[]],denyUrls:[...e.denyUrls||[],...t.denyUrls||[]],ignoreErrors:[...e.ignoreErrors||[],...t.ignoreErrors||[],...e.disableErrorDefaults?[]:Wi],ignoreTransactions:[...e.ignoreTransactions||[],...t.ignoreTransactions||[]]}}function Yi(e,n){if(!e.type){if(Xi(e,n.ignoreErrors))return t&&m.warn(`Event dropped due to being matched by \`ignoreErrors\` option.\nEvent: ${k(e)}`),!0;if(na(e))return t&&m.warn(`Event dropped due to not having an error message, error type or stacktrace.\nEvent: ${k(e)}`),!0;if(Qi(e,n.denyUrls))return t&&m.warn(`Event dropped due to being matched by \`denyUrls\` option.\nEvent: ${k(e)}.\nUrl: ${ta(e)}`),!0;if(!$i(e,n.allowUrls))return t&&m.warn(`Event dropped due to not being matched by \`allowUrls\` option.\nEvent: ${k(e)}.\nUrl: ${ta(e)}`),!0}else if(e.type===`transaction`&&Zi(e,n.ignoreTransactions))return t&&m.warn(`Event dropped due to being matched by \`ignoreTransactions\` option.\nEvent: ${k(e)}`),!0;return!1}function Xi(e,t){return t?.length?ci(e).some(e=>$e(e,t)):!1}function Zi(e,t){if(!t?.length)return!1;let n=e.transaction;return n?$e(n,t):!1}function Qi(e,t){if(!t?.length)return!1;let n=ta(e);return n?$e(n,t):!1}function $i(e,t){if(!t?.length)return!0;let n=ta(e);return n?$e(n,t):!0}function ea(e=[]){for(let t=e.length-1;t>=0;t--){let n=e[t];if(n&&n.filename!==`<anonymous>`&&n.filename!==`[native code]`)return n.filename||null}return null}function ta(e){try{let t=[...e.exception?.values??[]].reverse().find(e=>e.mechanism?.parent_id===void 0&&e.stacktrace?.frames?.length)?.stacktrace?.frames;return t?ea(t):null}catch{return t&&m.error(`Cannot extract url for event ${k(e)}`),null}}function na(e){return e.exception?.values?.length?!e.message&&!e.exception.values.some(e=>e.stacktrace||e.type&&e.type!==`Error`||e.value):!1}function ra(e,t,n,r,i,a){if(!i.exception?.values||!a||!w(a.originalException,Error))return;let o=i.exception.values.length>0?i.exception.values[i.exception.values.length-1]:void 0;o&&(i.exception.values=ia(e,t,r,a.originalException,n,i.exception.values,o,0))}function ia(e,t,n,r,i,a,o,s){if(a.length>=n+1)return a;let c=[...a];if(w(r[i],Error)){oa(o,s,r);let a=e(t,r[i]),l=c.length;sa(a,i,l,s),c=ia(e,t,n,r[i],i,[a,...c],a,l)}return aa(r)&&r.errors.forEach((a,l)=>{if(w(a,Error)){oa(o,s,r);let u=e(t,a),d=c.length;sa(u,`errors[${l}]`,d,s),c=ia(e,t,n,a,i,[u,...c],u,d)}}),c}function aa(e){return Array.isArray(e.errors)}function oa(e,t,n){e.mechanism={handled:!0,type:`auto.core.linked_errors`,...aa(n)&&{is_exception_group:!0},...e.mechanism,exception_id:t}}function sa(e,t,n,r){e.mechanism={handled:!0,...e.mechanism,type:`chained`,source:t,exception_id:n,parent_id:r}}function ca(e){let t=`console`;g(t,e),_(t,la)}function la(){`console`in n&&s.forEach(function(e){e in n.console&&T(n.console,e,function(t){return l[e]=t,function(...t){v(`console`,{args:t,level:e}),l[e]?.apply(n.console,t)}})})}function ua(e){return e===`warn`?`warning`:[`fatal`,`error`,`warning`,`log`,`info`,`debug`].includes(e)?e:`log`}var da=`Dedupe`,fa=q((()=>{let e;return{name:da,processEvent(n){if(n.type)return n;try{if(pa(n,e))return t&&m.warn(`Event dropped due to being a duplicate of previously captured event.`),null}catch{}return e=n}}}));function pa(e,t){return t?!!(ma(e,t)||ha(e,t)):!1}function ma(e,t){let n=e.message,r=t.message;return!(!n&&!r||n&&!r||!n&&r||n!==r||!_a(e,t)||!ga(e,t))}function ha(e,t){let n=va(t),r=va(e);return!(!n||!r||n.type!==r.type||n.value!==r.value||!_a(e,t)||!ga(e,t))}function ga(e,t){let n=pe(e),r=pe(t);if(!n&&!r)return!0;if(n&&!r||!n&&r||(n=n,r=r,r.length!==n.length))return!1;for(let e=0;e<r.length;e++){let t=r[e],i=n[e];if(t.filename!==i.filename||t.lineno!==i.lineno||t.colno!==i.colno||t.function!==i.function)return!1}return!0}function _a(e,t){let n=e.fingerprint,r=t.fingerprint;if(!n&&!r)return!0;if(n&&!r||!n&&r)return!1;n=n,r=r;try{return n.join(``)===r.join(``)}catch{return!1}}function va(e){return e.exception?.values?.[0]}var ya=`ConversationId`,ba=q((()=>({name:ya,setup(e){e.on(`spanStart`,e=>{let t=L().getScopeData(),n=R().getScopeData(),r=t.conversationId||n.conversationId;r&&e.setAttribute(Vt,r)})}})));function xa(e){if(e!==void 0){if(e>=400&&e<500)return`warning`;if(e>=500)return`error`}}var Y=n;function Sa(){return`history`in Y&&!!Y.history}function Ca(){if(!(`fetch`in Y))return!1;try{return new Headers,new Request(`data:,`),new Response,!0}catch{return!1}}function wa(e){return e&&/^function\s+\w+\(\)\s+\{\s+\[native code\]\s+\}$/.test(e.toString())}function Ta(){if(typeof EdgeRuntime==`string`)return!0;if(!Ca())return!1;if(wa(Y.fetch))return!0;let e=!1,n=Y.document;if(n&&typeof n.createElement==`function`)try{let t=n.createElement(`iframe`);t.hidden=!0,n.head.appendChild(t),t.contentWindow?.fetch&&(e=wa(t.contentWindow.fetch)),n.head.removeChild(t)}catch(e){t&&m.warn(`Could not create sandbox iframe for pure fetch check, bailing to window.fetch: `,e)}return e}function Ea(e,t){let n=`fetch`;g(n,e),_(n,()=>Da(void 0,t))}function Da(e,t=!1){t&&!Ta()||T(n,`fetch`,function(t){return function(...r){let i=Error(),{method:a,url:o}=Aa(r),s={args:r,fetchData:{method:a,url:o},startTimestamp:M()*1e3,virtualError:i,headers:ja(r)};return e||v(`fetch`,{...s}),t.apply(n,r).then(async t=>(e?e(t):v(`fetch`,{...s,endTimestamp:M()*1e3,response:t}),t),e=>{v(`fetch`,{...s,endTimestamp:M()*1e3,error:e}),y(e)&&e.stack===void 0&&(e.stack=i.stack,E(e,`framesToPop`,1));let t=z()?.getOptions().enhanceFetchErrorMessages??`always`;if(t!==!1&&e instanceof TypeError&&(e.message===`Failed to fetch`||e.message===`Load failed`||e.message===`NetworkError when attempting to fetch resource.`))try{let n=new URL(s.fetchData.url).host;t===`always`?e.message=`${e.message} (${n})`:E(e,`__sentry_fetch_url_host__`,n)}catch{}throw e})}})}function Oa(e,t){return!!e&&typeof e==`object`&&!!e[t]}function ka(e){return typeof e==`string`?e:e?Oa(e,`url`)?e.url:e.toString?e.toString():``:``}function Aa(e){if(e.length===0)return{method:`GET`,url:``};if(e.length===2){let[t,n]=e;return{url:ka(t),method:Oa(n,`method`)?String(n.method).toUpperCase():Pe(t)&&Oa(t,`method`)?String(t.method).toUpperCase():`GET`}}let t=e[0];return{url:ka(t),method:Oa(t,`method`)?String(t.method).toUpperCase():`GET`}}function ja(e){let[t,n]=e;try{if(typeof n==`object`&&n&&`headers`in n&&n.headers)return new Headers(n.headers);if(Pe(t))return new Headers(t.headers)}catch{}}function Ma(){return`npm`}var X=n,Na=0;function Pa(){return Na>0}function Fa(){Na++,setTimeout(()=>{Na--})}function Z(e,t={}){function n(e){return typeof e==`function`}if(!n(e))return e;try{let t=e.__sentry_wrapped__;if(t)return typeof t==`function`?t:e;if(He(e))return e}catch{return e}let r=function(...n){try{let r=n.map(e=>Z(e,t));return e.apply(this,r)}catch(e){throw Fa(),Pt(r=>{r.addEventProcessor(e=>(t.mechanism&&(it(e,void 0,void 0),A(e,t.mechanism)),e.extra={...e.extra,arguments:n},e)),Er(e)}),e}};try{for(let t in e)Object.prototype.hasOwnProperty.call(e,t)&&(r[t]=e[t])}catch{}Ve(r,e),E(e,`__sentry_wrapped__`,r);try{Object.getOwnPropertyDescriptor(r,`name`).configurable&&Object.defineProperty(r,`name`,{get(){return e.name}})}catch{}return r}function Ia(){let e=ze(),{referrer:t}=X.document||{},{userAgent:n}=X.navigator||{};return{url:e,headers:{...t&&{Referer:t},...n&&{"User-Agent":n}}}}function La(e,t){let n=Ba(e,t),r={type:Ga(t),value:Ka(t)};return n.length&&(r.stacktrace={frames:n}),r.type===void 0&&r.value===``&&(r.value=`Unrecoverable error caught`),r}function Ra(e,t,n,r){let i=z()?.getOptions().normalizeDepth,a=$a(t),o={__serialized__:kn(t,i)};if(a)return{exception:{values:[La(e,a)]},extra:o};let s={exception:{values:[{type:ke(t)?t.constructor.name:r?`UnhandledRejection`:`Error`,value:Za(t,{isUnhandledRejection:r})}]},extra:o};if(n){let t=Ba(e,n);t.length&&(s.exception.values[0].stacktrace={frames:t})}return s}function za(e,t){return{exception:{values:[La(e,t)]}}}function Ba(e,t){let n=t.stacktrace||t.stack||``,r=Ha(t),i=Ua(t);try{return e(n,r,i)}catch{}return[]}var Va=/Minified React error #\d+;/i;function Ha(e){return e&&Va.test(e.message)?1:0}function Ua(e){return typeof e.framesToPop==`number`?e.framesToPop:0}function Wa(e){return typeof WebAssembly<`u`&&WebAssembly.Exception!==void 0?e instanceof WebAssembly.Exception:!1}function Ga(e){let t=e?.name;return!t&&Wa(e)?e.message&&Array.isArray(e.message)&&e.message.length==2?e.message[0]:`WebAssembly.Exception`:t}function Ka(e){let t=e?.message;return Wa(e)?Array.isArray(e.message)&&e.message.length==2?e.message[1]:`wasm exception`:t?t.error&&typeof t.error.message==`string`?Mi(t.error):Mi(e):`No error message`}function qa(e,t,n,r){let i=Ya(e,t,n?.syntheticException||void 0,r);return A(i),i.level=`error`,n?.event_id&&(i.event_id=n.event_id),U(i)}function Ja(e,t,n=`info`,r,i){let a=Xa(e,t,r?.syntheticException||void 0,i);return a.level=n,r?.event_id&&(a.event_id=r.event_id),U(a)}function Ya(e,t,n,r,i){let a;if(we(t)&&t.error)return za(e,t.error);if(Te(t)||Ee(t)){let i=t;if(`stack`in t)a=za(e,t);else{let t=i.name||(Te(i)?`DOMError`:`DOMException`),o=i.message?`${t}: ${i.message}`:t;a=Xa(e,o,n,r),it(a,o)}return`code`in i&&(a.tags={...a.tags,"DOMException.code":`${i.code}`}),a}return y(t)?za(e,t):S(t)||ke(t)?(a=Ra(e,t,n,i),A(a,{synthetic:!0}),a):(a=Xa(e,t,n,r),it(a,`${t}`,void 0),A(a,{synthetic:!0}),a)}function Xa(e,t,n,r){let i={};if(r&&n){let r=Ba(e,n);r.length&&(i.exception={values:[{value:t,stacktrace:{frames:r}}]}),A(i,{synthetic:!0})}if(De(t)){let{__sentry_template_string__:e,__sentry_template_values__:n}=t;return i.logentry={message:e,params:n},i}return i.message=t,i}function Za(e,{isUnhandledRejection:t}){let n=Ke(e),r=t?`promise rejection`:`exception`;return we(e)?`Event \`ErrorEvent\` captured as ${r} with message \`${e.message}\``:ke(e)?`Event \`${Qa(e)}\` (type=${e.type}) captured as ${r}`:`Object captured as ${r} with keys: ${n}`}function Qa(e){try{let t=Object.getPrototypeOf(e);return t?t.constructor.name:void 0}catch{}}function $a(e){return Object.values(e).find(e=>e instanceof Error)}var eo=class extends xi{constructor(e){let t=to(e);Ri(t,`browser`,[`browser`],X.SENTRY_SDK_SOURCE||Ma()),t._metadata?.sdk&&(t._metadata.sdk.settings={infer_ip:t.sendDefaultPii?`auto`:`never`,...t._metadata.sdk.settings}),super(t);let{sendDefaultPii:n,sendClientReports:r,enableLogs:i,_experiments:a,enableMetrics:o}=this._options,s=o??a?.enableMetrics??!0;X.document&&(r||i||s)&&X.document.addEventListener(`visibilitychange`,()=>{X.document.visibilityState===`hidden`&&(r&&this._flushOutcomes(),i&&Wr(this),s&&Yr(this))}),n&&this.on(`beforeSendSession`,Li)}eventFromException(e,t){return qa(this._options.stackParser,e,t,this._options.attachStacktrace)}eventFromMessage(e,t=`info`,n){return Ja(this._options.stackParser,e,t,n,this._options.attachStacktrace)}_prepareEvent(e,t,n,r){return e.platform=e.platform||`javascript`,super._prepareEvent(e,t,n,r)}};function to(e){return{release:typeof __SENTRY_RELEASE__==`string`?__SENTRY_RELEASE__:X.SENTRY_RELEASE?.id,sendClientReports:!0,parentSpanIsAlwaysRootSpan:!0,...e}}var no=typeof __SENTRY_DEBUG__>`u`||__SENTRY_DEBUG__,Q=n,ro=1e3,io,ao,oo;function so(e){g(`dom`,e),_(`dom`,co)}function co(){if(!Q.document)return;let e=v.bind(null,`dom`),t=fo(e,!0);Q.document.addEventListener(`click`,t,!1),Q.document.addEventListener(`keypress`,t,!1),[`EventTarget`,`Node`].forEach(t=>{let n=Q[t]?.prototype;n?.hasOwnProperty?.(`addEventListener`)&&(T(n,`addEventListener`,function(t){return function(n,r,i){if(n===`click`||n==`keypress`)try{let r=this.__sentry_instrumentation_handlers__=this.__sentry_instrumentation_handlers__||{},a=r[n]=r[n]||{refCount:0};if(!a.handler){let r=fo(e);a.handler=r,t.call(this,n,r,i)}a.refCount++}catch{}return t.call(this,n,r,i)}}),T(n,`removeEventListener`,function(e){return function(t,n,r){if(t===`click`||t==`keypress`)try{let n=this.__sentry_instrumentation_handlers__||{},i=n[t];i&&(i.refCount--,i.refCount<=0&&(e.call(this,t,i.handler,r),i.handler=void 0,delete n[t]),Object.keys(n).length===0&&delete this.__sentry_instrumentation_handlers__)}catch{}return e.call(this,t,n,r)}}))})}function lo(e){if(e.type!==ao)return!1;try{if(!e.target||e.target._sentryId!==oo)return!1}catch{}return!0}function uo(e,t){return e===`keypress`?t?.tagName?!(t.tagName===`INPUT`||t.tagName===`TEXTAREA`||t.isContentEditable):!0:!1}function fo(e,t=!1){return n=>{if(!n||n._sentryCaptured)return;let r=po(n);if(uo(n.type,r))return;E(n,`_sentryCaptured`,!0),r&&!r._sentryId&&E(r,`_sentryId`,O());let i=n.type===`keypress`?`input`:n.type;lo(n)||(e({event:n,name:i,global:t}),ao=n.type,oo=r?r._sentryId:void 0),clearTimeout(io),io=Q.setTimeout(()=>{oo=void 0,ao=void 0},ro)}}function po(e){try{return e.target}catch{return null}}var mo;function ho(e){let t=`history`;g(t,e),_(t,go)}function go(){if(Q.addEventListener(`popstate`,()=>{let e=Q.location.href,t=mo;mo=e,t!==e&&v(`history`,{from:t,to:e})}),!Sa())return;function e(e){return function(...t){let n=t.length>2?t[2]:void 0;if(n){let r=mo,i=_o(String(n));if(mo=i,r===i)return e.apply(this,t);v(`history`,{from:r,to:i})}return e.apply(this,t)}}T(Q.history,`pushState`,e),T(Q.history,`replaceState`,e)}function _o(e){try{return new URL(e,Q.location.origin).toString()}catch{return e}}var vo={};function yo(e){let t=vo[e];if(t)return t;let n=Q[e];if(wa(n))return vo[e]=n.bind(Q);let r=Q.document;if(r&&typeof r.createElement==`function`)try{let t=r.createElement(`iframe`);t.hidden=!0,r.head.appendChild(t);let i=t.contentWindow;i?.[e]&&(n=i[e]),r.head.removeChild(t)}catch(t){no&&m.warn(`Could not create sandbox iframe for ${e} check, bailing to window.${e}: `,t)}return n&&(vo[e]=n.bind(Q))}function bo(e){vo[e]=void 0}var $=`__sentry_xhr_v3__`;function xo(e){g(`xhr`,e),_(`xhr`,So)}function So(){if(!Q.XMLHttpRequest)return;let e=XMLHttpRequest.prototype;e.open=new Proxy(e.open,{apply(e,t,n){let r=Error(),i=M()*1e3,a=x(n[0])?n[0].toUpperCase():void 0,o=Co(n[1]);if(!a||!o)return e.apply(t,n);t[$]={method:a,url:o,request_headers:{}},a===`POST`&&o.match(/sentry_key/)&&(t.__sentry_own_request__=!0);let s=()=>{let e=t[$];if(e&&t.readyState===4){try{e.status_code=t.status}catch{}v(`xhr`,{endTimestamp:M()*1e3,startTimestamp:i,xhr:t,virtualError:r})}};return`onreadystatechange`in t&&typeof t.onreadystatechange==`function`?t.onreadystatechange=new Proxy(t.onreadystatechange,{apply(e,t,n){return s(),e.apply(t,n)}}):t.addEventListener(`readystatechange`,s),t.setRequestHeader=new Proxy(t.setRequestHeader,{apply(e,t,n){let[r,i]=n,a=t[$];return a&&x(r)&&x(i)&&(a.request_headers[r.toLowerCase()]=i),e.apply(t,n)}}),e.apply(t,n)}}),e.send=new Proxy(e.send,{apply(e,t,n){let r=t[$];return r?(n[0]!==void 0&&(r.body=n[0]),v(`xhr`,{startTimestamp:M()*1e3,xhr:t}),e.apply(t,n)):e.apply(t,n)}})}function Co(e){if(x(e))return e;try{return e.toString()}catch{}}var wo=40;function To(e,t=yo(`fetch`)){let n=0,r=0;async function i(i){let a=i.body.length;n+=a,r++;let o={body:i.body,method:`POST`,referrerPolicy:`strict-origin`,headers:e.headers,keepalive:n<=6e4&&r<15,...e.fetchOptions};try{let n=await t(e.url,o);return{statusCode:n.status,headers:{"x-sentry-rate-limits":n.headers.get(`X-Sentry-Rate-Limits`),"retry-after":n.headers.get(`Retry-After`)}}}catch(e){throw bo(`fetch`),e}finally{n-=a,r--}}return oi(e,i,ei(e.bufferSize||wo))}var Eo=typeof __SENTRY_DEBUG__>`u`||__SENTRY_DEBUG__,Do=30,Oo=50;function ko(e,t,n,r){let i={filename:e,function:t===`<anonymous>`?`?`:t,in_app:!0};return n!==void 0&&(i.lineno=n),r!==void 0&&(i.colno=r),i}var Ao=/^\s*at (\S+?)(?::(\d+))(?::(\d+))\s*$/i,jo=/^\s*at (?:(.+?\)(?: \[.+\])?|.*?) ?\((?:address at )?)?(?:async )?((?:<anonymous>|[-a-z]+:|.*bundle|\/)?.*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,Mo=/\((\S*)(?::(\d+))(?::(\d+))\)/,No=/at (.+?) ?\(data:(.+?),/,Po=[Do,e=>{let t=e.match(No);if(t)return{filename:`<data:${t[2]}>`,function:t[1]};let n=Ao.exec(e);if(n){let[,e,t,r]=n;return ko(e,`?`,+t,+r)}let r=jo.exec(e);if(r){if(r[2]?.indexOf(`eval`)===0){let e=Mo.exec(r[2]);e&&(r[2]=e[1],r[3]=e[2],r[4]=e[3])}let[e,t]=Ro(r[1]||`?`,r[2]);return ko(t,e,r[3]?+r[3]:void 0,r[4]?+r[4]:void 0)}}],Fo=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:[-a-z]+)?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,Io=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,Lo=ce(Po,[Oo,e=>{let t=Fo.exec(e);if(t){if(t[3]&&t[3].indexOf(` > eval`)>-1){let e=Io.exec(t[3]);e&&(t[1]=t[1]||`eval`,t[3]=e[1],t[4]=e[2],t[5]=``)}let e=t[3],n=t[1]||`?`;return[n,e]=Ro(n,e),ko(e,n,t[4]?+t[4]:void 0,t[5]?+t[5]:void 0)}}]),Ro=(e,t)=>{let n=e.indexOf(`safari-extension`)!==-1,r=e.indexOf(`safari-web-extension`)!==-1;return n||r?[e.indexOf(`@`)===-1?`?`:e.split(`@`)[0],n?`safari-extension:${t}`:`safari-web-extension:${t}`]:[e,t]},zo=1024,Bo=`Breadcrumbs`,Vo=q(((e={})=>{let t={console:!0,dom:!0,fetch:!0,history:!0,sentry:!0,xhr:!0,...e};return{name:Bo,setup(e){t.console&&ca(Wo(e)),t.dom&&so(Uo(e,t.dom)),t.xhr&&xo(Go(e)),t.fetch&&Ea(Ko(e)),t.history&&ho(qo(e)),t.sentry&&e.on(`beforeSendEvent`,Ho(e))}}}));function Ho(e){return function(t){z()===e&&J({category:`sentry.${t.type===`transaction`?`transaction`:`event`}`,event_id:t.event_id,level:t.level,message:k(t)},{event:t})}}function Uo(e,t){return function(n){if(z()!==e)return;let r,i,a=typeof t==`object`?t.serializeAttribute:void 0,o=typeof t==`object`&&typeof t.maxStringLength==`number`?t.maxStringLength:void 0;o&&o>zo&&(Eo&&m.warn(`\`dom.maxStringLength\` cannot exceed ${zo}, but a value of ${o} was configured. Sentry will use ${zo} instead.`),o=zo),typeof a==`string`&&(a=[a]);try{let e=n.event,t=Jo(e)?e.target:e;r=Le(t,{keyAttrs:a,maxStringLength:o}),i=Be(t)}catch{r=`<unknown>`}if(r.length===0)return;let s={category:`ui.${n.name}`,message:r};i&&(s.data={"ui.component_name":i}),J(s,{event:n.event,name:n.name,global:n.global})}}function Wo(e){return function(t){if(z()!==e)return;let n={category:`console`,data:{arguments:t.args,logger:`console`},level:ua(t.level),message:Ze(t.args,` `)};if(t.level===`assert`)if(t.args[0]===!1)n.message=`Assertion failed: ${Ze(t.args.slice(1),` `)||`console.assert`}`,n.data.arguments=t.args.slice(1);else return;J(n,{input:t.args,level:t.level})}}function Go(e){return function(t){if(z()!==e)return;let{startTimestamp:n,endTimestamp:r}=t,i=t.xhr[$];if(!n||!r||!i)return;let{method:a,url:o,status_code:s,body:c}=i,l={method:a,url:o,status_code:s},u={xhr:t.xhr,input:c,startTimestamp:n,endTimestamp:r},d={category:`xhr`,data:l,type:`http`,level:xa(s)};e.emit(`beforeOutgoingRequestBreadcrumb`,d,u),J(d,u)}}function Ko(e){return function(t){if(z()!==e)return;let{startTimestamp:n,endTimestamp:r}=t;if(r&&!(t.fetchData.url.match(/sentry_key/)&&t.fetchData.method===`POST`))if(t.error){let i={data:t.error,input:t.args,startTimestamp:n,endTimestamp:r},a={category:`fetch`,data:t.fetchData,level:`error`,type:`http`};e.emit(`beforeOutgoingRequestBreadcrumb`,a,i),J(a,i)}else{let i=t.response,a={...t.fetchData,status_code:i?.status},o={input:t.args,response:i,startTimestamp:n,endTimestamp:r},s={category:`fetch`,data:a,type:`http`,level:xa(a.status_code)};e.emit(`beforeOutgoingRequestBreadcrumb`,s,o),J(s,o)}}}function qo(e){return function(t){if(z()!==e)return;let n=t.from,r=t.to,i=Fi(X.location.href),a=n?Fi(n):void 0,o=Fi(r);a?.path||(a=i),i.protocol===o.protocol&&i.host===o.host&&(r=o.relative),i.protocol===a.protocol&&i.host===a.host&&(n=a.relative),J({category:`navigation`,data:{from:n,to:r}})}}function Jo(e){return!!e&&!!e.target}var Yo=`EventTarget,Window,Node,ApplicationCache,AudioTrackList,BroadcastChannel,ChannelMergerNode,CryptoOperation,EventSource,FileReader,HTMLUnknownElement,IDBDatabase,IDBRequest,IDBTransaction,KeyOperation,MediaController,MessagePort,ModalWindow,Notification,SVGElementInstance,Screen,SharedWorker,TextTrack,TextTrackCue,TextTrackList,WebSocket,WebSocketWorker,Worker,XMLHttpRequest,XMLHttpRequestEventTarget,XMLHttpRequestUpload`.split(`,`),Xo=`BrowserApiErrors`,Zo=q(((e={})=>{let t={XMLHttpRequest:!0,eventTarget:!0,requestAnimationFrame:!0,setInterval:!0,setTimeout:!0,unregisterOriginalCallbacks:!1,...e};return{name:Xo,setupOnce(){t.setTimeout&&T(X,`setTimeout`,Qo),t.setInterval&&T(X,`setInterval`,Qo),t.requestAnimationFrame&&T(X,`requestAnimationFrame`,$o),t.XMLHttpRequest&&`XMLHttpRequest`in X&&T(XMLHttpRequest.prototype,`send`,es);let e=t.eventTarget;e&&(Array.isArray(e)?e:Yo).forEach(e=>ts(e,t))}}}));function Qo(e){return function(...t){let n=t[0];return t[0]=Z(n,{mechanism:{handled:!1,type:`auto.browser.browserapierrors.${h(e)}`}}),e.apply(this,t)}}function $o(e){return function(t){return e.apply(this,[Z(t,{mechanism:{data:{handler:h(e)},handled:!1,type:`auto.browser.browserapierrors.requestAnimationFrame`}})])}}function es(e){return function(...t){let n=this;return[`onload`,`onerror`,`onprogress`,`onreadystatechange`].forEach(e=>{e in n&&typeof n[e]==`function`&&T(n,e,function(t){let n={mechanism:{data:{handler:h(t)},handled:!1,type:`auto.browser.browserapierrors.xhr.${e}`}},r=He(t);return r&&(n.mechanism.data.handler=h(r)),Z(t,n)})}),e.apply(this,t)}}function ts(e,t){let n=X[e]?.prototype;n?.hasOwnProperty?.(`addEventListener`)&&(T(n,`addEventListener`,function(n){return function(r,i,a){try{ns(i)&&(i.handleEvent=Z(i.handleEvent,{mechanism:{data:{handler:h(i),target:e},handled:!1,type:`auto.browser.browserapierrors.handleEvent`}}))}catch{}return t.unregisterOriginalCallbacks&&rs(this,r,i),n.apply(this,[r,Z(i,{mechanism:{data:{handler:h(i),target:e},handled:!1,type:`auto.browser.browserapierrors.addEventListener`}}),a])}}),T(n,`removeEventListener`,function(e){return function(t,n,r){try{let i=n.__sentry_wrapped__;i&&e.call(this,t,i,r)}catch{}return e.call(this,t,n,r)}}))}function ns(e){return typeof e.handleEvent==`function`}function rs(e,t,n){e&&typeof e==`object`&&`removeEventListener`in e&&typeof e.removeEventListener==`function`&&e.removeEventListener(t,n)}var is=q((e={})=>{let t=e.lifecycle??`route`;return{name:`BrowserSession`,setupOnce(){if(X.document===void 0){Eo&&m.warn("Using the `browserSessionIntegration` in non-browser environments is not supported.");return}Or({ignoreDuration:!0}),jr();let e=R(),n=e.getUser();e.addScopeListener(e=>{let t=e.getUser();(n?.id!==t?.id||n?.ip_address!==t?.ip_address)&&(jr(),n=t)}),t===`route`&&ho(({from:e,to:t})=>{e!==t&&(Or({ignoreDuration:!0}),jr())})}}}),as=`CultureContext`,os=q((()=>({name:as,preprocessEvent(e){let t=ss();t&&(e.contexts={...e.contexts,culture:{...t,...e.contexts?.culture}})}})));function ss(){try{let e=X.Intl;if(!e)return;let t=e.DateTimeFormat().resolvedOptions();return{locale:t.locale,timezone:t.timeZone,calendar:t.calendar}}catch{return}}var cs=`GlobalHandlers`,ls=q(((e={})=>{let t={onerror:!0,onunhandledrejection:!0,...e};return{name:cs,setupOnce(){Error.stackTraceLimit=50},setup(e){t.onerror&&(us(e),hs(`onerror`)),t.onunhandledrejection&&(ds(e),hs(`onunhandledrejection`))}}}));function us(e){ve(t=>{let{stackParser:n,attachStacktrace:r}=gs();if(z()!==e||Pa())return;let{msg:i,url:a,line:o,column:s,error:c}=t,l=ms(Ya(n,c||i,void 0,r,!1),a,o,s);l.level=`error`,Dr(l,{originalException:c,mechanism:{handled:!1,type:`auto.browser.global_handlers.onerror`}})})}function ds(e){xe(t=>{let{stackParser:n,attachStacktrace:r}=gs();if(z()!==e||Pa())return;let i=fs(t),a=Oe(i)?ps(i):Ya(n,i,void 0,r,!0);a.level=`error`,Dr(a,{originalException:i,mechanism:{handled:!1,type:`auto.browser.global_handlers.onunhandledrejection`}})})}function fs(e){if(Oe(e))return e;try{if(`reason`in e)return e.reason;if(`detail`in e&&`reason`in e.detail)return e.detail.reason}catch{}return e}function ps(e){return{exception:{values:[{type:`UnhandledRejection`,value:`Non-Error promise rejection captured with value: ${String(e)}`}]}}}function ms(e,t,n,r){let i=e.exception=e.exception||{},a=i.values=i.values||[],o=a[0]=a[0]||{},s=o.stacktrace=o.stacktrace||{},c=s.frames=s.frames||[];return c.length===0&&c.push({colno:r,lineno:n,filename:_s(t)??ze(),function:`?`,in_app:!0}),e}function hs(e){Eo&&m.log(`Global Handler attached: ${e}`)}function gs(){return z()?.getOptions()||{stackParser:()=>[],attachStacktrace:!1}}function _s(e){if(!(!x(e)||e.length===0))return e.startsWith(`data:`)?`<${Ii(e,!1)}>`:e}var vs=q(()=>({name:`HttpContext`,preprocessEvent(e){if(!X.navigator&&!X.location&&!X.document)return;let t=Ia(),n={...t.headers,...e.request?.headers};e.request={...t,...e.request,headers:n}}})),ys=`cause`,bs=5,xs=`LinkedErrors`,Ss=q(((e={})=>{let t=e.limit||bs,n=e.key||ys;return{name:xs,preprocessEvent(e,r,i){ra(La,i.getOptions().stackParser,n,t,e,r)}}}));function Cs(){return ws()?(Eo&&u(()=>{console.error(`[Sentry] You cannot use Sentry.init() in a browser extension, see: https://docs.sentry.io/platforms/javascript/best-practices/browser-extensions/`)}),!0):!1}function ws(){if(X.window===void 0)return!1;let e=X;if(e.nw||!(e.chrome||e.browser)?.runtime?.id)return!1;let t=ze();return!(X===X.top&&/^(?:chrome-extension|moz-extension|ms-browser-extension|safari-web-extension):\/\//.test(t))}function Ts(e){return[qi(),Ui(),ba(),Zo(),Vo(),ls(),Ss(),fa(),vs(),os(),is()]}function Es(e={}){let t=!e.skipBrowserExtensionCheck&&Cs(),n=e.defaultIntegrations==null?Ts():e.defaultIntegrations;return Ni(eo,{...e,enabled:t?!1:e.enabled,stackParser:le(e.stackParser||Lo),integrations:Rr({integrations:e.integrations,defaultIntegrations:n}),transport:e.transport||To})}var Ds=e(((e,t)=>{t.exports={}}));function Os(e,t,n,r){if(!(e instanceof Error))throw e;if(!(typeof window>`u`&&t||r))throw e.message+=` on line `+n,e;var i,a,o,s;try{r||=Ds().readFileSync(t,{encoding:`utf8`}),i=3,a=r.split(`
|
|
3
|
+
`),o=Math.max(n-i,0),s=Math.min(a.length,n+i)}catch(r){e.message+=` - could not read from `+t+` (`+r.message+`)`,Os(e,null,n);return}i=a.slice(o,s).map(function(e,t){var r=t+o+1;return(r==n?` > `:` `)+r+`| `+e}).join(`
|
|
4
|
+
`),e.path=t;try{e.message=(t||`Pug`)+`:`+n+`
|
|
5
|
+
`+i+`
|
|
6
|
+
|
|
7
|
+
`+e.message}catch{}throw e}function ks(e){var t=``,n,r;try{r=1,n=`/home/circleci/project/girder/plugins/sentry/girder_sentry/web_client/templates/configView.pug`,t+=`<div class="g-config-breadcrumb-container"></div>`,r=2,n=`/home/circleci/project/girder/plugins/sentry/girder_sentry/web_client/templates/configView.pug`,t+=`<p class="g-sentry-description">`,r=3,n=`/home/circleci/project/girder/plugins/sentry/girder_sentry/web_client/templates/configView.pug`,t+=`To track errors in Sentry, enter your Sentry project DSNs here.</p>`,r=4,n=`/home/circleci/project/girder/plugins/sentry/girder_sentry/web_client/templates/configView.pug`,t+=`<form id="g-sentry-server-form" role="form">`,r=5,n=`/home/circleci/project/girder/plugins/sentry/girder_sentry/web_client/templates/configView.pug`,t+=`<div class="form-group">`,r=6,n=`/home/circleci/project/girder/plugins/sentry/girder_sentry/web_client/templates/configView.pug`,t+=`<label class="control-label" for="g-sentry-server-dsn">`,r=6,n=`/home/circleci/project/girder/plugins/sentry/girder_sentry/web_client/templates/configView.pug`,t+=`Sentry Server DSN</label>`,r=7,n=`/home/circleci/project/girder/plugins/sentry/girder_sentry/web_client/templates/configView.pug`,t+=`<input class="input-sm form-control" id="g-sentry-server-dsn" type="text" placeholder="Tracking ID"/></div>`,r=9,n=`/home/circleci/project/girder/plugins/sentry/girder_sentry/web_client/templates/configView.pug`,t+=`<p class="g-validation-failed-message" id="g-sentry-server-error-message"></p>`,r=10,n=`/home/circleci/project/girder/plugins/sentry/girder_sentry/web_client/templates/configView.pug`,t+=`<input class="btn btn-sm btn-primary" type="submit" value="Save"/></form>`,r=12,n=`/home/circleci/project/girder/plugins/sentry/girder_sentry/web_client/templates/configView.pug`,t+=`<form id="g-sentry-client-form" role="form">`,r=13,n=`/home/circleci/project/girder/plugins/sentry/girder_sentry/web_client/templates/configView.pug`,t+=`<div class="form-group">`,r=14,n=`/home/circleci/project/girder/plugins/sentry/girder_sentry/web_client/templates/configView.pug`,t+=`<label class="control-label" for="g-sentry-client-dsn">`,r=14,n=`/home/circleci/project/girder/plugins/sentry/girder_sentry/web_client/templates/configView.pug`,t+=`Sentry Client DSN</label>`,r=15,n=`/home/circleci/project/girder/plugins/sentry/girder_sentry/web_client/templates/configView.pug`,t+=`<input class="input-sm form-control" id="g-sentry-client-dsn" type="text" placeholder="Tracking ID"/></div>`,r=17,n=`/home/circleci/project/girder/plugins/sentry/girder_sentry/web_client/templates/configView.pug`,t+=`<p class="g-validation-failed-message" id="g-sentry-client-error-message"></p>`,r=18,n=`/home/circleci/project/girder/plugins/sentry/girder_sentry/web_client/templates/configView.pug`,t+=`<input class="btn btn-sm btn-primary" type="submit" value="Save"/></form>`}catch(e){Os(e,n,r)}return t}var As=girder.views.widgets.PluginConfigBreadcrumbWidget,js=girder.views.View,{restRequest:Ms}=girder.rest,Ns=girder.events,Ps=js.extend({events:{"submit #g-sentry-server-form":function(e){e.preventDefault(),this.$(`#g-sentry-server-error-message`).empty(),this._saveSettings([{key:`sentry.backend_dsn`,value:this.$(`#g-sentry-server-dsn`).val().trim()}],{errorTarget:`#g-sentry-server-error-message`})},"submit #g-sentry-client-form":function(e){e.preventDefault(),this.$(`#g-sentry-client-error-message`).empty(),this._saveSettings([{key:`sentry.frontend_dsn`,value:this.$(`#g-sentry-client-dsn`).val().trim()}],{errorTarget:`#g-sentry-client-error-message`})}},initialize:function(){Ms({method:`GET`,url:`system/setting`,data:{list:JSON.stringify([`sentry.backend_dsn`,`sentry.frontend_dsn`])}}).done(e=>{this.render(),this.$(`#g-sentry-server-dsn`).val(e[`sentry.backend_dsn`]),this.$(`#g-sentry-client-dsn`).val(e[`sentry.frontend_dsn`])})},render:function(){return this.$el.html(ks()),this.breadcrumb||=new As({pluginName:`Sentry`,el:this.$(`.g-config-breadcrumb-container`),parentView:this}).render(),this},_saveSettings:function(e,t){Ms({method:`PUT`,url:`system/setting`,data:{list:JSON.stringify(e)},error:null}).done(()=>{Ns.trigger(`g:alert`,{icon:`ok`,text:`Settings saved.`,type:`success`,timeout:4e3})}).fail(e=>{this.$(t.errorTarget).text(e.responseJSON.message)})}}),Fs=girder.router,Is=girder.events,{exposePluginConfig:Ls}=girder.utilities.PluginUtils;Ls(`sentry`,`plugins/sentry/config`),Fs.route(`plugins/sentry/config`,`SentryConfig`,function(){Is.trigger(`g:navigateTo`,Ps)});var Rs=girder.events,{restRequest:zs}=girder.rest;Rs.on(`g:appload.after`,function(){zs({method:`GET`,url:`sentry/dsn`}).done(e=>{e.sentry_dsn&&Es({dsn:e.sentry_dsn})})})});
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
(function(e){typeof define==`function`&&define.amd?define([],e):e()})(function(){var e=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),t=typeof __SENTRY_DEBUG__>`u`||__SENTRY_DEBUG__,n=globalThis,r=`10.46.0`;function i(){return a(n),n}function a(e){let t=e.__SENTRY__=e.__SENTRY__||{};return t.version=t.version||`10.46.0`,t[r]=t[`10.46.0`]||{}}function o(e,t,i=n){let a=i.__SENTRY__=i.__SENTRY__||{},o=a[r]=a[`10.46.0`]||{};return o[e]||(o[e]=t())}var s=[`debug`,`info`,`warn`,`error`,`log`,`assert`,`trace`],c=`Sentry Logger `,l={};function u(e){if(!(`console`in n))return e();let t=n.console,r={},i=Object.keys(l);i.forEach(e=>{let n=l[e];r[e]=t[e],t[e]=n});try{return e()}finally{i.forEach(e=>{t[e]=r[e]})}}function d(){ie().enabled=!0}function f(){ie().enabled=!1}function p(){return ie().enabled}function ee(...e){re(`log`,...e)}function te(...e){re(`warn`,...e)}function ne(...e){re(`error`,...e)}function re(e,...r){t&&p()&&u(()=>{n.console[e](`${c}[${e}]:`,...r)})}function ie(){return t?o(`loggerSettings`,()=>({enabled:!1})):{enabled:!1}}var m={enable:d,disable:f,isEnabled:p,log:ee,warn:te,error:ne},ae=50,oe=/\(error: (.*)\)/,se=/captureMessage|captureException/;function ce(...e){let t=e.sort((e,t)=>e[0]-t[0]).map(e=>e[1]);return(e,n=0,r=0)=>{let i=[],a=e.split(`
|
|
2
|
-
`);for(let e=n;e<a.length;e++){let n=a[e];n.length>1024&&(n=n.slice(0,1024));let o=oe.test(n)?n.replace(oe,`$1`):n;if(!o.match(/\S*Error: /)){for(let e of t){let t=e(o);if(t){i.push(t);break}}if(i.length>=ae+r)break}}return ue(i.slice(r))}}function le(e){return Array.isArray(e)?ce(...e):e}function ue(e){if(!e.length)return[];let t=Array.from(e);return/sentryWrapped/.test(de(t).function||``)&&t.pop(),t.reverse(),se.test(de(t).function||``)&&(t.pop(),se.test(de(t).function||``)&&t.pop()),t.slice(0,ae).map(e=>({...e,filename:e.filename||de(t).filename,function:e.function||`?`}))}function de(e){return e[e.length-1]||{}}var fe=`<anonymous>`;function h(e){try{return!e||typeof e!=`function`?fe:e.name||fe}catch{return fe}}function pe(e){let t=e.exception;if(t){let e=[];try{return t.values.forEach(t=>{t.stacktrace.frames&&e.push(...t.stacktrace.frames)}),e}catch{return}}}function me(e){return`__v_isVNode`in e&&e.__v_isVNode?`[VueVNode]`:`[VueViewModel]`}var he={},ge={};function g(e,t){he[e]=he[e]||[],he[e].push(t)}function _(e,n){if(!ge[e]){ge[e]=!0;try{n()}catch(n){t&&m.error(`Error while instrumenting ${e}`,n)}}}function v(e,n){let r=e&&he[e];if(r)for(let i of r)try{i(n)}catch(n){t&&m.error(`Error while triggering instrumentation handler.\nType: ${e}\nName: ${h(i)}\nError:`,n)}}var _e=null;function ve(e){let t=`error`;g(t,e),_(t,ye)}function ye(){_e=n.onerror,n.onerror=function(e,t,n,r,i){return v(`error`,{column:r,error:i,line:n,msg:e,url:t}),_e?_e.apply(this,arguments):!1},n.onerror.__SENTRY_INSTRUMENTED__=!0}var be=null;function xe(e){let t=`unhandledrejection`;g(t,e),_(t,Se)}function Se(){be=n.onunhandledrejection,n.onunhandledrejection=function(e){return v(`unhandledrejection`,e),be?be.apply(this,arguments):!0},n.onunhandledrejection.__SENTRY_INSTRUMENTED__=!0}var Ce=Object.prototype.toString;function y(e){switch(Ce.call(e)){case`[object Error]`:case`[object Exception]`:case`[object DOMException]`:case`[object WebAssembly.Exception]`:return!0;default:return w(e,Error)}}function b(e,t){return Ce.call(e)===`[object ${t}]`}function we(e){return b(e,`ErrorEvent`)}function Te(e){return b(e,`DOMError`)}function Ee(e){return b(e,`DOMException`)}function x(e){return b(e,`String`)}function De(e){return typeof e==`object`&&!!e&&`__sentry_template_string__`in e&&`__sentry_template_values__`in e}function Oe(e){return e===null||De(e)||typeof e!=`object`&&typeof e!=`function`}function S(e){return b(e,`Object`)}function ke(e){return typeof Event<`u`&&w(e,Event)}function Ae(e){return typeof Element<`u`&&w(e,Element)}function je(e){return b(e,`RegExp`)}function C(e){return!!(e?.then&&typeof e.then==`function`)}function Me(e){return S(e)&&`nativeEvent`in e&&`preventDefault`in e&&`stopPropagation`in e}function w(e,t){try{return e instanceof t}catch{return!1}}function Ne(e){return!!(typeof e==`object`&&e&&(e.__isVue||e._isVue||e.__v_isVNode))}function Pe(e){return typeof Request<`u`&&w(e,Request)}var Fe=n,Ie=80;function Le(e,t={}){if(!e)return`<unknown>`;try{let n=e,r=[],i=0,a=0,o,s=Array.isArray(t)?t:t.keyAttrs,c=!Array.isArray(t)&&t.maxStringLength||Ie;for(;n&&i++<5&&(o=Re(n,s),!(o===`html`||i>1&&a+r.length*3+o.length>=c));)r.push(o),a+=o.length,n=n.parentNode;return r.reverse().join(` > `)}catch{return`<unknown>`}}function Re(e,t){let n=e,r=[];if(!n?.tagName)return``;if(Fe.HTMLElement&&n instanceof HTMLElement&&n.dataset){if(n.dataset.sentryComponent)return n.dataset.sentryComponent;if(n.dataset.sentryElement)return n.dataset.sentryElement}r.push(n.tagName.toLowerCase());let i=t?.length?t.filter(e=>n.getAttribute(e)).map(e=>[e,n.getAttribute(e)]):null;if(i?.length)i.forEach(e=>{r.push(`[${e[0]}="${e[1]}"]`)});else{n.id&&r.push(`#${n.id}`);let e=n.className;if(e&&x(e)){let t=e.split(/\s+/);for(let e of t)r.push(`.${e}`)}}for(let e of[`aria-label`,`type`,`name`,`title`,`alt`]){let t=n.getAttribute(e);t&&r.push(`[${e}="${t}"]`)}return r.join(``)}function ze(){try{return Fe.document.location.href}catch{return``}}function Be(e){if(!Fe.HTMLElement)return null;let t=e;for(let e=0;e<5;e++){if(!t)return null;if(t instanceof HTMLElement){if(t.dataset.sentryComponent)return t.dataset.sentryComponent;if(t.dataset.sentryElement)return t.dataset.sentryElement}t=t.parentNode}return null}function T(e,n,r){if(!(n in e))return;let i=e[n];if(typeof i!=`function`)return;let a=r(i);typeof a==`function`&&Ve(a,i);try{e[n]=a}catch{t&&m.log(`Failed to replace method "${n}" in object`,e)}}function E(e,n,r){try{Object.defineProperty(e,n,{value:r,writable:!0,configurable:!0})}catch{t&&m.log(`Failed to add non-enumerable property "${n}" to object`,e)}}function Ve(e,t){try{e.prototype=t.prototype=t.prototype||{},E(e,`__sentry_original__`,t)}catch{}}function He(e){return e.__sentry_original__}function Ue(e){if(y(e))return{message:e.message,name:e.name,stack:e.stack,...Ge(e)};if(ke(e)){let t={type:e.type,target:We(e.target),currentTarget:We(e.currentTarget),...Ge(e)};return typeof CustomEvent<`u`&&w(e,CustomEvent)&&(t.detail=e.detail),t}else return e}function We(e){try{return Ae(e)?Le(e):Object.prototype.toString.call(e)}catch{return`<unknown>`}}function Ge(e){return typeof e==`object`&&e?Object.fromEntries(Object.entries(e)):{}}function Ke(e){let t=Object.keys(Ue(e));return t.sort(),t[0]?t.join(`, `):`[object has no keys]`}var D;function qe(e){if(D!==void 0)return D?D(e):e();let t=Symbol.for(`__SENTRY_SAFE_RANDOM_ID_WRAPPER__`),r=n;return t in r&&typeof r[t]==`function`?(D=r[t],D(e)):(D=null,e())}function Je(){return qe(()=>Math.random())}function Ye(){return qe(()=>Date.now())}function Xe(e,t=0){return typeof e!=`string`||t===0||e.length<=t?e:`${e.slice(0,t)}...`}function Ze(e,t){if(!Array.isArray(e))return``;let n=[];for(let t=0;t<e.length;t++){let r=e[t];try{Ne(r)?n.push(me(r)):n.push(String(r))}catch{n.push(`[value cannot be serialized]`)}}return n.join(t)}function Qe(e,t,n=!1){return x(e)?je(t)?t.test(e):x(t)?n?e===t:e.includes(t):!1:!1}function $e(e,t=[],n=!1){return t.some(t=>Qe(e,t,n))}function et(){let e=n;return e.crypto||e.msCrypto}var tt;function nt(){return Je()*16}function O(e=et()){try{if(e?.randomUUID)return qe(()=>e.randomUUID()).replace(/-/g,``)}catch{}return tt||=`10000000100040008000100000000000`,tt.replace(/[018]/g,e=>(e^(nt()&15)>>e/4).toString(16))}function rt(e){return e.exception?.values?.[0]}function k(e){let{message:t,event_id:n}=e;if(t)return t;let r=rt(e);return r?r.type&&r.value?`${r.type}: ${r.value}`:r.type||r.value||n||`<unknown>`:n||`<unknown>`}function it(e,t,n){let r=e.exception=e.exception||{},i=r.values=r.values||[],a=i[0]=i[0]||{};a.value||=t||``,a.type||=n||`Error`}function A(e,t){let n=rt(e);if(!n)return;let r={type:`generic`,handled:!0},i=n.mechanism;if(n.mechanism={...r,...i,...t},t&&`data`in t){let e={...i?.data,...t.data};n.mechanism.data=e}}function at(e){if(ot(e))return!0;try{E(e,`__sentry_captured__`,!0)}catch{}return!1}function ot(e){try{return e.__sentry_captured__}catch{}}var st=1e3;function j(){return Ye()/st}function ct(){let{performance:e}=n;if(!e?.now||!e.timeOrigin)return j;let t=e.timeOrigin;return()=>(t+qe(()=>e.now()))/st}var lt;function M(){return(lt??=ct())()}function ut(e){let t=M(),n={sid:O(),init:!0,timestamp:t,started:t,duration:0,status:`ok`,errors:0,ignoreDuration:!1,toJSON:()=>ft(n)};return e&&N(n,e),n}function N(e,t={}){if(t.user&&(!e.ipAddress&&t.user.ip_address&&(e.ipAddress=t.user.ip_address),!e.did&&!t.did&&(e.did=t.user.id||t.user.email||t.user.username)),e.timestamp=t.timestamp||M(),t.abnormal_mechanism&&(e.abnormal_mechanism=t.abnormal_mechanism),t.ignoreDuration&&(e.ignoreDuration=t.ignoreDuration),t.sid&&(e.sid=t.sid.length===32?t.sid:O()),t.init!==void 0&&(e.init=t.init),!e.did&&t.did&&(e.did=`${t.did}`),typeof t.started==`number`&&(e.started=t.started),e.ignoreDuration)e.duration=void 0;else if(typeof t.duration==`number`)e.duration=t.duration;else{let t=e.timestamp-e.started;e.duration=t>=0?t:0}t.release&&(e.release=t.release),t.environment&&(e.environment=t.environment),!e.ipAddress&&t.ipAddress&&(e.ipAddress=t.ipAddress),!e.userAgent&&t.userAgent&&(e.userAgent=t.userAgent),typeof t.errors==`number`&&(e.errors=t.errors),t.status&&(e.status=t.status)}function dt(e,t){let n={};t?n={status:t}:e.status===`ok`&&(n={status:`exited`}),N(e,n)}function ft(e){return{sid:`${e.sid}`,init:e.init,started:new Date(e.started*1e3).toISOString(),timestamp:new Date(e.timestamp*1e3).toISOString(),status:e.status,errors:e.errors,did:typeof e.did==`number`||typeof e.did==`string`?`${e.did}`:void 0,duration:e.duration,abnormal_mechanism:e.abnormal_mechanism,attrs:{release:e.release,environment:e.environment,ip_address:e.ipAddress,user_agent:e.userAgent}}}function P(e,t,n=2){if(!t||typeof t!=`object`||n<=0)return t;if(e&&Object.keys(t).length===0)return e;let r={...e};for(let e in t)Object.prototype.hasOwnProperty.call(t,e)&&(r[e]=P(r[e],t[e],n-1));return r}function pt(){return O()}function mt(){return O().substring(16)}var ht=`_sentrySpan`;function gt(e,t){t?E(e,ht,t):delete e[ht]}function _t(e){return e[ht]}var vt=100,F=class e{constructor(){this._notifyingListeners=!1,this._scopeListeners=[],this._eventProcessors=[],this._breadcrumbs=[],this._attachments=[],this._user={},this._tags={},this._attributes={},this._extra={},this._contexts={},this._sdkProcessingMetadata={},this._propagationContext={traceId:pt(),sampleRand:Je()}}clone(){let t=new e;return t._breadcrumbs=[...this._breadcrumbs],t._tags={...this._tags},t._attributes={...this._attributes},t._extra={...this._extra},t._contexts={...this._contexts},this._contexts.flags&&(t._contexts.flags={values:[...this._contexts.flags.values]}),t._user=this._user,t._level=this._level,t._session=this._session,t._transactionName=this._transactionName,t._fingerprint=this._fingerprint,t._eventProcessors=[...this._eventProcessors],t._attachments=[...this._attachments],t._sdkProcessingMetadata={...this._sdkProcessingMetadata},t._propagationContext={...this._propagationContext},t._client=this._client,t._lastEventId=this._lastEventId,t._conversationId=this._conversationId,gt(t,_t(this)),t}setClient(e){this._client=e}setLastEventId(e){this._lastEventId=e}getClient(){return this._client}lastEventId(){return this._lastEventId}addScopeListener(e){this._scopeListeners.push(e)}addEventProcessor(e){return this._eventProcessors.push(e),this}setUser(e){return this._user=e||{email:void 0,id:void 0,ip_address:void 0,username:void 0},this._session&&N(this._session,{user:e}),this._notifyScopeListeners(),this}getUser(){return this._user}setConversationId(e){return this._conversationId=e||void 0,this._notifyScopeListeners(),this}setTags(e){return this._tags={...this._tags,...e},this._notifyScopeListeners(),this}setTag(e,t){return this.setTags({[e]:t})}setAttributes(e){return this._attributes={...this._attributes,...e},this._notifyScopeListeners(),this}setAttribute(e,t){return this.setAttributes({[e]:t})}removeAttribute(e){return e in this._attributes&&(delete this._attributes[e],this._notifyScopeListeners()),this}setExtras(e){return this._extra={...this._extra,...e},this._notifyScopeListeners(),this}setExtra(e,t){return this._extra={...this._extra,[e]:t},this._notifyScopeListeners(),this}setFingerprint(e){return this._fingerprint=e,this._notifyScopeListeners(),this}setLevel(e){return this._level=e,this._notifyScopeListeners(),this}setTransactionName(e){return this._transactionName=e,this._notifyScopeListeners(),this}setContext(e,t){return t===null?delete this._contexts[e]:this._contexts[e]=t,this._notifyScopeListeners(),this}setSession(e){return e?this._session=e:delete this._session,this._notifyScopeListeners(),this}getSession(){return this._session}update(t){if(!t)return this;let n=typeof t==`function`?t(this):t,{tags:r,attributes:i,extra:a,user:o,contexts:s,level:c,fingerprint:l=[],propagationContext:u,conversationId:d}=(n instanceof e?n.getScopeData():S(n)?t:void 0)||{};return this._tags={...this._tags,...r},this._attributes={...this._attributes,...i},this._extra={...this._extra,...a},this._contexts={...this._contexts,...s},o&&Object.keys(o).length&&(this._user=o),c&&(this._level=c),l.length&&(this._fingerprint=l),u&&(this._propagationContext=u),d&&(this._conversationId=d),this}clear(){return this._breadcrumbs=[],this._tags={},this._attributes={},this._extra={},this._user={},this._contexts={},this._level=void 0,this._transactionName=void 0,this._fingerprint=void 0,this._session=void 0,this._conversationId=void 0,gt(this,void 0),this._attachments=[],this.setPropagationContext({traceId:pt(),sampleRand:Je()}),this._notifyScopeListeners(),this}addBreadcrumb(e,t){let n=typeof t==`number`?t:vt;if(n<=0)return this;let r={timestamp:j(),...e,message:e.message?Xe(e.message,2048):e.message};return this._breadcrumbs.push(r),this._breadcrumbs.length>n&&(this._breadcrumbs=this._breadcrumbs.slice(-n),this._client?.recordDroppedEvent(`buffer_overflow`,`log_item`)),this._notifyScopeListeners(),this}getLastBreadcrumb(){return this._breadcrumbs[this._breadcrumbs.length-1]}clearBreadcrumbs(){return this._breadcrumbs=[],this._notifyScopeListeners(),this}addAttachment(e){return this._attachments.push(e),this}clearAttachments(){return this._attachments=[],this}getScopeData(){return{breadcrumbs:this._breadcrumbs,attachments:this._attachments,contexts:this._contexts,tags:this._tags,attributes:this._attributes,extra:this._extra,user:this._user,level:this._level,fingerprint:this._fingerprint||[],eventProcessors:this._eventProcessors,propagationContext:this._propagationContext,sdkProcessingMetadata:this._sdkProcessingMetadata,transactionName:this._transactionName,span:_t(this),conversationId:this._conversationId}}setSDKProcessingMetadata(e){return this._sdkProcessingMetadata=P(this._sdkProcessingMetadata,e,2),this}setPropagationContext(e){return this._propagationContext=e,this}getPropagationContext(){return this._propagationContext}captureException(e,n){let r=n?.event_id||O();if(!this._client)return t&&m.warn(`No client configured on scope - will not capture exception!`),r;let i=Error(`Sentry syntheticException`);return this._client.captureException(e,{originalException:e,syntheticException:i,...n,event_id:r},this),r}captureMessage(e,n,r){let i=r?.event_id||O();if(!this._client)return t&&m.warn(`No client configured on scope - will not capture message!`),i;let a=r?.syntheticException??Error(e);return this._client.captureMessage(e,n,{originalException:e,syntheticException:a,...r,event_id:i},this),i}captureEvent(e,n){let r=e.event_id||n?.event_id||O();return this._client?(this._client.captureEvent(e,{...n,event_id:r},this),r):(t&&m.warn(`No client configured on scope - will not capture event!`),r)}_notifyScopeListeners(){this._notifyingListeners||=(this._notifyingListeners=!0,this._scopeListeners.forEach(e=>{e(this)}),!1)}};function yt(){return o(`defaultCurrentScope`,()=>new F)}function bt(){return o(`defaultIsolationScope`,()=>new F)}var xt=e=>e instanceof Promise&&!e[St],St=Symbol(`chained PromiseLike`),Ct=(e,t,n)=>{let r=e.then(e=>(t(e),e),e=>{throw n(e),e});return xt(r)&&xt(e)?r:wt(e,r)},wt=(e,t)=>{let n=!1;for(let r in e){if(r in t)continue;n=!0;let i=e[r];typeof i==`function`?Object.defineProperty(t,r,{value:(...t)=>i.apply(e,t),enumerable:!0,configurable:!0,writable:!0}):t[r]=i}return n&&Object.assign(t,{[St]:!0}),t},Tt=class{constructor(e,t){let n;n=e||new F;let r;r=t||new F,this._stack=[{scope:n}],this._isolationScope=r}withScope(e){let t=this._pushScope(),n;try{n=e(t)}catch(e){throw this._popScope(),e}return C(n)?Ct(n,()=>this._popScope(),()=>this._popScope()):(this._popScope(),n)}getClient(){return this.getStackTop().client}getScope(){return this.getStackTop().scope}getIsolationScope(){return this._isolationScope}getStackTop(){return this._stack[this._stack.length-1]}_pushScope(){let e=this.getScope().clone();return this._stack.push({client:this.getClient(),scope:e}),e}_popScope(){return this._stack.length<=1?!1:!!this._stack.pop()}};function I(){let e=a(i());return e.stack=e.stack||new Tt(yt(),bt())}function Et(e){return I().withScope(e)}function Dt(e,t){let n=I();return n.withScope(()=>(n.getStackTop().scope=e,t(e)))}function Ot(e){return I().withScope(()=>e(I().getIsolationScope()))}function kt(){return{withIsolationScope:Ot,withScope:Et,withSetScope:Dt,withSetIsolationScope:(e,t)=>Ot(t),getCurrentScope:()=>I().getScope(),getIsolationScope:()=>I().getIsolationScope()}}function At(e){let t=a(e);return t.acs?t.acs:kt()}function L(){return At(i()).getCurrentScope()}function R(){return At(i()).getIsolationScope()}function jt(){return o(`globalScope`,()=>new F)}function Mt(...e){let t=At(i());if(e.length===2){let[n,r]=e;return n?t.withSetScope(n,r):t.withScope(r)}return t.withScope(e[0])}function z(){return L().getClient()}function Nt(e){let{traceId:t,parentSpanId:n,propagationSpanId:r}=e.getPropagationContext(),i={trace_id:t,span_id:r||mt()};return n&&(i.parent_span_id=n),i}var Pt=`sentry.source`,Ft=`sentry.op`,It=`sentry.origin`,Lt=`sentry.profile_id`,Rt=`sentry.exclusive_time`,zt=`gen_ai.conversation.id`,Bt=`_sentryScope`,Vt=`_sentryIsolationScope`;function Ht(e){if(e){if(typeof e==`object`&&`deref`in e&&typeof e.deref==`function`)try{return e.deref()}catch{return}return e}}function Ut(e){let t=e;return{scope:t[Bt],isolationScope:Ht(t[Vt])}}function Wt(e){let t=Gt(e);if(!t)return;let n=Object.entries(t).reduce((e,[t,n])=>{if(t.startsWith(`sentry-`)){let r=t.slice(7);e[r]=n}return e},{});if(Object.keys(n).length>0)return n}function Gt(e){if(!(!e||!x(e)&&!Array.isArray(e)))return Array.isArray(e)?e.reduce((e,t)=>{let n=Kt(t);return Object.entries(n).forEach(([t,n])=>{e[t]=n}),e},{}):Kt(e)}function Kt(e){return e.split(`,`).map(e=>{let t=e.indexOf(`=`);return t===-1?[]:[e.slice(0,t),e.slice(t+1)].map(e=>{try{return decodeURIComponent(e.trim())}catch{return}})}).reduce((e,[t,n])=>(t&&n&&(e[t]=n),e),{})}var qt=/^o(\d+)\./,Jt=/^(?:(\w+):)\/\/(?:(\w+)(?::(\w+)?)?@)((?:\[[:.%\w]+\]|[\w.-]+))(?::(\d+))?\/(.+)/;function Yt(e){return e===`http`||e===`https`}function B(e,t=!1){let{host:n,path:r,pass:i,port:a,projectId:o,protocol:s,publicKey:c}=e;return`${s}://${c}${t&&i?`:${i}`:``}@${n}${a?`:${a}`:``}/${r&&`${r}/`}${o}`}function Xt(e){let t=Jt.exec(e);if(!t){u(()=>{console.error(`Invalid Sentry Dsn: ${e}`)});return}let[n,r,i=``,a=``,o=``,s=``]=t.slice(1),c=``,l=s,d=l.split(`/`);if(d.length>1&&(c=d.slice(0,-1).join(`/`),l=d.pop()),l){let e=l.match(/^\d+/);e&&(l=e[0])}return Zt({host:a,pass:i,path:c,projectId:l,port:o,protocol:n,publicKey:r})}function Zt(e){return{protocol:e.protocol,publicKey:e.publicKey||``,pass:e.pass||``,host:e.host,port:e.port||``,path:e.path||``,projectId:e.projectId}}function Qt(e){if(!t)return!0;let{port:n,projectId:r,protocol:i}=e;return[`protocol`,`publicKey`,`host`,`projectId`].find(t=>e[t]?!1:(m.error(`Invalid Sentry Dsn: ${t} missing`),!0))?!1:r.match(/^\d+$/)?Yt(i)?n&&isNaN(parseInt(n,10))?(m.error(`Invalid Sentry Dsn: Invalid port ${n}`),!1):!0:(m.error(`Invalid Sentry Dsn: Invalid protocol ${i}`),!1):(m.error(`Invalid Sentry Dsn: Invalid projectId ${r}`),!1)}function $t(e){return e.match(qt)?.[1]}function en(e){let t=e.getOptions(),{host:n}=e.getDsn()||{},r;return t.orgId?r=String(t.orgId):n&&(r=$t(n)),r}function tn(e){let t=typeof e==`string`?Xt(e):Zt(e);if(!(!t||!Qt(t)))return t}function nn(e){if(typeof e==`boolean`)return Number(e);let t=typeof e==`string`?parseFloat(e):e;if(!(typeof t!=`number`||isNaN(t)||t<0||t>1))return t}var rn=!1;function an(e){let{spanId:t,traceId:n,isRemote:r}=e.spanContext(),i=r?t:ln(e).parent_span_id,a=Ut(e).scope;return{parent_span_id:i,span_id:r?a?.getPropagationContext().propagationSpanId||mt():t,trace_id:n}}function on(e){if(e&&e.length>0)return e.map(({context:{spanId:e,traceId:t,traceFlags:n,...r},attributes:i})=>({span_id:e,trace_id:t,sampled:n===1,attributes:i,...r}))}function sn(e){return typeof e==`number`?cn(e):Array.isArray(e)?e[0]+e[1]/1e9:e instanceof Date?cn(e.getTime()):M()}function cn(e){return e>9999999999?e/1e3:e}function ln(e){if(dn(e))return e.getSpanJSON();let{spanId:t,traceId:n}=e.spanContext();if(un(e)){let{attributes:r,startTime:i,name:a,endTime:o,status:s,links:c}=e;return{span_id:t,trace_id:n,data:r,description:a,parent_span_id:`parentSpanId`in e?e.parentSpanId:`parentSpanContext`in e?e.parentSpanContext?.spanId:void 0,start_timestamp:sn(i),timestamp:sn(o)||void 0,status:pn(s),op:r[Ft],origin:r[It],links:on(c)}}return{span_id:t,trace_id:n,start_timestamp:0,data:{}}}function un(e){let t=e;return!!t.attributes&&!!t.startTime&&!!t.name&&!!t.endTime&&!!t.status}function dn(e){return typeof e.getSpanJSON==`function`}function fn(e){let{traceFlags:t}=e.spanContext();return t===1}function pn(e){if(!(!e||e.code===0))return e.code===1?`ok`:e.message||`internal_error`}var mn=`_sentryRootSpan`;function hn(e){return e[mn]||e}function gn(){rn||=(u(()=>{console.warn("[Sentry] Returning null from `beforeSendSpan` is disallowed. To drop certain spans, configure the respective integrations directly or use `ignoreSpans`.")}),!0)}function _n(e){if(typeof __SENTRY_TRACING__==`boolean`&&!__SENTRY_TRACING__)return!1;let t=e||z()?.getOptions();return!!t&&(t.tracesSampleRate!=null||!!t.tracesSampler)}function vn(e){m.log(`Ignoring span ${e.op} - ${e.description} because it matches \`ignoreSpans\`.`)}function yn(e,n){if(!n?.length||!e.description)return!1;for(let r of n){if(xn(r)){if(Qe(e.description,r))return t&&vn(e),!0;continue}if(!r.name&&!r.op)continue;let n=r.name?Qe(e.description,r.name):!0,i=r.op?e.op&&Qe(e.op,r.op):!0;if(n&&i)return t&&vn(e),!0}return!1}function bn(e,t){let n=t.parent_span_id,r=t.span_id;if(n)for(let t of e)t.parent_span_id===r&&(t.parent_span_id=n)}function xn(e){return typeof e==`string`||e instanceof RegExp}var Sn=`production`,Cn=`_frozenDsc`;function wn(e,t){let n=t.getOptions(),{publicKey:r}=t.getDsn()||{},i={environment:n.environment||`production`,release:n.release,public_key:r,trace_id:e,org_id:en(t)};return t.emit(`createDsc`,i),i}function Tn(e,t){let n=t.getPropagationContext();return n.dsc||wn(n.traceId,e)}function En(e){let t=z();if(!t)return{};let n=hn(e),r=ln(n),i=r.data,a=n.spanContext().traceState,o=a?.get(`sentry.sample_rate`)??i[`sentry.sample_rate`]??i[`sentry.previous_trace_sample_rate`];function s(e){return(typeof o==`number`||typeof o==`string`)&&(e.sample_rate=`${o}`),e}let c=n[Cn];if(c)return s(c);let l=a?.get(`sentry.dsc`),u=l&&Wt(l);if(u)return s(u);let d=wn(e.spanContext().traceId,t),f=i[Pt],p=r.description;return f!==`url`&&p&&(d.transaction=p),_n()&&(d.sampled=String(fn(n)),d.sample_rand=a?.get(`sentry.sample_rand`)??Ut(n).scope?.getPropagationContext().sampleRand.toString()),s(d),t.emit(`createDsc`,d,n),d}function V(e,t=100,n=1/0){try{return On(``,e,t,n)}catch(e){return{ERROR:`**non-serializable** (${e})`}}}function Dn(e,t=3,n=100*1024){let r=V(e,t);return Mn(r)>n?Dn(e,t-1,n):r}function On(e,t,n=1/0,r=1/0,i=Nn()){let[a,o]=i;if(t==null||[`boolean`,`string`].includes(typeof t)||typeof t==`number`&&Number.isFinite(t))return t;let s=kn(e,t);if(!s.startsWith(`[object `))return s;if(t.__sentry_skip_normalization__)return t;let c=typeof t.__sentry_override_normalization_depth__==`number`?t.__sentry_override_normalization_depth__:n;if(c===0)return s.replace(`object `,``);if(a(t))return`[Circular ~]`;let l=t;if(l&&typeof l.toJSON==`function`)try{return On(``,l.toJSON(),c-1,r,i)}catch{}let u=Array.isArray(t)?[]:{},d=0,f=Ue(t);for(let e in f){if(!Object.prototype.hasOwnProperty.call(f,e))continue;if(d>=r){u[e]=`[MaxProperties ~]`;break}let t=f[e];u[e]=On(e,t,c-1,r,i),d++}return o(t),u}function kn(e,t){try{if(e===`domain`&&t&&typeof t==`object`&&t._events)return`[Domain]`;if(e===`domainEmitter`)return`[DomainEmitter]`;if(typeof global<`u`&&t===global)return`[Global]`;if(typeof window<`u`&&t===window)return`[Window]`;if(typeof document<`u`&&t===document)return`[Document]`;if(Ne(t))return me(t);if(Me(t))return`[SyntheticEvent]`;if(typeof t==`number`&&!Number.isFinite(t))return`[${t}]`;if(typeof t==`function`)return`[Function: ${h(t)}]`;if(typeof t==`symbol`)return`[${String(t)}]`;if(typeof t==`bigint`)return`[BigInt: ${String(t)}]`;let n=An(t);return/^HTML(\w*)Element$/.test(n)?`[HTMLElement: ${n}]`:`[object ${n}]`}catch(e){return`**non-serializable** (${e})`}}function An(e){let t=Object.getPrototypeOf(e);return t?.constructor?t.constructor.name:`null prototype`}function jn(e){return~-encodeURI(e).split(/%..|./).length}function Mn(e){return jn(JSON.stringify(e))}function Nn(){let e=new WeakSet;function t(t){return e.has(t)?!0:(e.add(t),!1)}function n(t){e.delete(t)}return[t,n]}function H(e,t=[]){return[e,t]}function Pn(e,t){let[n,r]=e;return[n,[...r,t]]}function Fn(e,t){let n=e[1];for(let e of n){let n=e[0].type;if(t(e,n))return!0}return!1}function In(e,t){return Fn(e,(e,n)=>t.includes(n))}function Ln(e){let t=a(n);return t.encodePolyfill?t.encodePolyfill(e):new TextEncoder().encode(e)}function Rn(e){let[t,n]=e,r=JSON.stringify(t);function i(e){typeof r==`string`?r=typeof e==`string`?r+e:[Ln(r),e]:r.push(typeof e==`string`?Ln(e):e)}for(let e of n){let[t,n]=e;if(i(`\n${JSON.stringify(t)}\n`),typeof n==`string`||n instanceof Uint8Array)i(n);else{let e;try{e=JSON.stringify(n)}catch{e=JSON.stringify(V(n))}i(e)}}return typeof r==`string`?r:zn(r)}function zn(e){let t=e.reduce((e,t)=>e+t.length,0),n=new Uint8Array(t),r=0;for(let t of e)n.set(t,r),r+=t.length;return n}function Bn(e){let t=typeof e.data==`string`?Ln(e.data):e.data;return[{type:`attachment`,length:t.length,filename:e.filename,content_type:e.contentType,attachment_type:e.attachmentType},t]}var Vn={sessions:`session`,event:`error`,client_report:`internal`,user_report:`default`,profile_chunk:`profile`,replay_event:`replay`,replay_recording:`replay`,check_in:`monitor`,raw_security:`security`,log:`log_item`,trace_metric:`metric`};function Hn(e){return e in Vn}function Un(e){return Hn(e)?Vn[e]:e}function Wn(e){if(!e?.sdk)return;let{name:t,version:n}=e.sdk;return{name:t,version:n}}function Gn(e,t,n,r){let i=e.sdkProcessingMetadata?.dynamicSamplingContext;return{event_id:e.event_id,sent_at:new Date().toISOString(),...t&&{sdk:t},...!!n&&r&&{dsn:B(r)},...i&&{trace:i}}}function Kn(e,t){if(!t)return e;let n=e.sdk||{};return e.sdk={...n,name:n.name||t.name,version:n.version||t.version,integrations:[...e.sdk?.integrations||[],...t.integrations||[]],packages:[...e.sdk?.packages||[],...t.packages||[]],settings:e.sdk?.settings||t.settings?{...e.sdk?.settings,...t.settings}:void 0},e}function qn(e,t,n,r){let i=Wn(n);return H({sent_at:new Date().toISOString(),...i&&{sdk:i},...!!r&&t&&{dsn:B(t)}},[`aggregates`in e?[{type:`sessions`},e]:[{type:`session`},e.toJSON()]])}function Jn(e,t,n,r){let i=Wn(n),a=e.type&&e.type!==`replay_event`?e.type:`event`;Kn(e,n?.sdk);let o=Gn(e,i,r,t);return delete e.sdkProcessingMetadata,H(o,[[{type:a},e]])}var Yn=0,Xn=1,Zn=2;function U(e){return new $n(t=>{t(e)})}function Qn(e){return new $n((t,n)=>{n(e)})}var $n=class e{constructor(e){this._state=Yn,this._handlers=[],this._runExecutor(e)}then(t,n){return new e((e,r)=>{this._handlers.push([!1,n=>{if(!t)e(n);else try{e(t(n))}catch(e){r(e)}},t=>{if(!n)r(t);else try{e(n(t))}catch(e){r(e)}}]),this._executeHandlers()})}catch(e){return this.then(e=>e,e)}finally(t){return new e((e,n)=>{let r,i;return this.then(e=>{i=!1,r=e,t&&t()},e=>{i=!0,r=e,t&&t()}).then(()=>{if(i){n(r);return}e(r)})})}_executeHandlers(){if(this._state===Yn)return;let e=this._handlers.slice();this._handlers=[],e.forEach(e=>{e[0]||=(this._state===Xn&&e[1](this._value),this._state===Zn&&e[2](this._value),!0)})}_runExecutor(e){let t=(e,t)=>{if(this._state===Yn){if(C(t)){t.then(n,r);return}this._state=e,this._value=t,this._executeHandlers()}},n=e=>{t(Xn,e)},r=e=>{t(Zn,e)};try{e(n,r)}catch(e){r(e)}}};function er(e,t,n,r=0){try{let i=tr(t,n,e,r);return C(i)?i:U(i)}catch(e){return Qn(e)}}function tr(e,n,r,i){let a=r[i];if(!e||!a)return e;let o=a({...e},n);return t&&o===null&&m.log(`Event processor "${a.id||`?`}" dropped event`),C(o)?o.then(e=>tr(e,n,r,i+1)):tr(o,n,r,i+1)}var W,nr,rr,G;function ir(e){let t=n._sentryDebugIds,r=n._debugIds;if(!t&&!r)return{};let i=t?Object.keys(t):[],a=r?Object.keys(r):[];if(G&&i.length===nr&&a.length===rr)return G;nr=i.length,rr=a.length,G={},W||={};let o=(t,n)=>{for(let r of t){let t=n[r],i=W?.[r];if(i&&G&&t)G[i[0]]=t,W&&(W[r]=[i[0],t]);else if(t){let n=e(r);for(let e=n.length-1;e>=0;e--){let i=n[e]?.filename;if(i&&G&&W){G[i]=t,W[r]=[i,t];break}}}}};return t&&o(i,t),r&&o(a,r),G}function ar(e,t){let{fingerprint:n,span:r,breadcrumbs:i,sdkProcessingMetadata:a}=t;cr(e,t),r&&dr(e,r),fr(e,n),lr(e,i),ur(e,a)}function or(e,t){let{extra:n,tags:r,attributes:i,user:a,contexts:o,level:s,sdkProcessingMetadata:c,breadcrumbs:l,fingerprint:u,eventProcessors:d,attachments:f,propagationContext:p,transactionName:ee,span:te}=t;K(e,`extra`,n),K(e,`tags`,r),K(e,`attributes`,i),K(e,`user`,a),K(e,`contexts`,o),e.sdkProcessingMetadata=P(e.sdkProcessingMetadata,c,2),s&&(e.level=s),ee&&(e.transactionName=ee),te&&(e.span=te),l.length&&(e.breadcrumbs=[...e.breadcrumbs,...l]),u.length&&(e.fingerprint=[...e.fingerprint,...u]),d.length&&(e.eventProcessors=[...e.eventProcessors,...d]),f.length&&(e.attachments=[...e.attachments,...f]),e.propagationContext={...e.propagationContext,...p}}function K(e,t,n){e[t]=P(e[t],n,1)}function sr(e,t){let n=jt().getScopeData();return e&&or(n,e.getScopeData()),t&&or(n,t.getScopeData()),n}function cr(e,t){let{extra:n,tags:r,user:i,contexts:a,level:o,transactionName:s}=t;Object.keys(n).length&&(e.extra={...n,...e.extra}),Object.keys(r).length&&(e.tags={...r,...e.tags}),Object.keys(i).length&&(e.user={...i,...e.user}),Object.keys(a).length&&(e.contexts={...a,...e.contexts}),o&&(e.level=o),s&&e.type!==`transaction`&&(e.transaction=s)}function lr(e,t){let n=[...e.breadcrumbs||[],...t];e.breadcrumbs=n.length?n:void 0}function ur(e,t){e.sdkProcessingMetadata={...e.sdkProcessingMetadata,...t}}function dr(e,t){e.contexts={trace:an(t),...e.contexts},e.sdkProcessingMetadata={dynamicSamplingContext:En(t),...e.sdkProcessingMetadata};let n=ln(hn(t)).description;n&&!e.transaction&&e.type===`transaction`&&(e.transaction=n)}function fr(e,t){e.fingerprint=e.fingerprint?Array.isArray(e.fingerprint)?e.fingerprint:[e.fingerprint]:[],t&&(e.fingerprint=e.fingerprint.concat(t)),e.fingerprint.length||delete e.fingerprint}function pr(e,t,n,r,i,a){let{normalizeDepth:o=3,normalizeMaxBreadth:s=1e3}=e,c={...t,event_id:t.event_id||n.event_id||O(),timestamp:t.timestamp||j()},l=n.integrations||e.integrations.map(e=>e.name);mr(c,e),_r(c,l),i&&i.emit(`applyFrameMetadata`,t),t.type===void 0&&hr(c,e.stackParser);let u=yr(r,n.captureContext);n.mechanism&&A(c,n.mechanism);let d=i?i.getEventProcessors():[],f=sr(a,u),p=[...n.attachments||[],...f.attachments];p.length&&(n.attachments=p),ar(c,f);let ee=[...d,...f.eventProcessors];return(n.data&&n.data.__sentry__===!0?U(c):er(ee,c,n)).then(e=>(e&&gr(e),typeof o==`number`&&o>0?vr(e,o,s):e))}function mr(e,t){let{environment:n,release:r,dist:i,maxValueLength:a}=t;e.environment=e.environment||n||`production`,!e.release&&r&&(e.release=r),!e.dist&&i&&(e.dist=i);let o=e.request;o?.url&&a&&(o.url=Xe(o.url,a)),a&&e.exception?.values?.forEach(e=>{e.value&&=Xe(e.value,a)})}function hr(e,t){let n=ir(t);e.exception?.values?.forEach(e=>{e.stacktrace?.frames?.forEach(e=>{e.filename&&(e.debug_id=n[e.filename])})})}function gr(e){let t={};if(e.exception?.values?.forEach(e=>{e.stacktrace?.frames?.forEach(e=>{e.debug_id&&(e.abs_path?t[e.abs_path]=e.debug_id:e.filename&&(t[e.filename]=e.debug_id),delete e.debug_id)})}),Object.keys(t).length===0)return;e.debug_meta=e.debug_meta||{},e.debug_meta.images=e.debug_meta.images||[];let n=e.debug_meta.images;Object.entries(t).forEach(([e,t])=>{n.push({type:`sourcemap`,code_file:e,debug_id:t})})}function _r(e,t){t.length>0&&(e.sdk=e.sdk||{},e.sdk.integrations=[...e.sdk.integrations||[],...t])}function vr(e,t,n){if(!e)return null;let r={...e,...e.breadcrumbs&&{breadcrumbs:e.breadcrumbs.map(e=>({...e,...e.data&&{data:V(e.data,t,n)}}))},...e.user&&{user:V(e.user,t,n)},...e.contexts&&{contexts:V(e.contexts,t,n)},...e.extra&&{extra:V(e.extra,t,n)}};return e.contexts?.trace&&r.contexts&&(r.contexts.trace=e.contexts.trace,e.contexts.trace.data&&(r.contexts.trace.data=V(e.contexts.trace.data,t,n))),e.spans&&(r.spans=e.spans.map(e=>({...e,...e.data&&{data:V(e.data,t,n)}}))),e.contexts?.flags&&r.contexts&&(r.contexts.flags=V(e.contexts.flags,3,n)),r}function yr(e,t){if(!t)return e;let n=e?e.clone():new F;return n.update(t),n}function br(e){if(e)return xr(e)||Cr(e)?{captureContext:e}:e}function xr(e){return e instanceof F||typeof e==`function`}var Sr=[`user`,`level`,`extra`,`contexts`,`tags`,`fingerprint`,`propagationContext`];function Cr(e){return Object.keys(e).some(e=>Sr.includes(e))}function wr(e,t){return L().captureException(e,br(t))}function Tr(e,t){return L().captureEvent(e,t)}function Er(e){let t=R(),{user:r}=sr(t,L()),{userAgent:i}=n.navigator||{},a=ut({user:r,...i&&{userAgent:i},...e}),o=t.getSession();return o?.status===`ok`&&N(o,{status:`exited`}),Dr(),t.setSession(a),a}function Dr(){let e=R(),t=L().getSession()||e.getSession();t&&dt(t),Or(),e.setSession()}function Or(){let e=R(),t=z(),n=e.getSession();n&&t&&t.captureSession(n)}function kr(e=!1){if(e){Dr();return}Or()}var Ar=`7`;function jr(e){let t=e.protocol?`${e.protocol}:`:``,n=e.port?`:${e.port}`:``;return`${t}//${e.host}${n}${e.path?`/${e.path}`:``}/api/`}function Mr(e){return`${jr(e)}${e.projectId}/envelope/`}function Nr(e,t){let n={sentry_version:Ar};return e.publicKey&&(n.sentry_key=e.publicKey),t&&(n.sentry_client=`${t.name}/${t.version}`),new URLSearchParams(n).toString()}function Pr(e,t,n){return t||`${Mr(e)}?${Nr(e,n)}`}var Fr=[];function Ir(e){let t={};return e.forEach(e=>{let{name:n}=e,r=t[n];r&&!r.isDefaultInstance&&e.isDefaultInstance||(t[n]=e)}),Object.values(t)}function Lr(e){let t=e.defaultIntegrations||[],n=e.integrations;t.forEach(e=>{e.isDefaultInstance=!0});let r;if(Array.isArray(n))r=[...t,...n];else if(typeof n==`function`){let e=n(t);r=Array.isArray(e)?e:[e]}else r=t;return Ir(r)}function Rr(e,t){let n={};return t.forEach(t=>{t&&Br(e,t,n)}),n}function zr(e,t){for(let n of t)n?.afterAllSetup&&n.afterAllSetup(e)}function Br(e,n,r){if(r[n.name]){t&&m.log(`Integration skipped because it was already installed: ${n.name}`);return}if(r[n.name]=n,!Fr.includes(n.name)&&typeof n.setupOnce==`function`&&(n.setupOnce(),Fr.push(n.name)),n.setup&&typeof n.setup==`function`&&n.setup(e),typeof n.preprocessEvent==`function`){let t=n.preprocessEvent.bind(n);e.on(`preprocessEvent`,(n,r)=>t(n,r,e))}if(typeof n.processEvent==`function`){let t=n.processEvent.bind(n),r=Object.assign((n,r)=>t(n,r,e),{id:n.name});e.addEventProcessor(r)}t&&m.log(`Integration installed: ${n.name}`)}function q(e){return e}function Vr(e){return[{type:`log`,item_count:e.length,content_type:`application/vnd.sentry.items.log+json`},{items:e}]}function Hr(e,t,n,r){let i={};return t?.sdk&&(i.sdk={name:t.sdk.name,version:t.sdk.version}),n&&r&&(i.dsn=B(r)),H(i,[Vr(e)])}function Ur(e,t){let n=t??Wr(e)??[];if(n.length===0)return;let r=e.getOptions(),i=Hr(n,r._metadata,r.tunnel,e.getDsn());Gr().set(e,[]),e.emit(`flushLogs`),e.sendEnvelope(i)}function Wr(e){return Gr().get(e)}function Gr(){return o(`clientToLogBufferMap`,()=>new WeakMap)}function Kr(e){return[{type:`trace_metric`,item_count:e.length,content_type:`application/vnd.sentry.items.trace-metric+json`},{items:e}]}function qr(e,t,n,r){let i={};return t?.sdk&&(i.sdk={name:t.sdk.name,version:t.sdk.version}),n&&r&&(i.dsn=B(r)),H(i,[Kr(e)])}function Jr(e,t){let n=t??Yr(e)??[];if(n.length===0)return;let r=e.getOptions(),i=qr(n,r._metadata,r.tunnel,e.getDsn());Xr().set(e,[]),e.emit(`flushMetrics`),e.sendEnvelope(i)}function Yr(e){return Xr().get(e)}function Xr(){return o(`clientToMetricBufferMap`,()=>new WeakMap)}function Zr(e){return typeof e==`object`&&typeof e.unref==`function`&&e.unref(),e}var Qr=Symbol.for(`SentryBufferFullError`);function $r(e=100){let t=new Set;function n(){return t.size<e}function r(e){t.delete(e)}function i(e){if(!n())return Qn(Qr);let i=e();return t.add(i),i.then(()=>r(i),()=>r(i)),i}function a(e){if(!t.size)return U(!0);let n=Promise.allSettled(Array.from(t)).then(()=>!0);if(!e)return n;let r=[n,new Promise(t=>Zr(setTimeout(()=>t(!1),e)))];return Promise.race(r)}return{get $(){return Array.from(t)},add:i,drain:a}}var ei=60*1e3;function ti(e,t=Ye()){let n=parseInt(`${e}`,10);if(!isNaN(n))return n*1e3;let r=Date.parse(`${e}`);return isNaN(r)?ei:r-t}function ni(e,t){return e[t]||e.all||0}function ri(e,t,n=Ye()){return ni(e,t)>n}function ii(e,{statusCode:t,headers:n},r=Ye()){let i={...e},a=n?.[`x-sentry-rate-limits`],o=n?.[`retry-after`];if(a)for(let e of a.trim().split(`,`)){let[t,n,,,a]=e.split(`:`,5),o=parseInt(t,10),s=(isNaN(o)?60:o)*1e3;if(!n)i.all=r+s;else for(let e of n.split(`;`))e===`metric_bucket`?(!a||a.split(`;`).includes(`custom`))&&(i[e]=r+s):i[e]=r+s}else o?i.all=r+ti(o,r):t===429&&(i.all=r+60*1e3);return i}function ai(e,n,r=$r(e.bufferSize||64)){let i={},a=e=>r.drain(e);function o(a){let o=[];if(Fn(a,(t,n)=>{let r=Un(n);ri(i,r)?e.recordDroppedEvent(`ratelimit_backoff`,r):o.push(t)}),o.length===0)return Promise.resolve({});let s=H(a[0],o),c=n=>{if(In(s,[`client_report`])){t&&m.warn(`Dropping client report. Will not send outcomes (reason: ${n}).`);return}Fn(s,(t,r)=>{e.recordDroppedEvent(n,Un(r))})};return r.add(()=>n({body:Rn(s)}).then(e=>e.statusCode===413?(t&&m.error(`Sentry responded with status code 413. Envelope was discarded due to exceeding size limits.`),c(`send_error`),e):(t&&e.statusCode!==void 0&&(e.statusCode<200||e.statusCode>=300)&&m.warn(`Sentry responded with status code ${e.statusCode} to sent event.`),i=ii(i,e),e),e=>{throw c(`network_error`),t&&m.error(`Encountered error running transport request:`,e),e})).then(e=>e,e=>{if(e===Qr)return t&&m.error(`Skipped sending event because buffer is full.`),c(`queue_overflow`),Promise.resolve({});throw e})}return{send:o,flush:a}}function oi(e,t,n){let r=[{type:`client_report`},{timestamp:n||j(),discarded_events:e}];return H(t?{dsn:t}:{},[r])}function si(e){let t=[];e.message&&t.push(e.message);try{let n=e.exception.values[e.exception.values.length-1];n?.value&&(t.push(n.value),n.type&&t.push(`${n.type}: ${n.value}`))}catch{}return t}function ci(e){let{trace_id:t,parent_span_id:n,span_id:r,status:i,origin:a,data:o,op:s}=e.contexts?.trace??{};return{data:o??{},description:e.transaction,op:s,parent_span_id:n,span_id:r??``,start_timestamp:e.start_timestamp??0,status:i,timestamp:e.timestamp,trace_id:t??``,origin:a,profile_id:o?.[Lt],exclusive_time:o?.[Rt],measurements:e.measurements,is_segment:!0}}function li(e){return{type:`transaction`,timestamp:e.timestamp,start_timestamp:e.start_timestamp,transaction:e.description,contexts:{trace:{trace_id:e.trace_id,span_id:e.span_id,parent_span_id:e.parent_span_id,op:e.op,status:e.status,origin:e.origin,data:{...e.data,...e.profile_id&&{"sentry.profile_id":e.profile_id},...e.exclusive_time&&{"sentry.exclusive_time":e.exclusive_time}}}},measurements:e.measurements}}var ui=`Not capturing exception because it's already been captured.`,di=`Discarded session because of missing or non-string release`,fi=Symbol.for(`SentryInternalError`),pi=Symbol.for(`SentryDoNotSendEventError`),mi=5e3;function hi(e){return{message:e,[fi]:!0}}function gi(e){return{message:e,[pi]:!0}}function _i(e){return!!e&&typeof e==`object`&&fi in e}function vi(e){return!!e&&typeof e==`object`&&pi in e}function yi(e,t,n,r,i){let a=0,o,s=!1;e.on(n,()=>{a=0,clearTimeout(o),s=!1}),e.on(t,t=>{a+=r(t),a>=8e5?i(e):s||(s=!0,o=Zr(setTimeout(()=>{i(e)},mi)))}),e.on(`flush`,()=>{i(e)})}var bi=class{constructor(e){if(this._options=e,this._integrations={},this._numProcessing=0,this._outcomes={},this._hooks={},this._eventProcessors=[],this._promiseBuffer=$r(e.transportOptions?.bufferSize??64),e.dsn?this._dsn=tn(e.dsn):t&&m.warn(`No DSN provided, client will not send events.`),this._dsn){let t=Pr(this._dsn,e.tunnel,e._metadata?e._metadata.sdk:void 0);this._transport=e.transport({tunnel:this._options.tunnel,recordDroppedEvent:this.recordDroppedEvent.bind(this),...e.transportOptions,url:t})}this._options.enableLogs=this._options.enableLogs??this._options._experiments?.enableLogs,this._options.enableLogs&&yi(this,`afterCaptureLog`,`flushLogs`,Di,Ur),(this._options.enableMetrics??this._options._experiments?.enableMetrics??!0)&&yi(this,`afterCaptureMetric`,`flushMetrics`,Ei,Jr)}captureException(e,n,r){let i=O();if(at(e))return t&&m.log(ui),i;let a={event_id:i,...n};return this._process(()=>this.eventFromException(e,a).then(e=>this._captureEvent(e,a,r)).then(e=>e),`error`),a.event_id}captureMessage(e,t,n,r){let i={event_id:O(),...n},a=De(e)?e:String(e),o=Oe(e),s=o?this.eventFromMessage(a,t,i):this.eventFromException(e,i);return this._process(()=>s.then(e=>this._captureEvent(e,i,r)),o?`unknown`:`error`),i.event_id}captureEvent(e,n,r){let i=O();if(n?.originalException&&at(n.originalException))return t&&m.log(ui),i;let a={event_id:i,...n},o=e.sdkProcessingMetadata||{},s=o.capturedSpanScope,c=o.capturedSpanIsolationScope,l=xi(e.type);return this._process(()=>this._captureEvent(e,a,s||r,c),l),a.event_id}captureSession(e){this.sendSession(e),N(e,{init:!1})}getDsn(){return this._dsn}getOptions(){return this._options}getSdkMetadata(){return this._options._metadata}getTransport(){return this._transport}async flush(e){let t=this._transport;if(!t)return!0;this.emit(`flush`);let n=await this._isClientDoneProcessing(e),r=await t.flush(e);return n&&r}async close(e){Ur(this);let t=await this.flush(e);return this.getOptions().enabled=!1,this.emit(`close`),t}getEventProcessors(){return this._eventProcessors}addEventProcessor(e){this._eventProcessors.push(e)}init(){(this._isEnabled()||this._options.integrations.some(({name:e})=>e.startsWith(`Spotlight`)))&&this._setupIntegrations()}getIntegrationByName(e){return this._integrations[e]}addIntegration(e){let t=this._integrations[e.name];Br(this,e,this._integrations),t||zr(this,[e])}sendEvent(e,t={}){this.emit(`beforeSendEvent`,e,t);let n=Jn(e,this._dsn,this._options._metadata,this._options.tunnel);for(let e of t.attachments||[])n=Pn(n,Bn(e));this.sendEnvelope(n).then(t=>this.emit(`afterSendEvent`,e,t))}sendSession(e){let{release:n,environment:r=Sn}=this._options;if(`aggregates`in e){let i=e.attrs||{};if(!i.release&&!n){t&&m.warn(di);return}i.release=i.release||n,i.environment=i.environment||r,e.attrs=i}else{if(!e.release&&!n){t&&m.warn(di);return}e.release=e.release||n,e.environment=e.environment||r}this.emit(`beforeSendSession`,e);let i=qn(e,this._dsn,this._options._metadata,this._options.tunnel);this.sendEnvelope(i)}recordDroppedEvent(e,n,r=1){if(this._options.sendClientReports){let i=`${e}:${n}`;t&&m.log(`Recording outcome: "${i}"${r>1?` (${r} times)`:``}`),this._outcomes[i]=(this._outcomes[i]||0)+r}}on(e,t){let n=this._hooks[e]=this._hooks[e]||new Set,r=(...e)=>t(...e);return n.add(r),()=>{n.delete(r)}}emit(e,...t){let n=this._hooks[e];n&&n.forEach(e=>e(...t))}async sendEnvelope(e){if(this.emit(`beforeEnvelope`,e),this._isEnabled()&&this._transport)try{return await this._transport.send(e)}catch(e){return t&&m.error(`Error while sending envelope:`,e),{}}return t&&m.error(`Transport disabled`),{}}dispose(){}_setupIntegrations(){let{integrations:e}=this._options;this._integrations=Rr(this,e),zr(this,e)}_updateSessionFromEvent(e,t){let n=t.level===`fatal`,r=!1,i=t.exception?.values;if(i){r=!0,n=!1;for(let e of i)if(e.mechanism?.handled===!1){n=!0;break}}let a=e.status===`ok`;(a&&e.errors===0||a&&n)&&(N(e,{...n&&{status:`crashed`},errors:e.errors||Number(r||n)}),this.captureSession(e))}async _isClientDoneProcessing(e){let t=0;for(;!e||t<e;){if(await new Promise(e=>setTimeout(e,1)),!this._numProcessing)return!0;t++}return!1}_isEnabled(){return this.getOptions().enabled!==!1&&this._transport!==void 0}_prepareEvent(e,t,n,r){let i=this.getOptions(),a=Object.keys(this._integrations);return!t.integrations&&a?.length&&(t.integrations=a),this.emit(`preprocessEvent`,e,t),e.type||r.setLastEventId(e.event_id||t.event_id),pr(i,e,t,n,this,r).then(e=>e===null?e:(this.emit(`postprocessEvent`,e,t),e.contexts={trace:{...e.contexts?.trace,...Nt(n)},...e.contexts},e.sdkProcessingMetadata={dynamicSamplingContext:Tn(this,n),...e.sdkProcessingMetadata},e))}_captureEvent(e,n={},r=L(),i=R()){return t&&wi(e)&&m.log(`Captured error event \`${si(e)[0]||`<unknown>`}\``),this._processEvent(e,n,r,i).then(e=>e.event_id,e=>{t&&(vi(e)?m.log(e.message):_i(e)?m.warn(e.message):m.warn(e))})}_processEvent(e,t,n,r){let i=this.getOptions(),{sampleRate:a}=i,o=Ti(e),s=wi(e),c=`before send for type \`${e.type||`error`}\``,l=a===void 0?void 0:nn(a);if(s&&typeof l==`number`&&Je()>l)return this.recordDroppedEvent(`sample_rate`,`error`),Qn(gi(`Discarding event because it's not included in the random sample (sampling rate = ${a})`));let u=xi(e.type);return this._prepareEvent(e,t,n,r).then(e=>{if(e===null)throw this.recordDroppedEvent(`event_processor`,u),gi("An event processor returned `null`, will not send event.");return t.data?.__sentry__===!0?e:Si(Ci(this,i,e,t),c)}).then(i=>{if(i===null){if(this.recordDroppedEvent(`before_send`,u),o){let t=1+(e.spans||[]).length;this.recordDroppedEvent(`before_send`,`span`,t)}throw gi(`${c} returned \`null\`, will not send event.`)}let a=n.getSession()||r.getSession();if(s&&a&&this._updateSessionFromEvent(a,i),o){let e=(i.sdkProcessingMetadata?.spanCountBeforeProcessing||0)-(i.spans?i.spans.length:0);e>0&&this.recordDroppedEvent(`before_send`,`span`,e)}let l=i.transaction_info;return o&&l&&i.transaction!==e.transaction&&(i.transaction_info={...l,source:`custom`}),this.sendEvent(i,t),i}).then(null,e=>{throw vi(e)||_i(e)?e:(this.captureException(e,{mechanism:{handled:!1,type:`internal`},data:{__sentry__:!0},originalException:e}),hi(`Event processing pipeline threw an error, original event will not be sent. Details have been sent as a new event.\nReason: ${e}`))})}_process(e,t){this._numProcessing++,this._promiseBuffer.add(e).then(e=>(this._numProcessing--,e),e=>(this._numProcessing--,e===Qr&&this.recordDroppedEvent(`queue_overflow`,t),e))}_clearOutcomes(){let e=this._outcomes;return this._outcomes={},Object.entries(e).map(([e,t])=>{let[n,r]=e.split(`:`);return{reason:n,category:r,quantity:t}})}_flushOutcomes(){t&&m.log(`Flushing outcomes...`);let e=this._clearOutcomes();if(e.length===0){t&&m.log(`No outcomes to send`);return}if(!this._dsn){t&&m.log(`No dsn provided, will not send outcomes`);return}t&&m.log(`Sending outcomes:`,e);let n=oi(e,this._options.tunnel&&B(this._dsn));this.sendEnvelope(n)}};function xi(e){return e===`replay_event`?`replay`:e||`error`}function Si(e,t){let n=`${t} must return \`null\` or a valid event.`;if(C(e))return e.then(e=>{if(!S(e)&&e!==null)throw hi(n);return e},e=>{throw hi(`${t} rejected with ${e}`)});if(!S(e)&&e!==null)throw hi(n);return e}function Ci(e,t,n,r){let{beforeSend:i,beforeSendTransaction:a,beforeSendSpan:o,ignoreSpans:s}=t,c=n;if(wi(c)&&i)return i(c,r);if(Ti(c)){if(o||s){let t=ci(c);if(s?.length&&yn(t,s))return null;if(o){let e=o(t);e?c=P(n,li(e)):gn()}if(c.spans){let t=[],n=c.spans;for(let e of n){if(s?.length&&yn(e,s)){bn(n,e);continue}if(o){let n=o(e);n?t.push(n):(gn(),t.push(e))}else t.push(e)}let r=c.spans.length-t.length;r&&e.recordDroppedEvent(`before_send`,`span`,r),c.spans=t}}if(a){if(c.spans){let e=c.spans.length;c.sdkProcessingMetadata={...n.sdkProcessingMetadata,spanCountBeforeProcessing:e}}return a(c,r)}}return c}function wi(e){return e.type===void 0}function Ti(e){return e.type===`transaction`}function Ei(e){let t=0;return e.name&&(t+=e.name.length*2),t+=8,t+Oi(e.attributes)}function Di(e){let t=0;return e.message&&(t+=e.message.length*2),t+Oi(e.attributes)}function Oi(e){if(!e)return 0;let t=0;return Object.values(e).forEach(e=>{Array.isArray(e)?t+=e.length*ki(e[0]):Oe(e)?t+=ki(e):t+=100}),t}function ki(e){return typeof e==`string`?e.length*2:typeof e==`number`?8:typeof e==`boolean`?4:0}function Ai(e){return y(e)&&`__sentry_fetch_url_host__`in e&&typeof e.__sentry_fetch_url_host__==`string`}function ji(e){return Ai(e)?`${e.message} (${e.__sentry_fetch_url_host__})`:e.message}function Mi(e,n){n.debug===!0&&(t?m.enable():u(()=>{console.warn("[Sentry] Cannot initialize SDK with `debug` option using a non-debug bundle.")})),L().update(n.initialScope);let r=new e(n);return Ni(r),r.init(),r}function Ni(e){L().setClient(e)}function Pi(e){if(!e)return{};let t=e.match(/^(([^:/?#]+):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?$/);if(!t)return{};let n=t[6]||``,r=t[8]||``;return{host:t[4],path:t[5],protocol:t[2],search:n,hash:r,relative:t[5]+n+r}}function Fi(e,t=!0){if(e.startsWith(`data:`)){let n=e.match(/^data:([^;,]+)/),r=n?n[1]:`text/plain`,i=e.includes(`;base64,`),a=e.indexOf(`,`),o=``;if(t&&a!==-1){let t=e.slice(a+1);o=t.length>10?`${t.slice(0,10)}... [truncated]`:t}return`data:${r}${i?`,base64`:``}${o?`,${o}`:``}`}return e}function Ii(e){`aggregates`in e?e.attrs?.ip_address===void 0&&(e.attrs={...e.attrs,ip_address:`{{auto}}`}):e.ipAddress===void 0&&(e.ipAddress=`{{auto}}`)}function Li(e,t,n=[t],i=`npm`){let a=(e._metadata=e._metadata||{}).sdk=e._metadata.sdk||{};a.name||(a.name=`sentry.javascript.${t}`,a.packages=n.map(e=>({name:`${i}:@sentry/${e}`,version:r})),a.version=r)}var Ri=100;function J(e,t){let n=z(),r=R();if(!n)return;let{beforeBreadcrumb:i=null,maxBreadcrumbs:a=Ri}=n.getOptions();if(a<=0)return;let o={timestamp:j(),...e},s=i?u(()=>i(o,t)):o;s!==null&&(n.emit&&n.emit(`beforeAddBreadcrumb`,s,t),r.addBreadcrumb(s,a))}var zi,Bi=`FunctionToString`,Vi=new WeakMap,Hi=q((()=>({name:Bi,setupOnce(){zi=Function.prototype.toString;try{Function.prototype.toString=function(...e){let t=He(this),n=Vi.has(z())&&t!==void 0?t:this;return zi.apply(n,e)}}catch{}},setup(e){Vi.set(e,!0)}}))),Ui=[/^Script error\.?$/,/^Javascript error: Script error\.? on line 0$/,/^ResizeObserver loop completed with undelivered notifications.$/,/^Cannot redefine property: googletag$/,/^Can't find variable: gmo$/,/^undefined is not an object \(evaluating 'a\.[A-Z]'\)$/,/can't redefine non-configurable property "solana"/,/vv\(\)\.getRestrictions is not a function/,/Can't find variable: _AutofillCallbackHandler/,/Object Not Found Matching Id:\d+, MethodName:simulateEvent/,/^Java exception was raised during method invocation$/],Wi=`EventFilters`,Gi=q((e={})=>{let t;return{name:Wi,setup(n){t=qi(e,n.getOptions())},processEvent(n,r,i){return t||=qi(e,i.getOptions()),Ji(n,t)?null:n}}}),Ki=q(((e={})=>({...Gi(e),name:`InboundFilters`})));function qi(e={},t={}){return{allowUrls:[...e.allowUrls||[],...t.allowUrls||[]],denyUrls:[...e.denyUrls||[],...t.denyUrls||[]],ignoreErrors:[...e.ignoreErrors||[],...t.ignoreErrors||[],...e.disableErrorDefaults?[]:Ui],ignoreTransactions:[...e.ignoreTransactions||[],...t.ignoreTransactions||[]]}}function Ji(e,n){if(!e.type){if(Yi(e,n.ignoreErrors))return t&&m.warn(`Event dropped due to being matched by \`ignoreErrors\` option.\nEvent: ${k(e)}`),!0;if(ta(e))return t&&m.warn(`Event dropped due to not having an error message, error type or stacktrace.\nEvent: ${k(e)}`),!0;if(Zi(e,n.denyUrls))return t&&m.warn(`Event dropped due to being matched by \`denyUrls\` option.\nEvent: ${k(e)}.\nUrl: ${ea(e)}`),!0;if(!Qi(e,n.allowUrls))return t&&m.warn(`Event dropped due to not being matched by \`allowUrls\` option.\nEvent: ${k(e)}.\nUrl: ${ea(e)}`),!0}else if(e.type===`transaction`&&Xi(e,n.ignoreTransactions))return t&&m.warn(`Event dropped due to being matched by \`ignoreTransactions\` option.\nEvent: ${k(e)}`),!0;return!1}function Yi(e,t){return t?.length?si(e).some(e=>$e(e,t)):!1}function Xi(e,t){if(!t?.length)return!1;let n=e.transaction;return n?$e(n,t):!1}function Zi(e,t){if(!t?.length)return!1;let n=ea(e);return n?$e(n,t):!1}function Qi(e,t){if(!t?.length)return!0;let n=ea(e);return n?$e(n,t):!0}function $i(e=[]){for(let t=e.length-1;t>=0;t--){let n=e[t];if(n&&n.filename!==`<anonymous>`&&n.filename!==`[native code]`)return n.filename||null}return null}function ea(e){try{let t=[...e.exception?.values??[]].reverse().find(e=>e.mechanism?.parent_id===void 0&&e.stacktrace?.frames?.length)?.stacktrace?.frames;return t?$i(t):null}catch{return t&&m.error(`Cannot extract url for event ${k(e)}`),null}}function ta(e){return e.exception?.values?.length?!e.message&&!e.exception.values.some(e=>e.stacktrace||e.type&&e.type!==`Error`||e.value):!1}function na(e,t,n,r,i,a){if(!i.exception?.values||!a||!w(a.originalException,Error))return;let o=i.exception.values.length>0?i.exception.values[i.exception.values.length-1]:void 0;o&&(i.exception.values=ra(e,t,r,a.originalException,n,i.exception.values,o,0))}function ra(e,t,n,r,i,a,o,s){if(a.length>=n+1)return a;let c=[...a];if(w(r[i],Error)){aa(o,s,r);let a=e(t,r[i]),l=c.length;oa(a,i,l,s),c=ra(e,t,n,r[i],i,[a,...c],a,l)}return ia(r)&&r.errors.forEach((a,l)=>{if(w(a,Error)){aa(o,s,r);let u=e(t,a),d=c.length;oa(u,`errors[${l}]`,d,s),c=ra(e,t,n,a,i,[u,...c],u,d)}}),c}function ia(e){return Array.isArray(e.errors)}function aa(e,t,n){e.mechanism={handled:!0,type:`auto.core.linked_errors`,...ia(n)&&{is_exception_group:!0},...e.mechanism,exception_id:t}}function oa(e,t,n,r){e.mechanism={handled:!0,...e.mechanism,type:`chained`,source:t,exception_id:n,parent_id:r}}function sa(e){let t=`console`;g(t,e),_(t,ca)}function ca(){`console`in n&&s.forEach(function(e){e in n.console&&T(n.console,e,function(t){return l[e]=t,function(...t){v(`console`,{args:t,level:e}),l[e]?.apply(n.console,t)}})})}function la(e){return e===`warn`?`warning`:[`fatal`,`error`,`warning`,`log`,`info`,`debug`].includes(e)?e:`log`}var ua=`Dedupe`,da=q((()=>{let e;return{name:ua,processEvent(n){if(n.type)return n;try{if(fa(n,e))return t&&m.warn(`Event dropped due to being a duplicate of previously captured event.`),null}catch{}return e=n}}}));function fa(e,t){return t?!!(pa(e,t)||ma(e,t)):!1}function pa(e,t){let n=e.message,r=t.message;return!(!n&&!r||n&&!r||!n&&r||n!==r||!ga(e,t)||!ha(e,t))}function ma(e,t){let n=_a(t),r=_a(e);return!(!n||!r||n.type!==r.type||n.value!==r.value||!ga(e,t)||!ha(e,t))}function ha(e,t){let n=pe(e),r=pe(t);if(!n&&!r)return!0;if(n&&!r||!n&&r||(n=n,r=r,r.length!==n.length))return!1;for(let e=0;e<r.length;e++){let t=r[e],i=n[e];if(t.filename!==i.filename||t.lineno!==i.lineno||t.colno!==i.colno||t.function!==i.function)return!1}return!0}function ga(e,t){let n=e.fingerprint,r=t.fingerprint;if(!n&&!r)return!0;if(n&&!r||!n&&r)return!1;n=n,r=r;try{return n.join(``)===r.join(``)}catch{return!1}}function _a(e){return e.exception?.values?.[0]}var va=`ConversationId`,ya=q((()=>({name:va,setup(e){e.on(`spanStart`,e=>{let t=L().getScopeData(),n=R().getScopeData(),r=t.conversationId||n.conversationId;r&&e.setAttribute(zt,r)})}})));function ba(e){if(e!==void 0){if(e>=400&&e<500)return`warning`;if(e>=500)return`error`}}var Y=n;function xa(){return`history`in Y&&!!Y.history}function Sa(){if(!(`fetch`in Y))return!1;try{return new Headers,new Request(`data:,`),new Response,!0}catch{return!1}}function Ca(e){return e&&/^function\s+\w+\(\)\s+\{\s+\[native code\]\s+\}$/.test(e.toString())}function wa(){if(typeof EdgeRuntime==`string`)return!0;if(!Sa())return!1;if(Ca(Y.fetch))return!0;let e=!1,n=Y.document;if(n&&typeof n.createElement==`function`)try{let t=n.createElement(`iframe`);t.hidden=!0,n.head.appendChild(t),t.contentWindow?.fetch&&(e=Ca(t.contentWindow.fetch)),n.head.removeChild(t)}catch(e){t&&m.warn(`Could not create sandbox iframe for pure fetch check, bailing to window.fetch: `,e)}return e}function Ta(e,t){let n=`fetch`;g(n,e),_(n,()=>Ea(void 0,t))}function Ea(e,t=!1){t&&!wa()||T(n,`fetch`,function(t){return function(...r){let i=Error(),{method:a,url:o}=ka(r),s={args:r,fetchData:{method:a,url:o},startTimestamp:M()*1e3,virtualError:i,headers:Aa(r)};return e||v(`fetch`,{...s}),t.apply(n,r).then(async t=>(e?e(t):v(`fetch`,{...s,endTimestamp:M()*1e3,response:t}),t),e=>{v(`fetch`,{...s,endTimestamp:M()*1e3,error:e}),y(e)&&e.stack===void 0&&(e.stack=i.stack,E(e,`framesToPop`,1));let t=z()?.getOptions().enhanceFetchErrorMessages??`always`;if(t!==!1&&e instanceof TypeError&&(e.message===`Failed to fetch`||e.message===`Load failed`||e.message===`NetworkError when attempting to fetch resource.`))try{let n=new URL(s.fetchData.url).host;t===`always`?e.message=`${e.message} (${n})`:E(e,`__sentry_fetch_url_host__`,n)}catch{}throw e})}})}function Da(e,t){return!!e&&typeof e==`object`&&!!e[t]}function Oa(e){return typeof e==`string`?e:e?Da(e,`url`)?e.url:e.toString?e.toString():``:``}function ka(e){if(e.length===0)return{method:`GET`,url:``};if(e.length===2){let[t,n]=e;return{url:Oa(t),method:Da(n,`method`)?String(n.method).toUpperCase():Pe(t)&&Da(t,`method`)?String(t.method).toUpperCase():`GET`}}let t=e[0];return{url:Oa(t),method:Da(t,`method`)?String(t.method).toUpperCase():`GET`}}function Aa(e){let[t,n]=e;try{if(typeof n==`object`&&n&&`headers`in n&&n.headers)return new Headers(n.headers);if(Pe(t))return new Headers(t.headers)}catch{}}function ja(){return`npm`}var X=n,Ma=0;function Na(){return Ma>0}function Pa(){Ma++,setTimeout(()=>{Ma--})}function Z(e,t={}){function n(e){return typeof e==`function`}if(!n(e))return e;try{let t=e.__sentry_wrapped__;if(t)return typeof t==`function`?t:e;if(He(e))return e}catch{return e}let r=function(...n){try{let r=n.map(e=>Z(e,t));return e.apply(this,r)}catch(e){throw Pa(),Mt(r=>{r.addEventProcessor(e=>(t.mechanism&&(it(e,void 0,void 0),A(e,t.mechanism)),e.extra={...e.extra,arguments:n},e)),wr(e)}),e}};try{for(let t in e)Object.prototype.hasOwnProperty.call(e,t)&&(r[t]=e[t])}catch{}Ve(r,e),E(e,`__sentry_wrapped__`,r);try{Object.getOwnPropertyDescriptor(r,`name`).configurable&&Object.defineProperty(r,`name`,{get(){return e.name}})}catch{}return r}function Fa(){let e=ze(),{referrer:t}=X.document||{},{userAgent:n}=X.navigator||{};return{url:e,headers:{...t&&{Referer:t},...n&&{"User-Agent":n}}}}function Ia(e,t){let n=za(e,t),r={type:Wa(t),value:Ga(t)};return n.length&&(r.stacktrace={frames:n}),r.type===void 0&&r.value===``&&(r.value=`Unrecoverable error caught`),r}function La(e,t,n,r){let i=z()?.getOptions().normalizeDepth,a=Qa(t),o={__serialized__:Dn(t,i)};if(a)return{exception:{values:[Ia(e,a)]},extra:o};let s={exception:{values:[{type:ke(t)?t.constructor.name:r?`UnhandledRejection`:`Error`,value:Xa(t,{isUnhandledRejection:r})}]},extra:o};if(n){let t=za(e,n);t.length&&(s.exception.values[0].stacktrace={frames:t})}return s}function Ra(e,t){return{exception:{values:[Ia(e,t)]}}}function za(e,t){let n=t.stacktrace||t.stack||``,r=Va(t),i=Ha(t);try{return e(n,r,i)}catch{}return[]}var Ba=/Minified React error #\d+;/i;function Va(e){return e&&Ba.test(e.message)?1:0}function Ha(e){return typeof e.framesToPop==`number`?e.framesToPop:0}function Ua(e){return typeof WebAssembly<`u`&&WebAssembly.Exception!==void 0?e instanceof WebAssembly.Exception:!1}function Wa(e){let t=e?.name;return!t&&Ua(e)?e.message&&Array.isArray(e.message)&&e.message.length==2?e.message[0]:`WebAssembly.Exception`:t}function Ga(e){let t=e?.message;return Ua(e)?Array.isArray(e.message)&&e.message.length==2?e.message[1]:`wasm exception`:t?t.error&&typeof t.error.message==`string`?ji(t.error):ji(e):`No error message`}function Ka(e,t,n,r){let i=Ja(e,t,n?.syntheticException||void 0,r);return A(i),i.level=`error`,n?.event_id&&(i.event_id=n.event_id),U(i)}function qa(e,t,n=`info`,r,i){let a=Ya(e,t,r?.syntheticException||void 0,i);return a.level=n,r?.event_id&&(a.event_id=r.event_id),U(a)}function Ja(e,t,n,r,i){let a;if(we(t)&&t.error)return Ra(e,t.error);if(Te(t)||Ee(t)){let i=t;if(`stack`in t)a=Ra(e,t);else{let t=i.name||(Te(i)?`DOMError`:`DOMException`),o=i.message?`${t}: ${i.message}`:t;a=Ya(e,o,n,r),it(a,o)}return`code`in i&&(a.tags={...a.tags,"DOMException.code":`${i.code}`}),a}return y(t)?Ra(e,t):S(t)||ke(t)?(a=La(e,t,n,i),A(a,{synthetic:!0}),a):(a=Ya(e,t,n,r),it(a,`${t}`,void 0),A(a,{synthetic:!0}),a)}function Ya(e,t,n,r){let i={};if(r&&n){let r=za(e,n);r.length&&(i.exception={values:[{value:t,stacktrace:{frames:r}}]}),A(i,{synthetic:!0})}if(De(t)){let{__sentry_template_string__:e,__sentry_template_values__:n}=t;return i.logentry={message:e,params:n},i}return i.message=t,i}function Xa(e,{isUnhandledRejection:t}){let n=Ke(e),r=t?`promise rejection`:`exception`;return we(e)?`Event \`ErrorEvent\` captured as ${r} with message \`${e.message}\``:ke(e)?`Event \`${Za(e)}\` (type=${e.type}) captured as ${r}`:`Object captured as ${r} with keys: ${n}`}function Za(e){try{let t=Object.getPrototypeOf(e);return t?t.constructor.name:void 0}catch{}}function Qa(e){for(let t in e)if(Object.prototype.hasOwnProperty.call(e,t)){let n=e[t];if(n instanceof Error)return n}}var $a=class extends bi{constructor(e){let t=eo(e);Li(t,`browser`,[`browser`],X.SENTRY_SDK_SOURCE||ja()),t._metadata?.sdk&&(t._metadata.sdk.settings={infer_ip:t.sendDefaultPii?`auto`:`never`,...t._metadata.sdk.settings}),super(t);let{sendDefaultPii:n,sendClientReports:r,enableLogs:i,_experiments:a,enableMetrics:o}=this._options,s=o??a?.enableMetrics??!0;X.document&&(r||i||s)&&X.document.addEventListener(`visibilitychange`,()=>{X.document.visibilityState===`hidden`&&(r&&this._flushOutcomes(),i&&Ur(this),s&&Jr(this))}),n&&this.on(`beforeSendSession`,Ii)}eventFromException(e,t){return Ka(this._options.stackParser,e,t,this._options.attachStacktrace)}eventFromMessage(e,t=`info`,n){return qa(this._options.stackParser,e,t,n,this._options.attachStacktrace)}_prepareEvent(e,t,n,r){return e.platform=e.platform||`javascript`,super._prepareEvent(e,t,n,r)}};function eo(e){return{release:typeof __SENTRY_RELEASE__==`string`?__SENTRY_RELEASE__:X.SENTRY_RELEASE?.id,sendClientReports:!0,parentSpanIsAlwaysRootSpan:!0,...e}}var to=typeof __SENTRY_DEBUG__>`u`||__SENTRY_DEBUG__,Q=n,no=1e3,ro,io,ao;function oo(e){g(`dom`,e),_(`dom`,so)}function so(){if(!Q.document)return;let e=v.bind(null,`dom`),t=uo(e,!0);Q.document.addEventListener(`click`,t,!1),Q.document.addEventListener(`keypress`,t,!1),[`EventTarget`,`Node`].forEach(t=>{let n=Q[t]?.prototype;n?.hasOwnProperty?.(`addEventListener`)&&(T(n,`addEventListener`,function(t){return function(n,r,i){if(n===`click`||n==`keypress`)try{let r=this.__sentry_instrumentation_handlers__=this.__sentry_instrumentation_handlers__||{},a=r[n]=r[n]||{refCount:0};if(!a.handler){let r=uo(e);a.handler=r,t.call(this,n,r,i)}a.refCount++}catch{}return t.call(this,n,r,i)}}),T(n,`removeEventListener`,function(e){return function(t,n,r){if(t===`click`||t==`keypress`)try{let n=this.__sentry_instrumentation_handlers__||{},i=n[t];i&&(i.refCount--,i.refCount<=0&&(e.call(this,t,i.handler,r),i.handler=void 0,delete n[t]),Object.keys(n).length===0&&delete this.__sentry_instrumentation_handlers__)}catch{}return e.call(this,t,n,r)}}))})}function co(e){if(e.type!==io)return!1;try{if(!e.target||e.target._sentryId!==ao)return!1}catch{}return!0}function lo(e,t){return e===`keypress`?t?.tagName?!(t.tagName===`INPUT`||t.tagName===`TEXTAREA`||t.isContentEditable):!0:!1}function uo(e,t=!1){return n=>{if(!n||n._sentryCaptured)return;let r=fo(n);if(lo(n.type,r))return;E(n,`_sentryCaptured`,!0),r&&!r._sentryId&&E(r,`_sentryId`,O());let i=n.type===`keypress`?`input`:n.type;co(n)||(e({event:n,name:i,global:t}),io=n.type,ao=r?r._sentryId:void 0),clearTimeout(ro),ro=Q.setTimeout(()=>{ao=void 0,io=void 0},no)}}function fo(e){try{return e.target}catch{return null}}var po;function mo(e){let t=`history`;g(t,e),_(t,ho)}function ho(){if(Q.addEventListener(`popstate`,()=>{let e=Q.location.href,t=po;po=e,t!==e&&v(`history`,{from:t,to:e})}),!xa())return;function e(e){return function(...t){let n=t.length>2?t[2]:void 0;if(n){let r=po,i=go(String(n));if(po=i,r===i)return e.apply(this,t);v(`history`,{from:r,to:i})}return e.apply(this,t)}}T(Q.history,`pushState`,e),T(Q.history,`replaceState`,e)}function go(e){try{return new URL(e,Q.location.origin).toString()}catch{return e}}var _o={};function vo(e){let t=_o[e];if(t)return t;let n=Q[e];if(Ca(n))return _o[e]=n.bind(Q);let r=Q.document;if(r&&typeof r.createElement==`function`)try{let t=r.createElement(`iframe`);t.hidden=!0,r.head.appendChild(t);let i=t.contentWindow;i?.[e]&&(n=i[e]),r.head.removeChild(t)}catch(t){to&&m.warn(`Could not create sandbox iframe for ${e} check, bailing to window.${e}: `,t)}return n&&(_o[e]=n.bind(Q))}function yo(e){_o[e]=void 0}var $=`__sentry_xhr_v3__`;function bo(e){g(`xhr`,e),_(`xhr`,xo)}function xo(){if(!Q.XMLHttpRequest)return;let e=XMLHttpRequest.prototype;e.open=new Proxy(e.open,{apply(e,t,n){let r=Error(),i=M()*1e3,a=x(n[0])?n[0].toUpperCase():void 0,o=So(n[1]);if(!a||!o)return e.apply(t,n);t[$]={method:a,url:o,request_headers:{}},a===`POST`&&o.match(/sentry_key/)&&(t.__sentry_own_request__=!0);let s=()=>{let e=t[$];if(e&&t.readyState===4){try{e.status_code=t.status}catch{}v(`xhr`,{endTimestamp:M()*1e3,startTimestamp:i,xhr:t,virtualError:r})}};return`onreadystatechange`in t&&typeof t.onreadystatechange==`function`?t.onreadystatechange=new Proxy(t.onreadystatechange,{apply(e,t,n){return s(),e.apply(t,n)}}):t.addEventListener(`readystatechange`,s),t.setRequestHeader=new Proxy(t.setRequestHeader,{apply(e,t,n){let[r,i]=n,a=t[$];return a&&x(r)&&x(i)&&(a.request_headers[r.toLowerCase()]=i),e.apply(t,n)}}),e.apply(t,n)}}),e.send=new Proxy(e.send,{apply(e,t,n){let r=t[$];return r?(n[0]!==void 0&&(r.body=n[0]),v(`xhr`,{startTimestamp:M()*1e3,xhr:t}),e.apply(t,n)):e.apply(t,n)}})}function So(e){if(x(e))return e;try{return e.toString()}catch{}}var Co=40;function wo(e,t=vo(`fetch`)){let n=0,r=0;async function i(i){let a=i.body.length;n+=a,r++;let o={body:i.body,method:`POST`,referrerPolicy:`strict-origin`,headers:e.headers,keepalive:n<=6e4&&r<15,...e.fetchOptions};try{let n=await t(e.url,o);return{statusCode:n.status,headers:{"x-sentry-rate-limits":n.headers.get(`X-Sentry-Rate-Limits`),"retry-after":n.headers.get(`Retry-After`)}}}catch(e){throw yo(`fetch`),e}finally{n-=a,r--}}return ai(e,i,$r(e.bufferSize||Co))}var To=typeof __SENTRY_DEBUG__>`u`||__SENTRY_DEBUG__,Eo=30,Do=50;function Oo(e,t,n,r){let i={filename:e,function:t===`<anonymous>`?`?`:t,in_app:!0};return n!==void 0&&(i.lineno=n),r!==void 0&&(i.colno=r),i}var ko=/^\s*at (\S+?)(?::(\d+))(?::(\d+))\s*$/i,Ao=/^\s*at (?:(.+?\)(?: \[.+\])?|.*?) ?\((?:address at )?)?(?:async )?((?:<anonymous>|[-a-z]+:|.*bundle|\/)?.*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,jo=/\((\S*)(?::(\d+))(?::(\d+))\)/,Mo=/at (.+?) ?\(data:(.+?),/,No=[Eo,e=>{let t=e.match(Mo);if(t)return{filename:`<data:${t[2]}>`,function:t[1]};let n=ko.exec(e);if(n){let[,e,t,r]=n;return Oo(e,`?`,+t,+r)}let r=Ao.exec(e);if(r){if(r[2]?.indexOf(`eval`)===0){let e=jo.exec(r[2]);e&&(r[2]=e[1],r[3]=e[2],r[4]=e[3])}let[e,t]=Lo(r[1]||`?`,r[2]);return Oo(t,e,r[3]?+r[3]:void 0,r[4]?+r[4]:void 0)}}],Po=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:[-a-z]+)?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,Fo=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,Io=ce(No,[Do,e=>{let t=Po.exec(e);if(t){if(t[3]&&t[3].indexOf(` > eval`)>-1){let e=Fo.exec(t[3]);e&&(t[1]=t[1]||`eval`,t[3]=e[1],t[4]=e[2],t[5]=``)}let e=t[3],n=t[1]||`?`;return[n,e]=Lo(n,e),Oo(e,n,t[4]?+t[4]:void 0,t[5]?+t[5]:void 0)}}]),Lo=(e,t)=>{let n=e.indexOf(`safari-extension`)!==-1,r=e.indexOf(`safari-web-extension`)!==-1;return n||r?[e.indexOf(`@`)===-1?`?`:e.split(`@`)[0],n?`safari-extension:${t}`:`safari-web-extension:${t}`]:[e,t]},Ro=1024,zo=`Breadcrumbs`,Bo=q(((e={})=>{let t={console:!0,dom:!0,fetch:!0,history:!0,sentry:!0,xhr:!0,...e};return{name:zo,setup(e){t.console&&sa(Uo(e)),t.dom&&oo(Ho(e,t.dom)),t.xhr&&bo(Wo(e)),t.fetch&&Ta(Go(e)),t.history&&mo(Ko(e)),t.sentry&&e.on(`beforeSendEvent`,Vo(e))}}}));function Vo(e){return function(t){z()===e&&J({category:`sentry.${t.type===`transaction`?`transaction`:`event`}`,event_id:t.event_id,level:t.level,message:k(t)},{event:t})}}function Ho(e,t){return function(n){if(z()!==e)return;let r,i,a=typeof t==`object`?t.serializeAttribute:void 0,o=typeof t==`object`&&typeof t.maxStringLength==`number`?t.maxStringLength:void 0;o&&o>Ro&&(To&&m.warn(`\`dom.maxStringLength\` cannot exceed ${Ro}, but a value of ${o} was configured. Sentry will use ${Ro} instead.`),o=Ro),typeof a==`string`&&(a=[a]);try{let e=n.event,t=qo(e)?e.target:e;r=Le(t,{keyAttrs:a,maxStringLength:o}),i=Be(t)}catch{r=`<unknown>`}if(r.length===0)return;let s={category:`ui.${n.name}`,message:r};i&&(s.data={"ui.component_name":i}),J(s,{event:n.event,name:n.name,global:n.global})}}function Uo(e){return function(t){if(z()!==e)return;let n={category:`console`,data:{arguments:t.args,logger:`console`},level:la(t.level),message:Ze(t.args,` `)};if(t.level===`assert`)if(t.args[0]===!1)n.message=`Assertion failed: ${Ze(t.args.slice(1),` `)||`console.assert`}`,n.data.arguments=t.args.slice(1);else return;J(n,{input:t.args,level:t.level})}}function Wo(e){return function(t){if(z()!==e)return;let{startTimestamp:n,endTimestamp:r}=t,i=t.xhr[$];if(!n||!r||!i)return;let{method:a,url:o,status_code:s,body:c}=i,l={method:a,url:o,status_code:s},u={xhr:t.xhr,input:c,startTimestamp:n,endTimestamp:r},d={category:`xhr`,data:l,type:`http`,level:ba(s)};e.emit(`beforeOutgoingRequestBreadcrumb`,d,u),J(d,u)}}function Go(e){return function(t){if(z()!==e)return;let{startTimestamp:n,endTimestamp:r}=t;if(r&&!(t.fetchData.url.match(/sentry_key/)&&t.fetchData.method===`POST`))if(t.fetchData.method,t.fetchData.url,t.error){let i=t.fetchData,a={data:t.error,input:t.args,startTimestamp:n,endTimestamp:r},o={category:`fetch`,data:i,level:`error`,type:`http`};e.emit(`beforeOutgoingRequestBreadcrumb`,o,a),J(o,a)}else{let i=t.response,a={...t.fetchData,status_code:i?.status};t.fetchData.request_body_size,t.fetchData.response_body_size,i?.status;let o={input:t.args,response:i,startTimestamp:n,endTimestamp:r},s={category:`fetch`,data:a,type:`http`,level:ba(a.status_code)};e.emit(`beforeOutgoingRequestBreadcrumb`,s,o),J(s,o)}}}function Ko(e){return function(t){if(z()!==e)return;let n=t.from,r=t.to,i=Pi(X.location.href),a=n?Pi(n):void 0,o=Pi(r);a?.path||(a=i),i.protocol===o.protocol&&i.host===o.host&&(r=o.relative),i.protocol===a.protocol&&i.host===a.host&&(n=a.relative),J({category:`navigation`,data:{from:n,to:r}})}}function qo(e){return!!e&&!!e.target}var Jo=`EventTarget.Window.Node.ApplicationCache.AudioTrackList.BroadcastChannel.ChannelMergerNode.CryptoOperation.EventSource.FileReader.HTMLUnknownElement.IDBDatabase.IDBRequest.IDBTransaction.KeyOperation.MediaController.MessagePort.ModalWindow.Notification.SVGElementInstance.Screen.SharedWorker.TextTrack.TextTrackCue.TextTrackList.WebSocket.WebSocketWorker.Worker.XMLHttpRequest.XMLHttpRequestEventTarget.XMLHttpRequestUpload`.split(`.`),Yo=`BrowserApiErrors`,Xo=q(((e={})=>{let t={XMLHttpRequest:!0,eventTarget:!0,requestAnimationFrame:!0,setInterval:!0,setTimeout:!0,unregisterOriginalCallbacks:!1,...e};return{name:Yo,setupOnce(){t.setTimeout&&T(X,`setTimeout`,Zo),t.setInterval&&T(X,`setInterval`,Zo),t.requestAnimationFrame&&T(X,`requestAnimationFrame`,Qo),t.XMLHttpRequest&&`XMLHttpRequest`in X&&T(XMLHttpRequest.prototype,`send`,$o);let e=t.eventTarget;e&&(Array.isArray(e)?e:Jo).forEach(e=>es(e,t))}}}));function Zo(e){return function(...t){let n=t[0];return t[0]=Z(n,{mechanism:{handled:!1,type:`auto.browser.browserapierrors.${h(e)}`}}),e.apply(this,t)}}function Qo(e){return function(t){return e.apply(this,[Z(t,{mechanism:{data:{handler:h(e)},handled:!1,type:`auto.browser.browserapierrors.requestAnimationFrame`}})])}}function $o(e){return function(...t){let n=this;return[`onload`,`onerror`,`onprogress`,`onreadystatechange`].forEach(e=>{e in n&&typeof n[e]==`function`&&T(n,e,function(t){let n={mechanism:{data:{handler:h(t)},handled:!1,type:`auto.browser.browserapierrors.xhr.${e}`}},r=He(t);return r&&(n.mechanism.data.handler=h(r)),Z(t,n)})}),e.apply(this,t)}}function es(e,t){let n=X[e]?.prototype;n?.hasOwnProperty?.(`addEventListener`)&&(T(n,`addEventListener`,function(n){return function(r,i,a){try{ts(i)&&(i.handleEvent=Z(i.handleEvent,{mechanism:{data:{handler:h(i),target:e},handled:!1,type:`auto.browser.browserapierrors.handleEvent`}}))}catch{}return t.unregisterOriginalCallbacks&&ns(this,r,i),n.apply(this,[r,Z(i,{mechanism:{data:{handler:h(i),target:e},handled:!1,type:`auto.browser.browserapierrors.addEventListener`}}),a])}}),T(n,`removeEventListener`,function(e){return function(t,n,r){try{let i=n.__sentry_wrapped__;i&&e.call(this,t,i,r)}catch{}return e.call(this,t,n,r)}}))}function ts(e){return typeof e.handleEvent==`function`}function ns(e,t,n){e&&typeof e==`object`&&`removeEventListener`in e&&typeof e.removeEventListener==`function`&&e.removeEventListener(t,n)}var rs=q((e={})=>{let t=e.lifecycle??`route`;return{name:`BrowserSession`,setupOnce(){if(X.document===void 0){To&&m.warn("Using the `browserSessionIntegration` in non-browser environments is not supported.");return}Er({ignoreDuration:!0}),kr();let e=R(),n=e.getUser();e.addScopeListener(e=>{let t=e.getUser();(n?.id!==t?.id||n?.ip_address!==t?.ip_address)&&(kr(),n=t)}),t===`route`&&mo(({from:e,to:t})=>{e!==t&&(Er({ignoreDuration:!0}),kr())})}}}),is=`CultureContext`,as=q((()=>({name:is,preprocessEvent(e){let t=os();t&&(e.contexts={...e.contexts,culture:{...t,...e.contexts?.culture}})}})));function os(){try{let e=X.Intl;if(!e)return;let t=e.DateTimeFormat().resolvedOptions();return{locale:t.locale,timezone:t.timeZone,calendar:t.calendar}}catch{return}}var ss=`GlobalHandlers`,cs=q(((e={})=>{let t={onerror:!0,onunhandledrejection:!0,...e};return{name:ss,setupOnce(){Error.stackTraceLimit=50},setup(e){t.onerror&&(ls(e),ms(`onerror`)),t.onunhandledrejection&&(us(e),ms(`onunhandledrejection`))}}}));function ls(e){ve(t=>{let{stackParser:n,attachStacktrace:r}=hs();if(z()!==e||Na())return;let{msg:i,url:a,line:o,column:s,error:c}=t,l=ps(Ja(n,c||i,void 0,r,!1),a,o,s);l.level=`error`,Tr(l,{originalException:c,mechanism:{handled:!1,type:`auto.browser.global_handlers.onerror`}})})}function us(e){xe(t=>{let{stackParser:n,attachStacktrace:r}=hs();if(z()!==e||Na())return;let i=ds(t),a=Oe(i)?fs(i):Ja(n,i,void 0,r,!0);a.level=`error`,Tr(a,{originalException:i,mechanism:{handled:!1,type:`auto.browser.global_handlers.onunhandledrejection`}})})}function ds(e){if(Oe(e))return e;try{if(`reason`in e)return e.reason;if(`detail`in e&&`reason`in e.detail)return e.detail.reason}catch{}return e}function fs(e){return{exception:{values:[{type:`UnhandledRejection`,value:`Non-Error promise rejection captured with value: ${String(e)}`}]}}}function ps(e,t,n,r){let i=e.exception=e.exception||{},a=i.values=i.values||[],o=a[0]=a[0]||{},s=o.stacktrace=o.stacktrace||{},c=s.frames=s.frames||[],l=r,u=n,d=gs(t)??ze();return c.length===0&&c.push({colno:l,filename:d,function:`?`,in_app:!0,lineno:u}),e}function ms(e){To&&m.log(`Global Handler attached: ${e}`)}function hs(){return z()?.getOptions()||{stackParser:()=>[],attachStacktrace:!1}}function gs(e){if(!(!x(e)||e.length===0))return e.startsWith(`data:`)?`<${Fi(e,!1)}>`:e}var _s=q(()=>({name:`HttpContext`,preprocessEvent(e){if(!X.navigator&&!X.location&&!X.document)return;let t=Fa(),n={...t.headers,...e.request?.headers};e.request={...t,...e.request,headers:n}}})),vs=`cause`,ys=5,bs=`LinkedErrors`,xs=q(((e={})=>{let t=e.limit||ys,n=e.key||vs;return{name:bs,preprocessEvent(e,r,i){na(Ia,i.getOptions().stackParser,n,t,e,r)}}}));function Ss(){return Cs()?(To&&u(()=>{console.error(`[Sentry] You cannot use Sentry.init() in a browser extension, see: https://docs.sentry.io/platforms/javascript/best-practices/browser-extensions/`)}),!0):!1}function Cs(){if(X.window===void 0)return!1;let e=X;if(e.nw||!(e.chrome||e.browser)?.runtime?.id)return!1;let t=ze();return!(X===X.top&&[`chrome-extension`,`moz-extension`,`ms-browser-extension`,`safari-web-extension`].some(e=>t.startsWith(`${e}://`)))}function ws(e){return[Ki(),Hi(),ya(),Xo(),Bo(),cs(),xs(),da(),_s(),as(),rs()]}function Ts(e={}){let t=!e.skipBrowserExtensionCheck&&Ss(),n=e.defaultIntegrations==null?ws():e.defaultIntegrations;return Mi($a,{...e,enabled:t?!1:e.enabled,stackParser:le(e.stackParser||Io),integrations:Lr({integrations:e.integrations,defaultIntegrations:n}),transport:e.transport||wo})}var Es=e(((e,t)=>{t.exports={}}));function Ds(e,t,n,r){if(!(e instanceof Error))throw e;if(!(typeof window>`u`&&t||r))throw e.message+=` on line `+n,e;var i,a,o,s;try{r||=Es().readFileSync(t,{encoding:`utf8`}),i=3,a=r.split(`
|
|
3
|
-
`),o=Math.max(n-i,0),s=Math.min(a.length,n+i)}catch(r){e.message+=` - could not read from `+t+` (`+r.message+`)`,Ds(e,null,n);return}i=a.slice(o,s).map(function(e,t){var r=t+o+1;return(r==n?` > `:` `)+r+`| `+e}).join(`
|
|
4
|
-
`),e.path=t;try{e.message=(t||`Pug`)+`:`+n+`
|
|
5
|
-
`+i+`
|
|
6
|
-
|
|
7
|
-
`+e.message}catch{}throw e}function Os(e){var t=``,n,r;try{r=1,n=`/home/circleci/project/girder/plugins/sentry/girder_sentry/web_client/templates/configView.pug`,t+=`<div class="g-config-breadcrumb-container"></div>`,r=2,n=`/home/circleci/project/girder/plugins/sentry/girder_sentry/web_client/templates/configView.pug`,t+=`<p class="g-sentry-description">`,r=3,n=`/home/circleci/project/girder/plugins/sentry/girder_sentry/web_client/templates/configView.pug`,t+=`To track errors in Sentry, enter your Sentry project DSNs here.</p>`,r=4,n=`/home/circleci/project/girder/plugins/sentry/girder_sentry/web_client/templates/configView.pug`,t+=`<form id="g-sentry-server-form" role="form">`,r=5,n=`/home/circleci/project/girder/plugins/sentry/girder_sentry/web_client/templates/configView.pug`,t+=`<div class="form-group">`,r=6,n=`/home/circleci/project/girder/plugins/sentry/girder_sentry/web_client/templates/configView.pug`,t+=`<label class="control-label" for="g-sentry-server-dsn">`,r=6,n=`/home/circleci/project/girder/plugins/sentry/girder_sentry/web_client/templates/configView.pug`,t+=`Sentry Server DSN</label>`,r=7,n=`/home/circleci/project/girder/plugins/sentry/girder_sentry/web_client/templates/configView.pug`,t+=`<input class="input-sm form-control" id="g-sentry-server-dsn" type="text" placeholder="Tracking ID"/></div>`,r=9,n=`/home/circleci/project/girder/plugins/sentry/girder_sentry/web_client/templates/configView.pug`,t+=`<p class="g-validation-failed-message" id="g-sentry-server-error-message"></p>`,r=10,n=`/home/circleci/project/girder/plugins/sentry/girder_sentry/web_client/templates/configView.pug`,t+=`<input class="btn btn-sm btn-primary" type="submit" value="Save"/></form>`,r=12,n=`/home/circleci/project/girder/plugins/sentry/girder_sentry/web_client/templates/configView.pug`,t+=`<form id="g-sentry-client-form" role="form">`,r=13,n=`/home/circleci/project/girder/plugins/sentry/girder_sentry/web_client/templates/configView.pug`,t+=`<div class="form-group">`,r=14,n=`/home/circleci/project/girder/plugins/sentry/girder_sentry/web_client/templates/configView.pug`,t+=`<label class="control-label" for="g-sentry-client-dsn">`,r=14,n=`/home/circleci/project/girder/plugins/sentry/girder_sentry/web_client/templates/configView.pug`,t+=`Sentry Client DSN</label>`,r=15,n=`/home/circleci/project/girder/plugins/sentry/girder_sentry/web_client/templates/configView.pug`,t+=`<input class="input-sm form-control" id="g-sentry-client-dsn" type="text" placeholder="Tracking ID"/></div>`,r=17,n=`/home/circleci/project/girder/plugins/sentry/girder_sentry/web_client/templates/configView.pug`,t+=`<p class="g-validation-failed-message" id="g-sentry-client-error-message"></p>`,r=18,n=`/home/circleci/project/girder/plugins/sentry/girder_sentry/web_client/templates/configView.pug`,t+=`<input class="btn btn-sm btn-primary" type="submit" value="Save"/></form>`}catch(e){Ds(e,n,r)}return t}var ks=girder.views.widgets.PluginConfigBreadcrumbWidget,As=girder.views.View,{restRequest:js}=girder.rest,Ms=girder.events,Ns=As.extend({events:{"submit #g-sentry-server-form":function(e){e.preventDefault(),this.$(`#g-sentry-server-error-message`).empty(),this._saveSettings([{key:`sentry.backend_dsn`,value:this.$(`#g-sentry-server-dsn`).val().trim()}],{errorTarget:`#g-sentry-server-error-message`})},"submit #g-sentry-client-form":function(e){e.preventDefault(),this.$(`#g-sentry-client-error-message`).empty(),this._saveSettings([{key:`sentry.frontend_dsn`,value:this.$(`#g-sentry-client-dsn`).val().trim()}],{errorTarget:`#g-sentry-client-error-message`})}},initialize:function(){js({method:`GET`,url:`system/setting`,data:{list:JSON.stringify([`sentry.backend_dsn`,`sentry.frontend_dsn`])}}).done(e=>{this.render(),this.$(`#g-sentry-server-dsn`).val(e[`sentry.backend_dsn`]),this.$(`#g-sentry-client-dsn`).val(e[`sentry.frontend_dsn`])})},render:function(){return this.$el.html(Os()),this.breadcrumb||=new ks({pluginName:`Sentry`,el:this.$(`.g-config-breadcrumb-container`),parentView:this}).render(),this},_saveSettings:function(e,t){js({method:`PUT`,url:`system/setting`,data:{list:JSON.stringify(e)},error:null}).done(()=>{Ms.trigger(`g:alert`,{icon:`ok`,text:`Settings saved.`,type:`success`,timeout:4e3})}).fail(e=>{this.$(t.errorTarget).text(e.responseJSON.message)})}}),Ps=girder.router,Fs=girder.events,{exposePluginConfig:Is}=girder.utilities.PluginUtils;Is(`sentry`,`plugins/sentry/config`),Ps.route(`plugins/sentry/config`,`SentryConfig`,function(){Fs.trigger(`g:navigateTo`,Ns)});var Ls=girder.events,{restRequest:Rs}=girder.rest;Ls.on(`g:appload.after`,function(){Rs({method:`GET`,url:`sentry/dsn`}).done(e=>{e.sentry_dsn&&Ts({dsn:e.sentry_dsn})})})});
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{girder_sentry-5.0.2.dev2 → girder_sentry-5.0.2.dev6}/girder_sentry/web_client/dist/style.css
RENAMED
|
File without changes
|
|
File without changes
|
{girder_sentry-5.0.2.dev2 → girder_sentry-5.0.2.dev6}/girder_sentry.egg-info/dependency_links.txt
RENAMED
|
File without changes
|
{girder_sentry-5.0.2.dev2 → girder_sentry-5.0.2.dev6}/girder_sentry.egg-info/entry_points.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|