Skip to content

PyTraceTable is a tool for scripting and script debugging. It aims to make a line-by-line debugging easier.

License

Notifications You must be signed in to change notification settings

filwaitman/pytracetable

Repository files navigation

Travis PyPI License Python versions PyPI downloads per month

pytracetable

Script debugging tool that aims to make a line-by-line debugging easier. Take a look:

from pytracetable import tracetable

@tracetable()
def some_weird_calculation(a, b):
        c = 10 + a
        b *= 2
        c += b
        del b
        return a + c

Then, calling some_weird_calculation(5, 10) will give the output:

--------------------------------------------------
At some_weird_calculation, line 3
    [ADDED]    a: 5 (int)
    [ADDED]    b: 10 (int)

--------------------------------------------------
At some_weird_calculation, line 4
    [ADDED]    c: 15 (int)

--------------------------------------------------
At some_weird_calculation, line 5
    [CHANGED]  b: 10 (int) --> 20 (int)

--------------------------------------------------
At some_weird_calculation, line 6
    [CHANGED]  c: 15 (int) --> 35 (int)

--------------------------------------------------
At some_weird_calculation, line 7
    [REMOVED]  b
    [RETURNED] 40 (int)

Development:

Run linter:

pip install -r requirements_dev.txt
isort -rc .
tox -e lint

Run tests via tox:

pip install -r requirements_dev.txt
tox

Release a new major/minor/patch version:

pip install -r requirements_dev.txt
bump2version <PART>  # <PART> can be either 'patch' or 'minor' or 'major'

Upload to PyPI:

pip install -r requirements_dev.txt
python setup.py sdist bdist_wheel
python -m twine upload dist/*

Contributing:

Please open issues if you see one, or create a pull request when possible. In case of a pull request, please consider the following:

  • Respect the line length (132 characters)
  • Write automated tests
  • Run tox locally so you can see if everything is green (including linter and other python versions)

About

PyTraceTable is a tool for scripting and script debugging. It aims to make a line-by-line debugging easier.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages