Skip to main content
Allows to aggregate key-value data from many sources.
Can be used, for example, as a proxy to settings object in Django framework.

The sources of key-value data are appended to :class:`MultiRegistry`
vi ``append()`` method, then looked up via standard Python
dotted notation, as explained in more detail below.

Upon access, attributes will be looked up in the parent objects
in the order the latter were appended.

For example, if we have two settings like objects:
``A`` with attribute ``a``
and ``B`` with attribute ``b``
and a third one, found in module importable from ``'some.registry.C'``,
we can construct the registry as:

>>>r = MultiRegistry(A, B, 'some.registry.C')

or alternatively:

>>>r = MultiRegistry()
>>>r.append(A)
>>>r.append(B)
>>>r.insert(2, 'some.registry.C')

.. note::
The registries can be provided as python objects or
dotted python paths. In the latter case an import error will
be raised if module at the path does not exist

then access the registry as:

r.b - attrubute b will be first looked
up in the object A, then in the object B, where
it will be found.

If there is an attribute present in more than one appended object,
the first one will be returned - in the same order the
registries are stored internally, which takes into account:

* order the registries were provided at the object initialization
* order of ``append()`` calls.
* taking into account indices provided with ``insert()`` call

If the attribute is not found, attribute error will be
raised.

Metadata

Release files for multi-registry 0.0.2

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

Source distribution (sdist)

Source distribution for multi-registry 0.0.2
File Size Uploaded Provenance
multi-registry-0.0.2.tar.gz 7.7 kB Without provenance Details

Release files / multi-registry-0.0.2.tar.gz

Download URL multi-registry-0.0.2.tar.gz
Size 7.7 kB
Tags Source
SHA-256 checksum
How to use checksums
c5e0f819cbd2520031271f9627314aec68066a423cfb8a49082017b2c46d9d4a
BLAKE2b-256 checksum
How to use checksums
f0f7f64cb2047ac63ebea54f7c52f3a0b27133427798881548956569bdc31435
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Security for multi-registry 0.0.2

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.0.2 This release

1 release file No provenance

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