1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133
|
Deprecated Features
===================
As features are deprecated and cleaned up, they are documented
here with steps to update your configuration for replacements.
``networkidle0`` and ``networkidle2`` for ``wait_until`` in browser jobs (since 2.28)
-------------------------------------------------------------------------------------
Since version 2.28, execution of browser jobs uses Playwright instead of pyppetteer.
The previously-supported ``wait_until`` values of ``networkidle0`` and ``networkidle2``
are not supported anymore. Playwright supports the values ``load``, ``domcontentloaded``,
``networkidle`` (discouraged) or ``commit`` instead.
Existing settings of ``networkidle0`` and ``networkidle2`` will be mapped to
``networkidle``, and a warning will be issued. To silence the warning and continue
to use ``networkidle``, specify ``wait_until: networkidle`` explicitly.
Filters without subfilters (since 2.22)
---------------------------------------
In older urlwatch versions, it was possible to write custom
filters that do not take a ``subfilter`` as argument.
If you have written your own filter code like this:
.. code:: python
class CustomFilter(filters.FilterBase):
"""My old custom filter"""
__kind__ = 'foo'
def filter(self, data):
...
You have to update your filter to take an optional subfilter
argument (if the filter configuration does not have a subfilter
defined, the value of ``subfilter`` will be ``None``):
.. code:: python
class CustomFilter(filters.FilterBase):
"""My new custom filter"""
__kind__ = 'foo'
def filter(self, data, subfilter):
...
string-based filter definitions (since 2.19)
--------------------------------------------
With urlwatch 2.19, string-based filter lists are deprecated,
because they are not as flexible as dict-based filter lists
and had some problems (e.g. ``:`` and ``,`` are treated in a
special way and cannot be used in subfilters easily).
If you have a filter definition like this:
.. code:: yaml
filter: css:body,html2text:re,strip
You can get the same results with a filter definition like this:
.. code:: yaml
filter:
- css:
selector: body
- html2text:
method: re
- strip
Since ``selector`` is the default subfilter for ``css``, and ``method``
is the default subfilter for ``html2text``, this can also be written as:
.. code:: yaml
filter:
- css: body
- html2text: re
- strip
If you just have a single filter such as:
.. code:: yaml
filter: html2text
You can change this filter to dict-based using:
.. code:: yaml
filter:
- html2text
keyring setting in SMTP reporter configuration (since 2.18)
-----------------------------------------------------------
Since version 2.18, the SMTP reporter configuration now uses ``auth``
to decide if SMTP authentication should be done or not. Previously,
this setting was called ``keyring``. If you have an old configuration
like this:
.. code:: yaml
report:
email:
smtp:
host: localhost
keyring: false
port: 25
starttls: true
subject: '{count} changes: {jobs}'
You can change the setting to this (replace ``keyring`` with ``auth``):
.. code:: yaml
report:
email:
smtp:
host: localhost
auth: false
port: 25
starttls: true
subject: '{count} changes: {jobs}'
|