--- id: panzi-json-logic version: "1.0.1" license: unclear license_treatment: permissive maintenance: abandoned --- # panzi-json-logic — Pure Python 3 JsonLogic and CertLogic implementation. License: permissive · Maintenance: abandoned · Downloads: 607.4K/mo ## What it is and what it does panzi-json-logic is a pure Python interpreter for JsonLogic—a JSON-based format for expressing conditional logic that can be shared across languages and stored in databases. It also implements CertLogic, a dialect with different semantics used in certificate validation workflows. The package evaluates rules (expressed as nested JSON objects with operators as keys) against data objects, supporting comparison, logical, and data-access operations. The implementation aims to closely match the JavaScript reference implementation's operator behavior, including quirks like loose equality. It supports custom operations via an optional dictionary, and includes extras like time parsing and conversion utilities. With no external runtime dependencies, it installs cleanly, but the project has been abandoned since 2021-09-12 and receives no maintenance. Use it for: - Store conditional business rules in a database and evaluate them server-side without recompiling or redeploying code. - Share the same rule logic between a web front-end and Python back-end to keep validation consistent. - Implement certificate validation workflows using CertLogic rules for EU digital certificates or similar systems. - Build a rules engine where non-developers can define logic in JSON without writing Python code. - Evaluate time-based rules using built-in time operators for expiration or validity checks. ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. Evaluates JsonLogic and CertLogic rules—JSON-serializable logic formats designed to share conditional rules between front-end and back-end code—against data objects and returns the computed result. Yes, if you need to evaluate JsonLogic or CertLogic rules and can tolerate an unmaintained library. The package is stable, has no dependencies, and works well for its stated purpose. However, do not use it if you require active maintenance, security updates, or compatibility assurance with future Python versions. For new projects, consider whether a maintained alternative better fits your risk tolerance. ## Install pip install panzi-json-logic uv add panzi-json-logic poetry add panzi-json-logic ## Installing panzi-json-logic Before you install: No runtime dependencies and a pure Python wheel make installation straightforward. However, the project is abandoned—last commit was 2021-09-12 and no updates have been released since. Security and compatibility fixes are unlikely. License in practice: Licensed under MIT (permissive), so you can use, modify, and distribute the package freely with minimal restrictions. Quickstart: pip install panzi-json-logic from panzi_json_logic import jsonLogic rule = {"==": [1, 1]} result = jsonLogic(rule) # True rule_with_data = {"var": "temp"} data = {"temp": 100} result = jsonLogic(rule_with_data, data) # 100 Requires Python 3.6 or later. Verify before relying: - How well does the JavaScript operator emulation handle edge cases in production use? - Are there known incompatibilities with recent Python versions? - Does the package handle deeply nested rules or large datasets efficiently? ## Package facts - License: not declared (permissive) - Python support: supports_current - Install friction: low - Maintenance: abandoned - Downloads: 607.4K/month (top 15,000 on PyPI) - Known vulnerabilities: none known ## Tags json logic evaluation, certlogic rules engine, cross-language rule evaluation, json conditional logic, rule engine python, logic rules from json, shared business rules, rules-engine, json-logic, cross-language [View on SkillFed](https://skillfed.io/packages/panzi-json-logic) · [View on PyPI](https://pypi.org/project/panzi-json-logic/)