{"id":49378216,"url":"https://github.com/tracewayapp/traceway-flutter","last_synced_at":"2026-05-04T03:05:59.169Z","repository":{"id":350326478,"uuid":"1206133717","full_name":"tracewayapp/traceway-flutter","owner":"tracewayapp","description":"Full session replays for your flutter app. Efficient recording across Android, iOS and web. Compatible with Traceway.","archived":false,"fork":false,"pushed_at":"2026-04-16T05:23:18.000Z","size":3974,"stargazers_count":8,"open_issues_count":1,"forks_count":1,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-04-28T03:42:02.516Z","etag":null,"topics":["flutter","observability","session-replay"],"latest_commit_sha":null,"homepage":"","language":"Dart","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/tracewayapp.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-04-09T15:57:46.000Z","updated_at":"2026-04-17T16:30:14.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/tracewayapp/traceway-flutter","commit_stats":null,"previous_names":["tracewayapp/traceway-flutter"],"tags_count":9,"template":false,"template_full_name":null,"purl":"pkg:github/tracewayapp/traceway-flutter","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tracewayapp%2Ftraceway-flutter","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tracewayapp%2Ftraceway-flutter/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tracewayapp%2Ftraceway-flutter/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tracewayapp%2Ftraceway-flutter/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tracewayapp","download_url":"https://codeload.github.com/tracewayapp/traceway-flutter/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tracewayapp%2Ftraceway-flutter/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32592721,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-03T22:12:39.696Z","status":"online","status_checked_at":"2026-05-04T02:00:06.625Z","response_time":58,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["flutter","observability","session-replay"],"created_at":"2026-04-28T03:41:29.323Z","updated_at":"2026-05-04T03:05:59.132Z","avatar_url":"https://github.com/tracewayapp.png","language":"Dart","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cp align=\"center\"\u003e\n  \u003cpicture\u003e\n    \u003csource media=\"(prefers-color-scheme: dark)\" srcset=\"https://raw.githubusercontent.com/tracewayapp/traceway/main/Traceway%20Logo%20White.png\" /\u003e\n    \u003csource media=\"(prefers-color-scheme: light)\" srcset=\"https://raw.githubusercontent.com/tracewayapp/traceway/main/Traceway%20Logo.png\" /\u003e\n    \u003cimg src=\"https://raw.githubusercontent.com/tracewayapp/traceway/main/Traceway%20Logo.png\" alt=\"Traceway\" width=\"200\" /\u003e\n  \u003c/picture\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"https://pub.dev/packages/traceway\"\u003e\u003cimg src=\"https://img.shields.io/pub/v/traceway.svg\" alt=\"pub.dev\"\u003e\u003c/a\u003e\n  \u003ca href=\"https://github.com/tracewayapp/traceway-flutter/blob/main/LICENSE\"\u003e\u003cimg src=\"https://img.shields.io/badge/license-MIT-blue.svg\" alt=\"License\"\u003e\u003c/a\u003e\n\u003c/p\u003e\n\n# Traceway Flutter SDK\n\nError tracking and screen recording for Flutter apps. Capture exceptions with full stack traces and the last 10 seconds of screen recording — automatically.\n\n[Traceway](https://tracewayapp.com) is a completely open-source error tracking platform. You can [self-host](https://docs.tracewayapp.com/server) it or use [Traceway Cloud](https://tracewayapp.com).\n\n## Features\n\n- Automatic capture of all Flutter errors (framework, platform, and async)\n- Full Dart stack traces\n- Screen recording — last ~10 seconds encoded as MP4 video\n- Touch/click positions rendered on recordings\n- Privacy masking — blur or blank sensitive UI regions in recordings\n- Disk persistence — pending exceptions survive app restarts\n- Gzip-compressed transport\n- Simple one-line setup\n\n## Installation\n\n```bash\nflutter pub add traceway\n```\n\n## Quick Start\n\nWrap your app with `Traceway.run()`:\n\n```dart\nimport 'package:flutter/material.dart';\nimport 'package:traceway/traceway.dart';\n\nvoid main() {\n  Traceway.run(\n    connectionString: 'your-token@https://your-traceway-instance.com/api/report',\n    options: TracewayOptions(\n      screenCapture: true,\n      version: '1.0.0',\n    ),\n    child: MyApp(),\n  );\n}\n```\n\nThat's it. All uncaught exceptions are captured automatically.\n\n## Manual Capture\n\n```dart\n// Capture a caught exception\ntry {\n  await riskyOperation();\n} catch (e, st) {\n  TracewayClient.instance?.captureException(e, st);\n}\n\n// Capture a message\nTracewayClient.instance?.captureMessage('User completed checkout');\n\n// Force send pending events\nawait TracewayClient.instance?.flush();\n```\n\n## Options\n\n| Option | Default | Description |\n|--------|---------|-------------|\n| `sampleRate` | `1.0` | Error sampling rate (0.0 - 1.0) |\n| `screenCapture` | `false` | Record last ~10 seconds of screen |\n| `debug` | `false` | Print debug info to console |\n| `version` | `''` | App version string |\n| `debounceMs` | `1500` | Milliseconds before sending batched events |\n| `retryDelayMs` | `10000` | Retry delay on failed uploads |\n| `capturePixelRatio` | `0.75` | Screenshot resolution scale factor |\n| `maxBufferFrames` | `150` | Max frames in recording buffer (~10s at 15fps) |\n| `fps` | `15` | Frames per second for screen capture (1–59) |\n| `maxPendingExceptions` | `5` | Max exceptions held in memory before oldest is dropped |\n| `persistToDisk` | `true` | Persist pending exceptions to disk so they survive app restarts |\n| `maxLocalFiles` | `5` | Max exception files stored on disk |\n| `localFileMaxAgeHours` | `12` | Hours after which unsynced local files are deleted |\n\n## Platform Setup\n\nTraceway needs network access to send error reports. Depending on the platform, you may need to add permissions manually.\n\n### Android\n\nAdd the `INTERNET` permission to `android/app/src/main/AndroidManifest.xml`:\n\n```xml\n\u003cmanifest xmlns:android=\"http://schemas.android.com/apk/res/android\"\u003e\n    \u003cuses-permission android:name=\"android.permission.INTERNET\"/\u003e\n    \u003capplication\n      ...\n```\n\n### macOS\n\nmacOS apps are sandboxed by default and cannot make network requests without the `com.apple.security.network.client` entitlement.\n\nAdd it to both `macos/Runner/DebugProfile.entitlements` and `macos/Runner/Release.entitlements`:\n\n```xml\n\u003cdict\u003e\n    \u003ckey\u003ecom.apple.security.app-sandbox\u003c/key\u003e\n    \u003ctrue/\u003e\n    \u003ckey\u003ecom.apple.security.network.client\u003c/key\u003e\n    \u003ctrue/\u003e\n\u003c/dict\u003e\n```\n\n### iOS\n\nNo additional configuration is required. iOS apps can make HTTPS requests by default.\n\n## Screen Recording\n\nWhen `screenCapture: true`, the SDK:\n\n1. Wraps your app in a `RepaintBoundary`\n2. Captures frames at ~15fps into a circular buffer\n3. On exception, encodes the last ~10 seconds to MP4\n4. Sends the video alongside the stack trace\n\nTouch and click positions are drawn directly onto the recorded frames (invisible to the user) so you can see exactly what the user was doing before the crash.\n\n## Privacy Masking\n\nUse `TracewayPrivacyMask` to hide sensitive content in screen recordings. Masked regions are applied to the recorded frames only — the user sees no visual change in the live app.\n\n**Blur (pixelation):**\n\n```dart\nTracewayPrivacyMask(\n  child: Text('4242 4242 4242 4242'),\n)\n```\n\nThe default mode is `TracewayMaskMode.blur()` which pixelates the region. You can control the intensity with the `ratio` parameter (0.0 = light, 1.0 = heavy):\n\n```dart\nTracewayPrivacyMask(\n  mode: TracewayMaskMode.blur(ratio: 0.5),\n  child: CreditCardWidget(),\n)\n```\n\n**Blank (solid fill):**\n\n```dart\nTracewayPrivacyMask(\n  mode: TracewayMaskMode.blank(color: Color(0xFF000000)),\n  child: SensitiveDataWidget(),\n)\n```\n\nThis replaces the region with a solid color (black by default) in the recording.\n\n## Platform Support\n\n| Platform | Error Tracking | Screen Recording |\n|----------|---------------|-----------------|\n| iOS | Yes | Yes |\n| Android | Yes | Yes |\n| macOS | Yes | Yes |\n| Web | No | No |\n\nFor Flutter web, use the JS SDK instead — see [Flutter Web](#flutter-web) below.\n\n## What Gets Captured Automatically\n\n- **Flutter framework errors** — rendering, layout, gestures via `FlutterError.onError`\n- **Platform errors** — native plugin crashes via `PlatformDispatcher.onError`\n- **Uncaught async errors** — unhandled futures via `runZonedGuarded`\n\n## Flutter Web\n\nThis SDK does not support Flutter web. For web apps, use the [`@tracewayapp/frontend`](https://docs.tracewayapp.com/client/js-sdk?sdk=js-generic) JS SDK which provides rrweb session replay and automatic fetch instrumentation.\n\n**Add the CDN script to `web/index.html`:**\n\n```html\n\u003cscript src=\"https://cdn.jsdelivr.net/npm/@tracewayapp/frontend@1/dist/traceway.iife.global.js\"\u003e\u003c/script\u003e\n\u003cscript\u003e\n  Traceway.init(\"your-token@https://traceway.example.com/api/report\");\n\u003c/script\u003e\n```\n\nAlternatively, if you use npm in your Flutter web project:\n\n```bash\nnpm install @tracewayapp/frontend\n```\n\n```html\n\u003cscript type=\"module\"\u003e\n  import { init } from '@tracewayapp/frontend';\n  init('your-token@https://traceway.example.com/api/report');\n\u003c/script\u003e\n```\n\nSee the full [JS SDK documentation](https://docs.tracewayapp.com/client/js-sdk?sdk=js-generic) for all options.\n\n## Links\n\n- [Traceway Website](https://tracewayapp.com)\n- [Traceway GitHub](https://github.com/tracewayapp/traceway)\n- [Documentation](https://docs.tracewayapp.com/client/flutter?sdk=flutter)\n- [Flutter SDK Source](https://github.com/tracewayapp/traceway-flutter)\n\n## License\n\nMIT\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftracewayapp%2Ftraceway-flutter","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftracewayapp%2Ftraceway-flutter","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftracewayapp%2Ftraceway-flutter/lists"}