Issue 5116: expose _CrtSetReportMode via the msvcrt module (original) (raw)

Created on 2009-01-31 06:52 by mhammond, last changed 2022-04-11 14:56 by admin. This issue is now closed.

Files
File name Uploaded Description Edit
msvcrt_crtsetreportmode.patch mhammond,2009-01-31 06:52 Adds msvcrt.SetCrtReportMode()
Messages (4)
msg80858 - (view) Author: Mark Hammond (mhammond) * (Python committer) Date: 2009-01-31 06:52
In bug 4804, there is some debate about how desirable it is for Python to unconditionally disable all CRT assertions on Windows - however, there is agreement that exposing the ability to enable and disable these assertions via the msvcrt module is reasonable - so I'm attaching a patch for exactly that. I'd also like to nominate this for the 2.6 and py3k branches.
msg96830 - (view) Author: Brian Curtin (brian.curtin) * (Python committer) Date: 2009-12-23 02:27
Has there been any consensus about what to do with this? I know there was some chatter on python-dev about assertions causing problems with buildbots (6 months ago?) but I don't think anything came out of it. The code change is small and looks good. Is it worth extending this to expose CrtSetReportFile since a file is one of the options of CrtSetReportMode?
msg96894 - (view) Author: Amaury Forgeot d'Arc (amaury.forgeotdarc) * (Python committer) Date: 2009-12-26 22:03
_CrtSetReportMode() is exposed without the leading underscore. IMO the _CRT_WARN and other constants should be renamed the same way.
msg97015 - (view) Author: Brian Curtin (brian.curtin) * (Python committer) Date: 2009-12-30 00:14
I just noticed that this already exists in py3k, added in r57823 (lacks docs but I'll cover them in the py3k fix for #7579)
History
Date User Action Args
2022-04-11 14:56:45 admin set github: 49366
2010-07-10 23:00:29 terry.reedy set status: open -> closedresolution: out of date
2010-01-13 03:00:26 brian.curtin set keywords: + 26backport, - patch, patch, needs reviewstage: needs patchversions: - Python 3.0, Python 3.1
2009-12-30 00:14:29 brian.curtin set messages: +
2009-12-26 22:03:11 amaury.forgeotdarc set keywords:patch, patch, needs reviewnosy: + amaury.forgeotdarcmessages: +
2009-12-23 02:27:15 brian.curtin set nosy: + brian.curtinmessages: +
2009-01-31 06:53:20 mhammond set keywords:patch, patch, needs reviewcomponents: + Windows
2009-01-31 06:52:53 mhammond create