Message244279
For Idle, the addition could be made in current versions. Idle compiles user code in the idle process and ships it to the user process for execution. In particular, idlelib.run.Executive.runcode, line 351, is
exec(code, self.locals)
Am I to presume that a) the warnings that you want to display will escape the exec call and that b) they are currently being caught at the module level and c) that the filterwarnings line or lines would do what you want if added to run.main, such as at line 104? Do warnings from python code and user code get treated the same?
Please post test cases to enter by hand, both at the prompt and in the editor, to get system warnings for 2.7 and 3.4 or 3.5. Also, please copy the positive and negative examples you posted to python-ideas. |
|
Date |
User |
Action |
Args |
2015-05-28 06:16:10 | terry.reedy | set | recipients:
+ terry.reedy, ncoghlan, ezio.melotti, njs, takluyver, martin.panter, serhiy.storchaka |
2015-05-28 06:16:10 | terry.reedy | set | messageid: <1432793770.94.0.440063211107.issue24294@psf.upfronthosting.co.za> |
2015-05-28 06:16:10 | terry.reedy | link | issue24294 messages |
2015-05-28 06:16:10 | terry.reedy | create | |
|