------------------
In this release, the ``handle_urls`` decorator gets an overhaul; it's not
required anymore to pass another Page Object class to
``handle_urls("...", overrides=...)``.
Also, the ``web_poet.field`` decorator gets support for output processing
functions, via the ``out`` argument.
Full list of changes:
* **Backwards incompatible** ``PageObjectRegistry`` is no longer supporting
dict-like access.
* Official support for Python 3.11.
* New ``web_poet.field(out=[...])`` argument which allows to set output
processing functions for web-poet fields.
* The ``web_poet.overrides`` module is deprecated and replaced with
``web_poet.rules``.
* The ``handle_urls`` decorator is now creating ``ApplyRule`` instances
instead of ``OverrideRule`` instances; ``OverrideRule`` is deprecated.
``ApplyRule`` is similar to ``OverrideRule``, but has the following differences:
* ``ApplyRule`` accepts a ``to_return`` parameter, which should be the data
container (item) class that the Page Object returns.
* Passing a string to ``for_patterns`` would auto-convert it into
``url_matcher.Patterns``.
* All arguments are now keyword-only except for ``for_patterns``.
* New signature and behavior of ``handle_urls``:
* The ``overrides`` parameter is made optional and renamed to
``instead_of``.
* If defined, the item class declared in a subclass of
``web_poet.ItemPage`` is used as the ``to_return`` parameter of
``ApplyRule``.
* Multiple ``handle_urls`` annotations are allowed.
* ``PageObjectRegistry`` is replaced with ``RulesRegistry``; its API is changed:
* **backwards incompatible** dict-like API is removed;
* **backwards incompatible** *O(1)* lookups using
``.search(use=PagObject)`` has become *O(N)*;
* ``search_overrides`` method is renamed to ``search``;
* ``get_overrides`` method is renamed to ``get_rules``;
* ``from_override_rules`` method is deprecated;
use ``RulesRegistry(rules=...)`` instead.
* Typing improvements.
* Documentation, test, and warning message improvements.
Deprecations:
* The ``web_poet.overrides`` module is deprecated. Use ``web_poet.rules`` instead.
* The ``overrides`` parameter from ``handle_urls`` is now deprecated.
Use the ``instead_of`` parameter instead.
* The ``OverrideRule`` class is now deprecated. Use ``ApplyRule`` instead.
* ``PageObjectRegistry`` is now deprecated. Use ``RulesRegistry`` instead.
* The ``from_override_rules`` method of ``PageObjectRegistry`` is now deprecated.
Use ``RulesRegistry(rules=...)`` instead.
* The ``PageObjectRegistry.get_overrides`` method is deprecated.
Use ``PageObjectRegistry.get_rules`` instead.
* The ``PageObjectRegistry.search_overrides`` method is deprecated.
Use ``PageObjectRegistry.search`` instead.