Skip to main content

A debugging tool that can help you what happened when you code quits unexpectedly

Project description

wthell

wthell is a debugging tool for python to interactively check frame stack when your code quit unexpectedly

Install

You can install wthell from pip

pip install wthell

Usage

It's super easy to use wthell. Just import it and it's done!

import wthell

If there's an uncaught exception, you will enter an interactive shell like this:

. def g(a, b):
.     a += h(a)
.     b += 3
>     raise Exception("lol")


<class 'Exception'> lol

back  -- go to outer frame | in     -- go to inner frame
clear -- reset the console | ctrl+D -- quit

>>> 

You will be in the frame(function) that raised exceptions in the beginning. You can type back to go to outer frame(its caller). You can type in to go to inner frame(when you already go out). wthell will record the full call stack so you can check any frame.

While you are in a stack, you can type anything that you want to evaluation to help you debug.

>>> a
13
>>> a + 1
14
>>> h(a)
16
>>> 

wthell behaves like an interactive shell.

Happy debugging!

License

Copyright Tian Gao, 2020.

Distributed under the terms of the Apache 2.0 license.

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

wthell-0.0.1.tar.gz (3.5 kB view details)

Uploaded Source

Built Distribution

wthell-0.0.1-py3-none-any.whl (7.9 kB view details)

Uploaded Python 3

File details

Details for the file wthell-0.0.1.tar.gz.

File metadata

  • Download URL: wthell-0.0.1.tar.gz
  • Upload date:
  • Size: 3.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/47.1.0 requests-toolbelt/0.9.1 tqdm/4.48.2 CPython/3.8.5

File hashes

Hashes for wthell-0.0.1.tar.gz
Algorithm Hash digest
SHA256 cf4a111745e6f2dc81d508e1a8a9e290d3770d6e29a6967f7a30b940f80616ec
MD5 1fc6f4875ed3cf1aa791b18d0cfda91b
BLAKE2b-256 1d48dc49169547fbe859dc7a6e8754b4890b448f39870e3e9988bd61f2313f72

See more details on using hashes here.

File details

Details for the file wthell-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: wthell-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 7.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/47.1.0 requests-toolbelt/0.9.1 tqdm/4.48.2 CPython/3.8.5

File hashes

Hashes for wthell-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 4c54a7b814193119ed7d712dd3424df4e5f127eb3a78c1059833698478497386
MD5 ce3ffe0365a62fb79a9d368092c9bdf8
BLAKE2b-256 4791ff2990ce86b3ffff37eb0cf10452e6100a8bce30bd9841bd8fac63b91586

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