Skip to main content

A small debug printing module that prints extra info like filenames, function names, and line numbers. It can also recursively print lists, tuples, and dicts.

Project description

A small debug printing module that prints extra info like filenames, function names, and line numbers. It can also recursively print objects such as lists, tuples, and dicts.

More useful stuff may be added in the future.

Example Usage:

from printdebug import debug, printobject
def myfunction():
    debug('Hello from myfunction.', basename=True)

myfunction()

# Output:
#   myfile.py:3 myfunction: Hello from myfunction.

o = {'key1': {'subkey1': 'value1', 'subkey2': 'value2'}}
printobject(o)

# Output:
#    key1:
#        subkey1:
#            value1
#        subkey2:
#            value2

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

PrintDebug-0.1.1.tar.gz (17.9 kB view details)

Uploaded Source

File details

Details for the file PrintDebug-0.1.1.tar.gz.

File metadata

  • Download URL: PrintDebug-0.1.1.tar.gz
  • Upload date:
  • Size: 17.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for PrintDebug-0.1.1.tar.gz
Algorithm Hash digest
SHA256 f33a0b92604893c709471228907774bac75e53e882b5a449163ce2d0e35ad64e
MD5 1cae7b17ffba23becba92c11ae8246ec
BLAKE2b-256 2526f574367ed4adef99118a0029c2a842d301969c0bf4a1fd247a88b11a2774

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