Skip to main content

Get and open StackOverflow posts for your tracebacks.

Project description

sotrace

This package opens up StackOverflow posts for your errors. It's the ultimate efficiency tool!

Example Usage

from sotrace import open_link


try:
    my_dict = {}
    print(my_dict[1])
except Exception as e:
    open_link(e)
from sotrace import open_link


open_link("What does the yield keyword do?", tags=["python", "generator"], num_of_results=3)

sotrace can also be run from the command line as a wrapper of sorts.

❯ python3 -m sotrace example2.py
Traceback (most recent call last):
  File "example2.py", line 2, in <module>
    print(my_dict[1])
KeyError: 1
(Opens links)

More arguments can be found using python3 -m sotrace -h, which gives:

❯ python3 -m sotrace -h
usage: __main__.py [-h] [--results RESULTS] [--tags TAGS [TAGS ...]] [--not-pretty] file

positional arguments:
  file                  File to execute with sotrace.

optional arguments:
  -h, --help            show this help message and exit
  --results RESULTS     Number of results to open.
  --tags TAGS [TAGS ...]
                        Preferred tags.
  --not-pretty          Don't use prettier tracebacks from the rich library. (not recommended)

Roadmap

  • Documentation
  • Default issue template
  • Github Actions

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

sotrace-1.1.2.tar.gz (3.7 kB view details)

Uploaded Source

Built Distribution

sotrace-1.1.2-py3-none-any.whl (4.0 kB view details)

Uploaded Python 3

File details

Details for the file sotrace-1.1.2.tar.gz.

File metadata

  • Download URL: sotrace-1.1.2.tar.gz
  • Upload date:
  • Size: 3.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.24.0 setuptools/50.3.2 requests-toolbelt/0.9.1 tqdm/4.54.1 CPython/3.8.6

File hashes

Hashes for sotrace-1.1.2.tar.gz
Algorithm Hash digest
SHA256 cc1d3a13328f39c6a865eb5e95d04e345d654d397349010f6e890f651232f2b2
MD5 41da131dea7ac9b916cdfb6c19b6b66b
BLAKE2b-256 9c11387cd02146cf416c3ec2e5190a2d18c2b77dc228a189abd8f57bdf867442

See more details on using hashes here.

File details

Details for the file sotrace-1.1.2-py3-none-any.whl.

File metadata

  • Download URL: sotrace-1.1.2-py3-none-any.whl
  • Upload date:
  • Size: 4.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.24.0 setuptools/50.3.2 requests-toolbelt/0.9.1 tqdm/4.54.1 CPython/3.8.6

File hashes

Hashes for sotrace-1.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 043d9acaa8560923993d40700cf47da9e0922dd3b111749a319484a784773757
MD5 de490810371545b37d4da9d64c6827b0
BLAKE2b-256 97db0e9da58544b89185f6c8812f1a15c807d705921943f4cfc22cd2d77590a9

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