stack_trace_codec 0.1.0 copy "stack_trace_codec: ^0.1.0" to clipboard
stack_trace_codec: ^0.1.0 copied to clipboard

Dart 1 only

Serialize Stack Traces.

stack_trace_codec #

Build Status Pub Package Version Latest Dartdocs

Serialize stack traces from the stack_trace package.

Disclaimer: This is not an official Google or Dart project.

Installation #

Add stack_trace_codec in your [pubspec.yaml][pubspec] file:

dependencies:
  stack_trace_codec: ^0.1.0

And that's it! See usage for details.

Usage #

Currently, a single codec, JsonTraceCodec, is available:

import 'dart:convert';

import 'package:stack_trace/stack_trace.dart';
import 'package:stack_trace_codec/stack_trace_codec.dart';

void logJson(String json) { /* ... */ }

// See package:stack_trace for details on converting from StackTrace --> Trace.
void logStackTrace(Trace trace) {
  logJson(JSON.encode(const JsonTraceCodec().encode(trace)));
}

Contributing #

We welcome a diverse set of contributions, including, but not limited to:

For the stability of the API and existing users, consider opening an issue first before implementing a large new feature or breaking an API. For smaller changes (like documentation, minor bug fixes), just send a pull request.

Testing #

All pull requests are validated against travis, and must pass.

Ensure code passes all our analyzer checks:

$ dartanalyzer .

Ensure all code is formatted with the latest dev-channel SDK.

$ dartfmt -w .

Run all of our unit tests:

$ pub run test
0
likes
20
pub points
0%
popularity

Publisher

unverified uploader

Serialize Stack Traces.

Repository (GitHub)
View/report issues

License

BSD-3-Clause (LICENSE)

Dependencies

stack_trace

More

Packages that depend on stack_trace_codec