Skip to main content

sinew_devtools 1.1.0 copy "sinew_devtools: ^1.1.0" to clipboard
sinew_devtools: ^1.1.0 copied to clipboard

DevTools capture: recorders, redaction, fault rules and host override.

sinew_devtools #

pub package License Docs

DevTools capture: recorders, redaction, fault rules and host override.

What a tester needs to see and break the app: every request and exception recorded with secrets already hidden, faults that force a status or drop a connection, and a host that can be switched. This package is the capture; sinew_devtools_ui is the overlay. A production build contains neither.

Features #

  • NetworkRecorder and ExceptionRecorder: bounded, in memory, newest first
  • Redaction: hides tokens, passwords and one-time codes in headers, URLs and bodies before anything is stored, extend-only
  • FaultRules and HostOverride, applied inside the auth layer so a forced 401 runs the real refresh
  • DevToolsGate: a const that is false in production, so the compiler removes every devtools entry point from the build

Getting started #

flutter pub add sinew_devtools

Usage #

void main() {
  DevToolsGate.assertMatchesFlavor();
  runApp(DevToolsGate.enabled ? SinewDevTools(child: const App()) : const App());
}

Build with --dart-define=SINEW_FLAVOR=staging for devtools in a release build. A production build, or one with no define, has none. CI proves it by searching the compiled output for a marker string.

Sinew is one architecture for Flutter and Kotlin, released as a set of packages at one version.

Documentation #

License #

Apache 2.0, see LICENSE.

0
likes
160
points
189
downloads

Documentation

Documentation
API reference

Publisher

verified publishersrctool.com

Weekly Downloads

DevTools capture: recorders, redaction, fault rules and host override.

Repository (GitHub)
View/report issues
Contributing

Topics

#devtools #debugging #networking

License

Apache-2.0 (license)

Dependencies

dio, flutter, sinew_exception, sinew_models, sinew_network, sinew_storage

More

Packages that depend on sinew_devtools