Skip to main content

Simple to use, Powerful Programming! Debugging, Printing, Analysis, and helpful tools!

Project description

Print Tricks And More

Simple to use, powerful programming tools for debugging, printing, analysis, and more!

Installation

pip install print-tricks-and-more

Features

  • Enhanced print statements with variable name, type, and line number information
  • Color-coded output for better readability
  • Timer functions for performance measurement
  • Easy debugging tools
  • Thread management helpers
  • And much more!

Basic Usage

from print_tricks import pt

# Basic variable printing
name = "Python"
pt(name)  # Will print the variable name, value, type, and line number

# Color printing
pt.c("This text will be colored", colors=pt.C.t1)

# Timer functionality
pt.t("timer_name")  # Start timer
# ... some code to measure
elapsed = pt.t("timer_name")  # End timer and get elapsed time

# Pause execution until a key is pressed
pt.p()  # Pause until any key is pressed
pt.p("y")  # Pause until 'y' key is pressed

# Error handling
try:
    # Some code that might raise an exception
    result = 1 / 0
except:
    pt.e()  # Print exception information

Advanced Features

  • pt.counter() - Count function calls
  • pt.profile_resources() - Monitor CPU, memory, and GPU usage
  • pt.timeall() - Comprehensive timing for functions
  • pt.props() - Inspect object properties
  • pt.easy_imports() - Simplify import paths

Documentation

For more detailed documentation, please visit the GitHub repository.

License

This project is licensed under the MIT License.

Project details


Release history Release notifications | RSS feed

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page