zope.tales
Zope Template Application Language Expression Syntax (TALES)
What it is and what it does
zope.tales is an expression language engine that interprets dynamic expressions within template contexts. It is designed primarily to integrate with zope.tal (Template Attribute Language) and zope.pagetemplate to enable server-side template rendering with dynamic variable substitution and expression evaluation. The package provides path expressions, string expressions, and other expression types that allow templates to reference variables, call methods, and perform conditional logic at render time.
The package depends on zope.interface for interface definitions and setuptools for packaging. It supports modern Python versions (3.9 through 3.13) and runs on both CPython and PyPy. The codebase has been maintained since 2007 and reached version 7.0 in 2025, with recent updates including PEP 420 namespace migration and Python 3.12/3.13 support. It is part of the broader Zope ecosystem and is typically used as a component within larger template-rendering systems rather than as a standalone tool.
Use it for:
- Render Zope page templates with dynamic variable substitution and expression evaluation in web applications.
- Evaluate path expressions to access nested object attributes and method results within template contexts.
- Integrate expression evaluation into custom template engines or domain-specific languages built on Zope infrastructure.
- Process string expressions with embedded variable references in server-side template rendering pipelines.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
zope.tales provides an expression language for evaluating dynamic expressions in template contexts, designed to work with zope.tal and zope.pagetemplate for server-side page template rendering.
Yes, if you are building or maintaining a Zope-based application or template system. The package is stable, has no known vulnerabilities, and supports current Python versions with low install friction. No, if you are starting a new project—modern alternatives like Jinja2 or Mako offer broader ecosystem support and more active development. The aging maintenance status and narrow use case (primarily Zope integration) make it a specialized tool rather than a general-purpose choice.
Install
zope-tales on PyPI
pip
pip install zope-talesuv
uv add zope-talespoetry
poetry add zope-talesInstalling zope.tales
Before you install
Low install friction with only two runtime dependencies (setuptools and zope.interface). The package is in aging maintenance status with the last commit on 2026-01-28, but remains actively supported for current Python versions (3.9 through 3.13).
License in practice
Licensed under ZPL-2.1 (Zope Public License), which is OSI-approved but has unclear treatment in some contexts. Verify compatibility with your project's license requirements before use.
Quickstart
pip install zope.tales
from zope.tales.engine import Engine
from zope.tales.tales import Context
engine = Engine()
context = Context(engine, {})
result = engine.compile('string:hello').eval(context)
Requires Python 3.9 or later; zope.interface must be installed as a runtime dependency.
Verify before relying
- Whether the package is actively maintained or in long-term stable mode given the 336 days since last release.
- Specific use cases beyond Zope framework integration where TALES expressions provide value over alternatives.
Package facts
| License | ZPL-2.1 (unclear) |
| Python support | supports the current Python release (>=3.9) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 2 — setuptools, zope.interface |
| Maintenance | aging — 336 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 135,505/month — #11,426 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: zope_tales-7.0-py3-none-any.whl
Keywords: zope, template, xml, tales
Tags
More WWW/HTTP packages
urllib3 is an HTTP client library that provides…
permissive · top 100 on PyPI
requestsRequests is a Python HTTP library that…
permissive · top 100 on PyPI
h11h11 is a pure-Python HTTP/1.1 protocol…
permissive · top 100 on PyPI
httpxHTTPX is a fully featured HTTP client library…
permissive · top 100 on PyPI
httpcoreA minimal low-level HTTP client library that…
permissive · top 100 on PyPI
aiohttpaiohttp is an async HTTP client and server…
permissive · top 100 on PyPI
zope.pagetemplatezope.pagetemplate provides a templating system…
unclear · top 15,000 on PyPI
zope.structuredtextParses and renders Zope structured text (STX),…
unclear · top 15,000 on PyPI
zope.talzope.tal implements the Template Attribute…
unclear · top 15,000 on PyPI
z3c.ptz3c.pt is a fast ZPT (Zope Page Template)…
unclear · top 15,000 on PyPI
DocumentTemplateDocumentTemplate implements the Document…
unclear · top 15,000 on PyPI
zope.exceptionsProvides general-purpose exception classes and…
unclear · top 15,000 on PyPI
zope.viewletzope.viewlet provides a pluggable framework for…
unclear · top 15,000 on PyPI
zope.ptresourceProvides a resource class that processes Zope…
unclear · top 15,000 on PyPI
zope.contentproviderProvides a framework for building componentized…
unclear · top 15,000 on PyPI
ChameleonChameleon is an HTML/XML template engine that…
permissive · top 15,000 on PyPI