Sentry不会在事件上提供操作系统

发布于 2025-02-12 16:25:22 字数 864 浏览 0 评论 0原文

我们正在使用Sentry在我们的Flutter应用程序上使用,这是很好的工具。

但这并未在此类事件上显示iOS操作系统:

我的初始化哨兵的方式就像这个

await SentryFlutter.init(
        (options) {
          options.dsn = SecretUtils.instance.get(key);
          options.environment = environment;
        },
        appRunner: appRunner,
      );

批准者只是运行我的申请。有什么方法可以在事件

编辑上获取iOS标签: ISSIU固定。更多信息 - > https://github.com/getsentry/sentry/sentry/sentry-dart/pull/pull/pull/958

We are using sentry on our flutter app which is quite good tool.

But it doesn't show iOS operating system on events like this:

Event on Sentry for iOS

But it shows on Android on the same event

Event on Sentry for Android

The way I am initializing sentry is like this

await SentryFlutter.init(
        (options) {
          options.dsn = SecretUtils.instance.get(key);
          options.environment = environment;
        },
        appRunner: appRunner,
      );

appRunner simply runs my application. Is there any way of getting iOS tag on events

Edit:
Issiu fixed. More info -> https://github.com/getsentry/sentry-dart/pull/958

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

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

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

拔了角的鹿 2025-02-19 16:25:22

看起来像是弹力弹力的SDK中的一个问题,我已经创建了一个问题: https:https:https:https:https: //github.com/getsentry/sentry-dart/issues/942

同时,解决方法可能正在设置操作系统在当前范围的上下文中手动: https://pub.dev/documentation/sentry/latest/sentry_io/contexts/operatingsystem.html

这样的事情可以起作用(不进行测试):

import 'dart:io' show Platform;

if (Platform.isIOS) {
  Sentry.configureScope((scope) => scope.setContexts('os', {
    'name': Platform.operatingSystem
  }));
}

Looks like an issue in the Sentry SDK for flutter, I've created an issue: https://github.com/getsentry/sentry-dart/issues/942

In the meantime, the workaround could be setting the operating system manually in the current scope's context: https://pub.dev/documentation/sentry/latest/sentry_io/Contexts/operatingSystem.html

Something like this could work (not tested):

import 'dart:io' show Platform;

if (Platform.isIOS) {
  Sentry.configureScope((scope) => scope.setContexts('os', {
    'name': Platform.operatingSystem
  }));
}
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文