Skip to main content

Object Registry

Keep track of all instantiated objects of a class.

Installation

pip install object-registry

Getting started

For any class whose objects you want to track, inherit from ObjectRegistry upon definition.

from object_registry import ObjectRegistry

class MyClass(ObjectRegistry): ...

Instantiate objects of the derived class as usual. Each object will be automatically added to the registry.

obj = MyClass()

Use from_id to retrieve an object by its Python object ID.

object_id = id(obj)
retrieved_obj = MyClass.from_id(object_id)

Metadata

Release files for object-registry 0.3.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for object-registry 0.3.0
File Size Uploaded
object_registry-0.3.0.tar.gz 14.0 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for object-registry 0.3.0
File Interpreter ABI Platform
object_registry-0.3.0-py3-none-any.whl Python 3 none any Details

Total release size: 28.6 kB

Release files / object_registry-0.3.0.tar.gz

Download URL object_registry-0.3.0.tar.gz
Size 14.0 kB
Tags Source
SHA-256 checksum
How to use checksums
fdd58a824bc7b873fd156f11891933ef6fd6f9e6df0a3b90dc6898827b092d78
BLAKE2b-256 checksum
How to use checksums
f689e03d6e99776981b23d66c02aa1a6c1cac77d37fffaa1a8e698c7631224b4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.11.3

Release files / object_registry-0.3.0-py3-none-any.whl

Download URL object_registry-0.3.0-py3-none-any.whl
Size 14.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
78fa638537fcedb1543cd9d6867482e6f1f952edd0c20ed8a95107fe49b4f489
BLAKE2b-256 checksum
How to use checksums
a9dd3b592ffbcd06c6bf8ac6613f6a9f2de068aaf133af83766a5c2b94ac91ea
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.11.3

Release history Release notifications | RSS feed

This release

0.3.0 This release

2 release files

0.2.0

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page