Skip to main content

A Python tool that generates video visualizations for source code debugging.

Project description

PyBud

PyBud is a Python debugging and profiling tool that generates videos of step-by-step code execution.

Here's a PyBud video output from debugging the usage example below!

Demo

Installation

Use the package manager pip to install PyBud.

pip install pybud

Usage Example

Usage_Example

Usage

Once installed, running pybud --help will give you an overview of how to use PyBud.

Here's the help output:

$ pybud -h
usage: pybud [-h] [-t] [-d FILE] [-f FUNCTION [FUNCTION ...]] [-o FILE] [-v [FILE]] [-c CONFIG] [-p [FILE]]

A Python debugger for analyzing and profiling functions. Created by Eastan Giebler.

optional arguments:
  -h, --help            show this help message and exit
  -t, --test            Test PyBud on a suite of sorting, searching, and similar algorithms. Outputs a PyBud JSON for each function in the
                        'pybud/test/test_logs' package.

Debugging:
  Debug a python function and generate an output log.

  -d FILE, --debug FILE
                        Path to the Python file you wish to debug.
  -f FUNCTION [FUNCTION ...], --function FUNCTION [FUNCTION ...]
                        The function in the Python file you wish to debug, along with the arguments you wish to pass. Defaults to the main
                        function if argument not used. EXAMPLE: '--function test 2 4' will call 'test(2,4)'.
  -o FILE, --output FILE
                        Optional: Path to write the json log file to. Defaults to output.pybud if argument not used.
  -v [FILE], --video [FILE]
                        Generate a video rendering for the PyBud debug steps of the program flow. Optional: provide a filepath to output to,
                        mp4 is the only supported format, defaults to output.mp4.
  -c CONFIG, --video-cfg CONFIG
                        Path to the YAML video config file you wish to use, default configuration will be loaded if not specified.

Parsing and Analysis:
  Parse a PyBud JSON output and display in human-readable form.

  -p [FILE], --parse [FILE]
                        Path to the json log you wish to parse into human-readable form. Defaults to output.pybud if a file is not specified.
  -v [FILE], --video [FILE]
                        Generate a video rendering for the PyBud debug steps of the program flow. Optional: provide a filepath to output to,
                        mp4 is the only supported format, defaults to output.mp4.
  -c CONFIG, --video-cfg CONFIG
                        Path to the YAML video config file you wish to use, default configuration will be loaded if not specified.

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

License

MIT

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

pybud-0.2.3.tar.gz (18.8 kB view details)

Uploaded Source

Built Distribution

pybud-0.2.3-py3-none-any.whl (21.7 kB view details)

Uploaded Python 3

File details

Details for the file pybud-0.2.3.tar.gz.

File metadata

  • Download URL: pybud-0.2.3.tar.gz
  • Upload date:
  • Size: 18.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.41.1 CPython/3.8.1

File hashes

Hashes for pybud-0.2.3.tar.gz
Algorithm Hash digest
SHA256 71411a6fa56cbfbd2275d1e22d9c1aa995a80f6609a8eb3e10c58a6e247bb428
MD5 189f59643dbc5ee7283056e3e5af03bc
BLAKE2b-256 172c956dfecde71c6fc9b73695abe5e6078cae138720d5e634b5b548f213720a

See more details on using hashes here.

File details

Details for the file pybud-0.2.3-py3-none-any.whl.

File metadata

  • Download URL: pybud-0.2.3-py3-none-any.whl
  • Upload date:
  • Size: 21.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.41.1 CPython/3.8.1

File hashes

Hashes for pybud-0.2.3-py3-none-any.whl
Algorithm Hash digest
SHA256 99cf328cdb9b895f0b85aeaba217d98981bec18933d8576e12ec4c4146910fc6
MD5 eabe08d6ce09d6ec7bac9f4748fe858f
BLAKE2b-256 fb6d37403b7bc9c8bdfd04616d42163caeca5ea40d1024545f215d34259bcc4e

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