Swiftpack.co - Package - swift-server/swift-backtrace

Backtrace

This Swift package provides support for automatically printing crash backtraces of Swift programs.

Usage

Add https://github.com/swift-server/swift-backtrace.git as a dependency in your Package.swift.

Crash backtraces

In your main.swift, do:

import Backtrace

// Do this first
Backtrace.install()

Finally, make sure you build your application with debug symbols enabled:

$ swift build -c release -Xswiftc -g

When your app crashes, a stacktrace will be printed to stderr.

Acknowledgements

Ian Partridge (GitHub, Twitter) the original author of this package.

Johannes Weiss (GitHub, Twitter) for the signal handling code.

Github

link
Stars: 190

Dependencies

Used By

Total: 0

Releases

1.2.0 - 2020-03-27 18:05:20

  • add deprecation warning on Backtrace.print()

1.1.1 - 2019-09-03 13:29:21

  • feat: cross-compilation support (#17)

1.1.0 - 2019-07-22 07:20:41

  • feat: add Backtrace.print() function (#15)

1.0.3 - 2019-07-18 12:12:18

  • feat: use libbacktrace (#8)
  • feat: automatic demangling of Swift symbols (#10)

1.0.2 - 2019-04-24 09:45:14

  • feat: Support Swift 4.2 (#3)

1.0.1 - 2019-04-20 19:57:12

  • fix: swift test on Linux (#1)
  • fix: Build CBacktrace as a system library (#2)

1.0.0 - 2019-04-19 20:04:51

  • Initial release