Skip to main content

A simple solution to analysis and extract information from traceback.

Project description

Unwind

A simple solution to analysis and extract information from traceback

install

pip install unwind

usage

from unwind import Report

with Report() as report:
    a = 1
    b = 2
    c = 'a'
    d = 1 + c

print(report.errors[0])
print(report.reports[0])

'''
(<class 'TypeError'>, TypeError("unsupported operand type(s) for +: 'int' and 'str'"), <traceback object at xxxxx>)
---------report--------
info = _TraceContext(file='xxxxxx', line=7, name='<module>', code='d = 1 + c', locals={...})
flag = operate
args = {'c': 'a'}
---------end------
'''

or

from unwind import get_report

try:
    a = 1
    b = 2
    c = 'a'
    d = 1 + c
except Exception as e:
    print(get_report(e))

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

unwind-0.4.0.tar.gz (7.1 kB view details)

Uploaded Source

Built Distribution

unwind-0.4.0-py3-none-any.whl (7.9 kB view details)

Uploaded Python 3

File details

Details for the file unwind-0.4.0.tar.gz.

File metadata

  • Download URL: unwind-0.4.0.tar.gz
  • Upload date:
  • Size: 7.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: pdm/2.1.3 CPython/3.8.6

File hashes

Hashes for unwind-0.4.0.tar.gz
Algorithm Hash digest
SHA256 a31a9f7ebaddf7eff0545055bcb601386b85b8631e6ab622140b07c64d77d2eb
MD5 afe3bb748201a9a848233f8b4ffceb69
BLAKE2b-256 528f88dd8cd4b658b4697bee1a37193a5f4afdb243e83f6e925b56e3bd6334e6

See more details on using hashes here.

File details

Details for the file unwind-0.4.0-py3-none-any.whl.

File metadata

  • Download URL: unwind-0.4.0-py3-none-any.whl
  • Upload date:
  • Size: 7.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: pdm/2.1.3 CPython/3.8.6

File hashes

Hashes for unwind-0.4.0-py3-none-any.whl
Algorithm Hash digest
SHA256 db1cf2ade01fadbefb56bbce81c2c49f1710453b4fcbcef415df59c4c3711b9d
MD5 66de9698073a704354bb34d2adc432f5
BLAKE2b-256 96624dd1fda0a2e81db21f9d070313b7bef4e948cca0dd9e7b919eba1f4fe01d

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page