cql2
Parse, validate, and convert Common Query Language (CQL2) text and JSON
Decision gist · record as of 2026-08-14
Yes. The package is actively maintained, has no security vulnerabilities, carries a permissive MIT license, and solves a specific standards-based problem (CQL2 parsing and conversion). Medium install friction is acceptable given the pre-built wheels for common platforms. Install if you need to parse or convert CQL2 expressions; skip if you don't work with OGC query standards.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- Requires Python 3.10 or later; compiled wheels available for common platforms but may require compilation on unsupported architectures.
- Medium install friction due to compiled Rust bindings, but pre-built wheels cover common platforms (macOS, Linux, Windows, multiple architectures).
- Active maintenance with a release within the last day.
License · maintenance · safety
MIT (permissive) — MIT license permits commercial and private use with minimal restrictions; suitable for most projects.
last release 2026-08-13 (1 days) · last repo commit 2026-08-13 · 23 stars
0 known vulnerabilities (OSV.dev, 2026-08-14) · 121,001 downloads/mo, #12,001 on PyPI
Alternatives
Verify before relying
pip install cql2
from cql2 import Expr
expr = Expr("landsat:scene_id = 'LC82030282019133LGN00'")
print(expr.to_sql())- Whether the CLI is automatically available after pip install or requires additional setup
- Performance characteristics for large or complex CQL2 expressions
- Completeness of CQL2 standard coverage in this implementation
What it is and what it does
cql2 is a Python binding to a Rust implementation of the OGC Common Query Language (CQL2) standard. It lets you parse CQL2 query expressions from text or files and convert them into multiple output formats—text, JSON, or SQL—making it useful for applications that need to accept user-friendly query syntax and translate it into database-specific query languages.
The package provides both a Python API and a command-line tool. It has no runtime dependencies beyond Python itself, though installation requires pre-built wheels or a Rust toolchain to compile. It supports Python 3.10 through 3.14 and is actively maintained.
Use it for
- Convert user-supplied CQL2 query strings into SQL for database backends in geospatial or data-discovery applications
- Parse and validate CQL2 expressions in REST APIs that accept OGC-compliant query filters
- Transform CQL2 text queries into JSON representation for downstream processing or storage
- Build CLI tools that accept CQL2 syntax and emit SQL or other query formats
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
Yes.
The package is actively maintained, has no security vulnerabilities, carries a permissive MIT license, and solves a specific standards-based problem (CQL2 parsing and conversion). Medium install friction is acceptable given the pre-built wheels for common platforms. Install if you need to parse or convert CQL2 expressions; skip if you don't work with OGC query standards.
Install
cql2 on PyPI
Before you install
Medium install friction due to compiled Rust bindings, but pre-built wheels cover common platforms (macOS, Linux, Windows, multiple architectures). Active maintenance with a release within the last day.
Requires Python 3.10 or later; compiled wheels available for common platforms but may require compilation on unsupported architectures.
License in practice
MIT license permits commercial and private use with minimal restrictions; suitable for most projects.
Quickstart
pip install cql2
from cql2 import Expr
expr = Expr("landsat:scene_id = 'LC82030282019133LGN00'")
print(expr.to_sql())
Verify before relying
- Whether the CLI is automatically available after pip install or requires additional setup
- Performance characteristics for large or complex CQL2 expressions
- Completeness of CQL2 standard coverage in this implementation
Package facts
| License | MIT permissive |
| Python support | Supports the current Python release >=3.10 |
| Install friction | Medium. Platform-specific wheel |
| Runtime dependencies | None |
| Maintenance | Actively maintained 1 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 121,001 / month, #12,001 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
| Classifiers | Programming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.14Programming Language :: Python :: Implementation :: CPythonProgramming Language :: Python :: Implementation :: PyPyProgramming Language :: Rust |
Evidence: cql2-0.6.0-cp310-abi3-macosx_10_12_x86_64.whl; cql2-0.6.0-cp310-abi3-macosx_11_0_arm64.whl; cql2-0.6.0-cp310-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl; cql2-0.6.0-cp310-abi3-manylinux_2_17_armv7l.manylinux2014_armv7l.whl; cql2-0.6.0-cp310-abi3-manylinux_2_17_i686.manylinux2014_i686.whl; cql2-0.6.0-cp310-abi3-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl; cql2-0.6.0-cp310-abi3-manylinux_2_17_s390x.manylinux2014_s390x.whl; cql2-0.6.0-cp310-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl; cql2-0.6.0-cp310-abi3-musllinux_1_2_aarch64.whl; cql2-0.6.0-cp310-abi3-musllinux_1_2_armv7l.whl; cql2-0.6.0-cp310-abi3-musllinux_1_2_i686.whl; cql2-0.6.0-cp310-abi3-musllinux_1_2_x86_64.whl; cql2-0.6.0-cp310-abi3-win32.whl; cql2-0.6.0-cp310-abi3-win_amd64.whl
Tags
Let your AI agent find packages like this
Example. Real query, live index.
You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.
wish › “cql2 parser”
- cql2Parses, validates, and converts Common Query Language (CQL2)…
- pypgstacpypgstac provides Python bindings and utilities for managing…
- ArpeggioArpeggio is a recursive descent parser with memoization that…
Give your agent the search over MCP, or paste the wish link into any chat.
More Text Processing packages
A drop-in replacement for Python's standard `re` module that adds advanced regex features like nested sets, fuzzy matching, lookaround in conditionals, and full Unicode case-folding while maintaining backward compatibility.
pyparsing provides a library for building text parsers directly in Python code using composable grammar classes, handling quoted strings, whitespace variation, and embedded comments without regex or lex/yacc.
Install it if you need to parse text or define grammars programmatically.
fonttools manipulates font files in multiple formats (TrueType, OpenType, AFM, Type 1, Mac-specific) and includes TTX, a tool to convert fonts to and from XML text format.
Install it if you need to read, write, or manipulate fonts programmatically or via the TTX command-line tool.
Docutils converts plaintext documentation in reStructuredText format into multiple output formats including HTML, XML, and LaTeX using a modular processing system.
RapidFuzz provides fast fuzzy string matching using Levenshtein Distance and related metrics, implemented mostly in C++ with Python bindings for rapid similarity scoring and approximate string matching.
Install it if you need fuzzy string matching; it's a solid replacement for FuzzyWuzzy with better licensing and performance.
tinycss2 parses CSS strings into token and block objects, and generates CSS strings from those objects, following the CSS Syntax Level 3 specification without enforcing specific properties or values.
Install it if your project requires CSS tokenization or syntax manipulation.
See also hogql-parser-rs · scim2-filter-parser · pygeofilter · syntaqlite · promql-parser · jsonata-python · moz-sql-parser · sqloxide · mo-sql-parsing · openlineage-sql