Skip to main content

Minimalistic lib for trace calls

Project description

CallTrace

Calltracer Logo
PyPI Version Python 3.8+ MIT License

A lightweight Python utility to track and log call hierarchy with class and method context.

Features

  • Automatically detects calling class and method names
  • Tracks nested call paths within the same class
  • Simple integration with existing code
  • Clean formatted output for debugging

Installation

pip install calltracing

Quick Start

from calltracing import CallContext

class MyClass:
    def method1(self):
        self.method2()
    
    def method2(self):
        print(CallContext.get_caller())

def standalone_function():
    print(CallContext.get_caller())

obj = MyClass()
obj.method1()
standalone_function()

License

MIT License

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

calltracing-1.0.1.tar.gz (2.7 kB view details)

Uploaded Source

Built Distribution

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

calltracing-1.0.1-py3-none-any.whl (3.4 kB view details)

Uploaded Python 3

File details

Details for the file calltracing-1.0.1.tar.gz.

File metadata

  • Download URL: calltracing-1.0.1.tar.gz
  • Upload date:
  • Size: 2.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.1.2 CPython/3.12.6 Windows/11

File hashes

Hashes for calltracing-1.0.1.tar.gz
Algorithm Hash digest
SHA256 b1e3005977d55d4b8a610a44b2134bb347f653eda39249130a57c72b0a54ea24
MD5 3b1039e75e116cfc30bdaae7ff3e3c2c
BLAKE2b-256 27a898710c6838f3d3397786f1638f93614c015c2e8794f1e71e634882ebdcc9

See more details on using hashes here.

File details

Details for the file calltracing-1.0.1-py3-none-any.whl.

File metadata

  • Download URL: calltracing-1.0.1-py3-none-any.whl
  • Upload date:
  • Size: 3.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.1.2 CPython/3.12.6 Windows/11

File hashes

Hashes for calltracing-1.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 703cd077d65bd447600c93ba35d54bf15d5970c6450a3fefc89d5c63d57f2ab4
MD5 29f5992837a29e080bbd60517121d40e
BLAKE2b-256 0f9042e12a7a4ebe12afb0ad9849641e54d1ce6f5f427d359bc2b4b7720a7365

See more details on using hashes here.

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