Sentry报告了一个错误:无效令牌(HTTP状态:401) - Sentry NextJS

发布于 2025-01-23 01:32:15 字数 742 浏览 1 评论 0原文

在我的项目中集成哨兵之后,开发环境的工作正常,但是当我尝试使用YARN Build构建项目时,我会面临此错误。

sentry cli插件:命令失败:/users/ishman/desktop/sh/web-speedhome/node_modules/@sentry/cli/sentry-cli释放新的ruwbsquhmn7t-kxjdjebz 错误:API请求失败 引起的:Sentry报告了一个错误:无效令牌(HTTP状态:401)

add-log-level = [info | debug]或导出Sentry_log_level = [info | debug]查看更多输出。 请将完整的调试日志附加到所有错误报告。

我的配置文件

import * as Sentry from '@sentry/nextjs'
import { SENTRY_DSN } from './env'

Sentry.init({
  dsn: SENTRY_DSN,

  tracesSampleRate: 1,
  integrations: [new Sentry.BrowserTracing({})],

})

和我的哨兵

defaults.url=https://sentry.io/
defaults.org=org
defaults.project=project
auth.token=token

After integration sentry in my project the dev environment works fine but when I try to build the project with yarn build i face this error.

Sentry CLI Plugin: Command failed: /Users/ishman/Desktop/sh/web-speedhome/node_modules/@sentry/cli/sentry-cli releases new RUwbSqUhmn7T-kxjDJebz
error: API request failed
caused by: sentry reported an error: Invalid token (http status: 401)

Add --log-level=[info|debug] or export SENTRY_LOG_LEVEL=[info|debug] to see more output.
Please attach the full debug log to all bug reports.

My configuration file for sentry

import * as Sentry from '@sentry/nextjs'
import { SENTRY_DSN } from './env'

Sentry.init({
  dsn: SENTRY_DSN,

  tracesSampleRate: 1,
  integrations: [new Sentry.BrowserTracing({})],

})

And my sentry.properties file

defaults.url=https://sentry.io/
defaults.org=org
defaults.project=project
auth.token=token

cli.executable=../../../.npm/_npx/a8388072043b4cbc/node_modules/@sentry/cli/bin/sentry-cli

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文