Sqla-filters

Latest version: v0.0.2

Safety actively analyzes 685525 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

0.0.2

Changes

The JSON parser is now available as a separate package.
Documentation folder is now present (need to link it with `Read the Docs`).
Pipenv user can now find the **Pipfile** and the **Pipfile.lock**.
Extend the usage of the namespace packages to the nodes (not in its final version).

0.0.1

Initial release.

The following operator are supported:

| support | operators | name | code |
|:-------:|:----------|:---------------------:|-------------------:|
| [x] | eq | equal | operators.eq |
| [x] | not_eq | not equal | operators.ne |
| [x] | null | null | is None |
| [x] | not_null | not null | is not None |
| [x] | gt | greater than | operators.gt |
| [x] | gte | greater than or equal | operators.ge |
| [x] | lt | lower than | operators.lt |
| [x] | lte | lower than or equal | operators.le |

Example of json format
json
{
"type": "and",
"data": [
{
"type": "operator",
"data": {
"attribute": "name",
"operator": "eq",
"value": "toto"
}
}
]
}


Example of usage
python
parser = JSONFiltersParser(raw_json_string)

You can finaly filter your query
query = session.query(Post)
filtered_query = parser.tree.filter(query)

Links

Releases

Has known vulnerabilities

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.