Luqum

Latest version: v0.13.0

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

Scan your dependencies

Page 1 of 4

1.0.0

.. _`Semantic Versioning`: http://semver.org/spec/v2.0.0.html

0.13.0

===================

Added
-----

* Add support for unbounded ranges

Support is added for open ranges, i.e. inequality operators in
front of a term. In tree form, the < is named To, and > is named From.

Additionally, a TreeTransformer is also added, to convert these
open ranges to more traditional Range objects.

To properly support escaping, some adjustments were made to how escaping
sequences work. After careful evaluation of how Apache Lucene handles
escape sequences, it appears that random characters can be escaped, even
if they result in unknown escape sequences: the escaped character is
always yielded. This makes support for operations such as `<\=foo` a lot
less complicated.

There is no support in the ElasticsearchQueryBuilder.

0.12.1

===================

Fixed
-----

- Precedence for unknown operation and boost (89, thanks to JSCU-CNI)

0.12.0

===================

Changed
-------

- Boost can be implicit ; by default, the boost factor is 1

Added
-----

- Add support for Lucene and Elasticsearch Boolean operations (71, thanks to linefeedse):

* Introduce the BooleanOperation
* add its resolution in ElasticSearch transformer
* add it as a possible resolver for the unknown operation (no explicit operator in query)

- Set E element as ElasticsearchQueryBuilder's attributes (75, thanks to qcoumes):

This allows to override elements such as EMust, EWord, ...,
without the need of overriding ElasticsearchQueryBuilder's methods.

- Explicit support for Python 3.9 and Python 3.10 (76)
- Add a thread safe parse function (82)

Fixed
-----

- Cast TokenValue.__str__ return value to string (74, thanks to delkopiso)
- Isolated comma should be parsed as a Word (80)
- Better handling of escaped wildcards

Docs
----

- Add boolean operation to doc
- Fix quick start documentation
- Updated readthedocs instructions

CI
--

- Run tests with github actions
- Update all libraries for dev:

* switch from nose to pytest as nose is not python3.10 compatible
* remove old travis tests

0.11.0

===================

Changed
-------

- completely modified the naming module and `auto_name` function, as it was not practical as is.

Added
-----

- added tools to build visual explanations about why a request matches a results
(leveraging `elasticsearch named queries`__.
- added a visitor and transformer that tracks path to element while visiting the tree.

__ https://www.elastic.co/guide/en/elasticsearch/reference/current/search-request-body.html#request-body-search-queries-and-filters

Fixed
-----

- fixed the handling of names when transforming luqum tree to elasticsearch queries
and added integration tests.

0.10.0

===================

Added
-----

- support for parsing Regular expressions like `/foo/` (no transformation to Elasticsearch DSL yet)
- basic support for head and tail of expressions (the separators)
and for their position (pos and size) in original text
- added `auto_head_tail` util
(use it if you build your tree programatically and want a printable representation)
- tree item now support a `clone_item` method and a setter for children.
This should help with making transformation pattern easier.
- New `visitor.TreeVisitor` and `visitor.TreeTransformer` classes to help in processing trees
`utils.LuceneTreeVisitor`, `utils.LuceneTreeVisitorV2` and `utils.LuceneTreeTransformer`
are warned as deprecated (but still works).

Changed
-------

- support for python 3.8 added, support for python 3.4 and 3.5 dropped
- better printing of Proximity and Fuzzy items (preserve implicit nature of degree)
- raise `IllegalCharacterError` on illegal character found instead of printing and skipping
- renamed `ParseError` to `ParseSyntaxError`, and kept `ParseError` as a parent exception

Fixed
-----

- Range item were not checking for bounds type on equality
- Boost item were not checking for force on equality
- Reorganize tests

Page 1 of 4

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.