https://github.com/messense/py-promql-parser
PromQL parser for Python
https://github.com/messense/py-promql-parser
Last synced: 4 months ago
JSON representation
PromQL parser for Python
- Host: GitHub
- URL: https://github.com/messense/py-promql-parser
- Owner: messense
- License: mit
- Created: 2023-02-01T11:48:45.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2025-03-12T11:57:27.000Z (about 1 year ago)
- Last Synced: 2025-05-14T10:57:24.587Z (about 1 year ago)
- Language: Rust
- Size: 129 KB
- Stars: 19
- Watchers: 3
- Forks: 5
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# py-promql-parser

[](https://pypi.org/project/promql-parser)
[promql-parser](https://github.com/GreptimeTeam/promql-parser) Python binding, a PromQL parser for Python.
## Installation
```bash
pip install promql-parser
```
## Usage
```python
import promql_parser
ast = promql_parser.parse('prometheus_http_requests_total{code="200", job="prometheus"}')
print(ast)
```
## License
This work is released under the MIT license. A copy of the license is provided in the [LICENSE](./LICENSE) file.