This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Title: msvcrt SetErrorMode not documented
Type: enhancement Stage:
Components: Documentation, Library (Lib), Windows Versions: Python 3.10, Python 3.9, Python 3.8
Status: open Resolution:
Dependencies: Superseder:
Assigned To: docs@python Nosy List: docs@python, eryksun, giampaolo.rodola, paul.moore, steve.dower, tim.golden, zach.ware
Priority: normal Keywords:

Created on 2017-05-07 12:24 by giampaolo.rodola, last changed 2022-04-11 14:58 by admin.

Messages (2)
msg293189 - (view) Author: Giampaolo Rodola' (giampaolo.rodola) * (Python committer) Date: 2017-05-07 12:24
Also SEM_FAILCRITICALERRORS and other SEM_constants. They should as setting error mode on Windows for console applications is a pretty common use case (in fact ./Lib/test/libregrtest/ uses it).
msg293200 - (view) Author: Eryk Sun (eryksun) * (Python triager) Date: 2017-05-07 15:56
msvcrt set_error_mode, CrtReportMode, CrtReportFile and the associated CRT constants should be documented for use with debug builds. Also, msvcrt is missing the set_error_mode constants _OUT_TO_DEFAULT, _OUT_TO_STDERR, _OUT_TO_MSGBOX, and _REPORT_ERRMODE.

SetErrorMode [1] and the SEM_* constants are defined in msvcrt, for convenience I suppose. They're not related to the CRT. I think they should be aliased in the os module and documented there. GetErrorMode [2] can also be provided in Python 3.5+. It would be useful to also provide SetThreadErrorMode [3] and GetThreadErrorMode conditionally in Windows 7+, which is practically all Windows users nowadays.

Date User Action Args
2022-04-11 14:58:46adminsetgithub: 74481
2021-03-06 15:34:24eryksunsettype: enhancement
components: + Library (Lib)
versions: + Python 3.8, Python 3.9, Python 3.10, - Python 3.4, Python 3.5, Python 3.6, Python 3.7
2017-05-07 15:56:43eryksunsetnosy: + tim.golden, paul.moore, zach.ware, steve.dower
components: + Windows
2017-05-07 15:56:09eryksunsetnosy: + eryksun
messages: + msg293200
2017-05-07 12:24:20giampaolo.rodolacreate