diff options
| author | Xavier Morel <xmo@odoo.com> | 2020-10-14 13:04:53 +0000 |
|---|---|---|
| committer | Xavier Morel <xmo@odoo.com> | 2020-10-14 13:35:36 +0000 |
| commit | 6b04dbcd4204a75d6bd68fc0b3010a2297779b32 (patch) | |
| tree | 7c5f61f811ff4d4ef83b087e9919a93db846dca5 /addons/website_slides/static/src/components/activity/activity_tests.js | |
| parent | 12030dde4fcc63b6bcb037084c21c24b23a91ff4 (diff) | |
[FIX] core: PyPDF2 suppresses warnings
By default, PdfFileReader will monkeypatch the `warnings` module even
if it has no reason whatsoever to do so and suppress the
`captureWarnings` behavior.
This means as soon as we've loaded a PDF file, `warnings.warn` don't
trigger `logging` warnings anymore, and become invisible.
This can lead to non-deterministic behaviors depending as warnings may
or may not be suppressed depending when they occur relative to loading
a PDF e.g. load a module which runs a test which loads a PDF before a
module triggering a warning and the warning won't be visible, other
way around it will.
Except ofc while we have an override to PdfFileReader it's not
used *everywhere*, so need to monkeypatch the init.
closes odoo/odoo#60002
Signed-off-by: Xavier Morel (xmo) <xmo@odoo.com>
Diffstat (limited to 'addons/website_slides/static/src/components/activity/activity_tests.js')
0 files changed, 0 insertions, 0 deletions
