pyparsing
pyparsing - Classes and methods to define and execute parsing grammars
Install
pyparsing on PyPI
pip
pip install pyparsinguv
uv add pyparsingpoetry
poetry add pyparsingPackage facts
| License | MIT (permissive) |
| Python support | supports the current Python release (>=3.9) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | none |
| Maintenance | actively maintained — 204 days since the last release |
| Last repo commit | |
| First released | |
| Popularity | one of the top 1,000 most-downloaded packages on PyPI (30-day window, as of 2026-08-13) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-13) |
Evidence: pyparsing-3.3.2-py3-none-any.whl
About pyparsing
from the package's own PyPI description — quoted content, verbatim
PyParsing -- A Python Parsing Module
|Version| |Build Status| |Coverage| |License| |Python Versions| |Snyk Score|
Introduction
The pyparsing module is an alternative approach to creating and executing simple grammars, vs. the traditional lex/yacc approach, or the use of regular expressions. The pyparsing module provides a library of classes that client code uses to construct the grammar directly in Python code.
[Since first writing this description of pyparsing in late 2003, this
technique for developing parsers has become more widespread, under the
name Parsing Expression Grammars - PEGs. See more information on PEGs
here <https://en.wikipedia.org/wiki/Parsing_expression_grammar>__
.]
Here is a program to parse "Hello, World!" (or any greeting of the form
"salutation, addressee!"):
.. code:: python
from pyparsing import Word, alphas
greet = Word(alphas) + "," + Word(alphas) + "!"
hello = "Hello, World!"
print(hello, "->", greet.parse_string(hello))
The program outputs the following::
Hello, World! -> ['Hello', ',', 'World', '!']
The Python representation of the grammar is quite...
Read as markdown · JSON record · Source repository · Homepage · Docs
AI interpretation — verify before relying
AI-generated interpretation of the package facts above; every digit, version, license, or vulnerability id it cites is grounded in the facts already shown on this page
pyparsing provides a Python library for building and executing text parsing grammars directly in code, handling common parsing challenges like whitespace variation, quoted strings, and comments without requiring traditional lex/yacc tools.
Low install friction with zero runtime dependencies and a pure-Python wheel distribution. Active maintenance with a recent release (204 days ago) and 2482 GitHub stars signals reliable ongoing support.
MIT license permits commercial and private use with minimal restrictions, making pyparsing suitable for proprietary projects provided you include the license notice.
Usage
from pyparsing import Word, alphas
greet = Word(alphas) + "," + Word(alphas) + "!"
result = greet.parse_string("Hello, World!")
print(result)
Requires Python 3.9 or later.
Verdict: pyparsing is a mature, well-maintained parsing library with no known vulnerabilities, zero dependencies, and permissive licensing. It is suitable for production use across a wide range of text-parsing tasks from simple grammars to complex domain-specific languages.
Needs verification
- Whether the package's type hints (Typing :: Typed classifier) provide full coverage for static analysis workflows.
- Performance characteristics relative to regex-based or hand-written parsers for specific use cases.
Similar packages
permissive · top 1,000 on PyPI
pycparserpermissive · top 100 on PyPI
larkpermissive · top 1,000 on PyPI
databricks-sdkpermissive · top 1,000 on PyPI
docutilsunclear · top 1,000 on PyPI
pydotpermissive · top 1,000 on PyPI
parsopermissive · top 1,000 on PyPI
RapidFuzzpermissive · top 1,000 on PyPI
rich-argparsepermissive · top 1,000 on PyPI
click-didyoumeanpermissive · top 1,000 on PyPI