Message98796
Currently this context manager is used in 3 different situations:
- to silence standard warnings
- to record warnings in a list, in order to verify them
- to silence py3k warnings
But it does not accept any parameter, and it does not *check* if the filter is obsolete. It silence *all* warnings, blindly.
I would like to propose an enhancement of this function, which accepts a list of filters as parameters, and which verifies that there's really something to catch.
An optional boolean argument "lazy" can be used to disable the check.
check_warnings([filter[, ...[, lazy=False]]])
Additionnally, a sister function will filter only the py3k warnings:
check_py3k_warnings([filter[, ...[, lazy=False]]])
See the patch and its docstring for details.
Note: this context manager could be used to fix the last part of #7092 |
|
Date |
User |
Action |
Args |
2010-02-03 20:02:32 | flox | set | recipients:
+ flox, ezio.melotti |
2010-02-03 20:02:32 | flox | set | messageid: <1265227352.4.0.15322999222.issue7849@psf.upfronthosting.co.za> |
2010-02-03 20:02:30 | flox | link | issue7849 messages |
2010-02-03 20:02:29 | flox | create | |
|