Skip to main content

Make runtime objects available through `extra`.

Project description

griffe-runtime-objects

ci documentation pypi version gitter

Make runtime objects available through extra.

Installation

pip install griffe-runtime-objects

Usage

Enable the griffe_runtime_objects extension. Now all Griffe objects will have access to the corresponding runtime objects in their extra attribute, under the runtime-objects namespace:

>>> import griffe
>>> griffe_data = griffe.load("griffe", extensions=griffe.load_extensions("griffe_runtime_objects"), resolve_aliases=True)
>>> griffe_data["parse"].extra
defaultdict(<class 'dict'>, {'runtime-objects': {'object': <function parse at 0x78685c951260>}})
>>> griffe_data["Module"].extra
defaultdict(<class 'dict'>, {'runtime-objects': {'object': <class '_griffe.models.Module'>}})

This extension can be useful in custom templates of mkdocstrings-python, to iterate on an object value or attributes.

With MkDocs:

plugins:
- mkdocstrings:
    handlers:
      python:
        options:
          extensions:
          - griffe_runtime_objects

Sponsors

Silver sponsors

FastAPI

Bronze sponsors

Nixtla


ofek samuelcolvin tlambert03 ssbarnea femtomc cmarqu kolenaIO ramnes machow BenHammersley trevorWieland MarcoGorelli analog-cbarber OdinManiac rstudio-sponsorship schlich butterlyn livingbio NemetschekAllplan EricJayHartman 15r10nk activeloopai roboflow cmclaughlin blaisep RapidataAI rodolphebarbanneau theSymbolSyndicate blakeNaccarato ChargeStorm Alphadelta14 Cusp-AI

And 7 more private sponsor(s).

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

griffe_runtime_objects-0.3.1.tar.gz (28.2 kB view details)

Uploaded Source

Built Distribution

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

griffe_runtime_objects-0.3.1-py3-none-any.whl (7.2 kB view details)

Uploaded Python 3

File details

Details for the file griffe_runtime_objects-0.3.1.tar.gz.

File metadata

  • Download URL: griffe_runtime_objects-0.3.1.tar.gz
  • Upload date:
  • Size: 28.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.2

File hashes

Hashes for griffe_runtime_objects-0.3.1.tar.gz
Algorithm Hash digest
SHA256 eecb887e1fb6b48bddcfc6115a61f59b3a91aeaadd9b932b8056eb8dd7811a57
MD5 d72fb0f323af36304fc51e9220918c6a
BLAKE2b-256 2a38e80d9a1a52ce7a815f18739e7ce6f8ac3604ae3007ec0e671e85cecdd340

See more details on using hashes here.

File details

Details for the file griffe_runtime_objects-0.3.1-py3-none-any.whl.

File metadata

File hashes

Hashes for griffe_runtime_objects-0.3.1-py3-none-any.whl
Algorithm Hash digest
SHA256 e7b219f2b58f7aefa763329213c11174cda815d7d69aeb2903460a7ddc3fef1c
MD5 03a5a9cbc12d70525322d9ea9da8892f
BLAKE2b-256 366cbc25e97b6aabe224da5106787cd585d2aa8ca3da9b7e73ef06a697037e24

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