Skip to main content

This is the revival of a small Python module which lived once on the now abandoned Vaults of Parnassus when I entered Python programming about a decade ago. It was originally written and published by JasonHarper in 1998 on a “free for any use” license. Since then it has slowly faded from the net which I find a bit sad.

What is reverb?

reverb.py is a tiny wrapper around Pythons re module which maps regular expressions onto Python expressions for the sake of readability. The module name can be read as “re-verb(ose)”. reverb follows the Python tradition of keeping the amount of punctuation small and avoid punctuation collisions.

In reverb one writes

Optional(Digit)+"."+Required(Digit)

instead of

\d*\.\d+

to denote a pattern that matches a floating point number. The reverb reads much like a meta-language explanation of the dense and compact regexp.

From a reverb object one can fetch the regexp using the text attribute

>>> (Optional(Digit)+"."+Required(Digit)).text
'\\d*\\.\\d+'

Each reverb object translates to a regexp and it is finally the regexp which is compiled and matched against strings.

Reverb in context

I think about reverb any time I encounter a regexp learning tool but also pyparsing which has grown in popularity within the Python community and I suspect it did this for reasons not dissimilar to those intended by reverb: “avoiding line noise when writing regular expressions” in the words of Jason Harper. So I do think it fits a real need.

The only significant change I made to reverb is capitalization of names. reverb 1.0 was published when Python 1.5 came out and used identifiers like any and set which have now counterparts as builtins in Pythons standard library.

Documentation

The complete module documentation can be found here

Metadata

Release files for reverb 2.0.1

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

Source distributions (sdists)

Source distribution for reverb 2.0.1
File Size Uploaded Provenance
reverb-2.0.1.zip 3.4 kB Without provenance Details
reverb-2.0.1.tar.gz 2.8 kB Without provenance Details

Release files / reverb-2.0.1.zip

Download URL reverb-2.0.1.zip
Size 3.4 kB
Tags Source
SHA-256 checksum
How to use checksums
b65009f7723dac38eb1597dcf691e54cbf2431446f50ece37c3b572decf73ba3
BLAKE2b-256 checksum
How to use checksums
10691800d4345e0562260fa0818f6ac50d2f43d4595f33743c9e2c655709d86d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release files / reverb-2.0.1.tar.gz

Download URL reverb-2.0.1.tar.gz
Size 2.8 kB
Tags Source
SHA-256 checksum
How to use checksums
8dda1cc59ee87c0ce7822338bece1c0635319c6227afd718c3ebe296331ddb0e
BLAKE2b-256 checksum
How to use checksums
6a22c45dd56656f2a0e5cc1c4ede1f87a2d8776bb9404c2a20d1718002553da6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Security for reverb 2.0.1

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.

Release history Release notifications | RSS feed

This release

2.0.1 This release

2 release files No provenance

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