Skip to main content

Dynamic-Expressions

A Python library for building, evaluating, and serializing expression trees.

Documentation

Installation

pip install dynamic-expressions

With optional dependencies:

pip install dynamic-expressions[cache-redis,serialization-pydantic,serialization-msgspec]

Quick example

import asyncio

from dynamic_expressions.dispatcher import VisitorDispatcher
from dynamic_expressions.nodes import BinaryExpressionNode, LiteralNode
from dynamic_expressions.types import EmptyContext
from dynamic_expressions.visitors import BinaryExpressionVisitor, LiteralVisitor

dispatcher = VisitorDispatcher[EmptyContext](
    visitors={
        LiteralNode: LiteralVisitor(),
        BinaryExpressionNode: BinaryExpressionVisitor(),
    },
)

node = BinaryExpressionNode(
    operator="+",
    left=LiteralNode(value=1),
    right=LiteralNode(value=2),
)

async def main() -> None:
    result = await dispatcher.visit(node, None)
    assert result == 3

asyncio.run(main())

See the getting started guide for more.

Metadata

Release files for dynamic-expressions 0.2.3

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

Source distribution (sdist)

Source distribution for dynamic-expressions 0.2.3
File Size Uploaded Provenance Actions
dynamic_expressions-0.2.3.tar.gz 16.6 kB Without provenance Details for dynamic_expressions-0.2.3.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for dynamic-expressions 0.2.3
File Interpreter ABI Platform Actions
dynamic_expressions-0.2.3-py3-none-any.whl Python 3 none any Details for dynamic_expressions-0.2.3-py3-none-any.whl

Total release size: 37.5 kB

Release files / dynamic_expressions-0.2.3.tar.gz

Download URL dynamic_expressions-0.2.3.tar.gz
Size 16.6 kB
Tags Source
SHA-256 checksum
How to use checksums
abc26ab7ff3571065af771dfe9df42bdc4dd322240b0da57fd20f4dabbd4ea7e
BLAKE2b-256 checksum
How to use checksums
8cf70071137215d9c181ebe38db247baa7340c7c02e4c1f4d7b3f6fec1bfb575
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.11.21 {"installer":{"name":"uv","version":"0.11.21","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / dynamic_expressions-0.2.3-py3-none-any.whl

Download URL dynamic_expressions-0.2.3-py3-none-any.whl
Size 20.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
3ec567aea257a6cbb0e75e21e86f5f434ce2daf6711d735a3adc0dfb7ee67a8f
BLAKE2b-256 checksum
How to use checksums
7538c089304ca6bbbe2b5c51adc4a847df00a938c1a4e1df7016a98ce44dd88c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.11.21 {"installer":{"name":"uv","version":"0.11.21","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Security for dynamic-expressions 0.2.3

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.

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