[issue14443] Distutils test_bdist_rpm failure

2012-06-26 Thread Dave Malcolm
Dave Malcolm added the comment: Fixes committed to 3.2 and default: RHEL 6.3 is now green for both branches. Closing this bug out. -- resolution: -> fixed stage: needs patch -> committed/rejected status: open -> closed ___ Python track

[issue12605] Enhancements to gdb 7 debugging hooks

2012-06-27 Thread Dave Malcolm
Dave Malcolm added the comment: I believe this was due to this line: return self._gdbframe.name().startswith('pthread_cond_timedwait') within is_waiting_for_gil(), and your gdb returned None for self._gdbframe.name() for your build. I've changed it to: name = self._gdbfra

[issue15516] exception-handling bug in PyString_Format

2012-07-31 Thread Dave Malcolm
Changes by Dave Malcolm : -- nosy: +dmalcolm ___ Python tracker <http://bugs.python.org/issue15516> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue9635] Add Py_BREAKPOINT and sys._breakpoint hooks

2012-08-01 Thread Dave Malcolm
Dave Malcolm added the comment: Note to self: a messy way of forcing gdb to do the equivalent of a breakpoint directly from Python is: os.kill(os.getpid(), signal.SIGTRAP) -- ___ Python tracker <http://bugs.python.org/issue9

[issue15540] Python 3.3 and numpy

2012-08-02 Thread Dave Malcolm
New submission from Dave Malcolm: I've been trying to get numpy working with Python 3.3, and to so I had to make some changes to CPython - hence I'm posting this to the Python bug tracker. numpy pokes at the insides of PyUnicodeObject in a few places and is thus affected by t

[issue15540] Python 3.3 and numpy

2012-08-02 Thread Dave Malcolm
Changes by Dave Malcolm : Added file: http://bugs.python.org/file26669/hack-out-test-against-MAX_UNICODE-from-cpython-3.3.patch ___ Python tracker <http://bugs.python.org/issue15

[issue15540] Python 3.3 and numpy

2012-08-02 Thread Dave Malcolm
Changes by Dave Malcolm : -- nosy: +haypo, loewis ___ Python tracker <http://bugs.python.org/issue15540> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue15540] Python 3.3 and numpy

2012-08-02 Thread Dave Malcolm
Changes by Dave Malcolm : -- nosy: +ncoghlan ___ Python tracker <http://bugs.python.org/issue15540> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue15540] Python 3.3 and numpy

2012-08-02 Thread Dave Malcolm
Changes by Dave Malcolm : -- nosy: +teoliphant ___ Python tracker <http://bugs.python.org/issue15540> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue9635] Add Py_BREAKPOINT and sys._breakpoint hooks

2012-08-07 Thread Dave Malcolm
Dave Malcolm added the comment: On Tue, 2010-11-02 at 17:25 +, Antoine Pitrou wrote: > Antoine Pitrou added the comment: > > I would rename Py_BREAKPOINT to _Py_BREAKPOINT since we don't really want to > support this. Also, why do you allow any arguments to sys._breakpoin

[issue15610] PyImport_ImportModuleEx always fails in 3.3 with "ValueError: level must be >= 0"

2012-08-09 Thread Dave Malcolm
New submission from Dave Malcolm: I've been testing various 3rd-party python code against 3.3b1, and see ValueError: level must be >= 0 exceptions where C code is using PyImport_ImportModuleEx. PyImport_ImportModuleEx reads as 63 #define PyImport_ImportModuleEx(n, g, l, f)

[issue15610] PyImport_ImportModuleEx always fails in 3.3 with "ValueError: level must be >= 0"

2012-08-09 Thread Dave Malcolm
Dave Malcolm added the comment: (FWIW, this was observed when compiling pygobject-3.3.4 against Python-3.3.0b1) -- ___ Python tracker <http://bugs.python.org/issue15

[issue15610] PyImport_ImportModuleEx always fails in 3.3 with "ValueError: level must be >= 0"

2012-08-09 Thread Dave Malcolm
Dave Malcolm added the comment: On Thu, 2012-08-09 at 21:04 +, STINNER Victor wrote: > STINNER Victor added the comment: > > Oh, I didn't realize that the documentation says that the default value is -1. > http://docs.python.org/library/functions.html#__import__ >

[issue15778] str(ImportError(b'foo')) fails

2012-08-24 Thread Dave Malcolm
New submission from Dave Malcolm: In Python 3.2 and earlier: >>> str(ImportError(b'foo')) "b'foo'" In Python 3.3: >>> str(ImportError(b'foo')) Traceback (most recent call last): File "", line 1, in TypeError: __str__ retu

[issue15778] str(ImportError(b'foo')) fails

2012-08-24 Thread Dave Malcolm
Dave Malcolm added the comment: Sorry, it's 6825fd9b00ed -- ___ Python tracker <http://bugs.python.org/issue15778> ___ ___ Python-bugs-list mailing list

[issue15778] str(ImportError(b'foo')) fails

2012-08-24 Thread Dave Malcolm
Changes by Dave Malcolm : -- keywords: +patch Added file: http://bugs.python.org/file26988/fix-str-of-bogus-ImportError.patch ___ Python tracker <http://bugs.python.org/issue15

[issue15778] str(ImportError(b'foo')) fails

2012-08-24 Thread Dave Malcolm
Dave Malcolm added the comment: (patch added) -- stage: -> patch review ___ Python tracker <http://bugs.python.org/issue15778> ___ ___ Python-bugs-list mai

[issue16191] ceval cleanup

2012-10-12 Thread Dave Malcolm
Changes by Dave Malcolm : -- nosy: +dmalcolm ___ Python tracker <http://bugs.python.org/issue16191> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue14776] Add SystemTap static markers

2014-05-19 Thread Dave Malcolm
Dave Malcolm added the comment: On Mon, 2014-05-19 at 11:10 +, Bohuslav "Slavek" Kabrda wrote: > Bohuslav "Slavek" Kabrda added the comment: > > Hi, > I'd like to take this over after Dave Malcolm. I don't see any issues that > haven't be

[issue14776] Add SystemTap static markers

2014-05-19 Thread Dave Malcolm
Dave Malcolm added the comment: On Mon, 2014-05-19 at 14:15 +, Dave Malcolm wrote: > Dave Malcolm added the comment: > > On Mon, 2014-05-19 at 11:10 +, Bohuslav "Slavek" Kabrda wrote: > > Bohuslav "Slavek" Kabrda added the comment: > > > >

[issue21590] Systemtap and DTrace support

2014-05-27 Thread Dave Malcolm
Changes by Dave Malcolm : -- nosy: +dmalcolm ___ Python tracker <http://bugs.python.org/issue21590> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue15043] test_gdb is disallowed by default security settings in Fedora 17

2012-11-29 Thread Dave Malcolm
Dave Malcolm added the comment: In my Fedora Python packages I've been applying this patch: http://pkgs.fedoraproject.org/cgit/python.git/plain/00156-gdb-autoload-safepath.patch which uses this code fragment to detect if gdb has the autoload safe path code, rather than trying to guess it

[issue16612] Integrate "Argument Clinic" specialized preprocessor into CPython trunk

2012-12-04 Thread Dave Malcolm
Changes by Dave Malcolm : -- nosy: +dmalcolm ___ Python tracker <http://bugs.python.org/issue16612> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue15516] exception-handling bug in PyString_Format

2012-12-05 Thread Dave Malcolm
Changes by Dave Malcolm : -- stage: -> patch review ___ Python tracker <http://bugs.python.org/issue15516> ___ ___ Python-bugs-list mailing list Unsubscri

[issue13390] Hunt memory allocations in addition to reference leaks

2012-12-06 Thread Dave Malcolm
Dave Malcolm added the comment: Minor bikeshedding/spelling nit: should "_Py_AllocedBlocks" be changed to "_Py_AllocatedBlocks" (and s/_Py_GetAllocedBlocks/_Py_GetAllocatedBlocks/)? -- ___ Python tracker <http://bug

[issue19743] test_gdb failures

2013-11-25 Thread Dave Malcolm
Dave Malcolm added the comment: FWIW, I feel that it's worth just expecting failures with an *optimized* build: with an optimizing compiler, there's likely to always be some program counter location where the debugger is going to get confused for some variables. Given umpteen

[issue19901] tests fail due to unsupported SO_REUSEPORT when building Python 3.3.2-r2

2013-12-05 Thread Dave Malcolm
Dave Malcolm added the comment: [FWIW, this looks similar to an issue I ran into on Fedora: https://bugzilla.redhat.com/show_bug.cgi?id=913732 which was due to a mismatch between the kernel headers on the system vs the actually running kernel. I patched around it there with a downstream-only

[issue20162] Test test_hash_distribution fails on RHEL 6.5 / ppc64

2014-01-07 Thread Dave Malcolm
Dave Malcolm added the comment: On Tue, 2014-01-07 at 16:30 +, Yury V. Zaytsev wrote: > Yury V. Zaytsev added the comment: > > After lots of fiddling, I can tell you what's wrong with the macro: > apparently it's a compiler bug, visible at -O2 and disappearing at -O1

[issue6508] expose setresuid

2009-09-16 Thread Dave Malcolm
Dave Malcolm added the comment: > I cannot test this in my current environment because I'm stuck with Red > Hat and it does not have a recent enough automake to re-create configure > from configure.in. FWIW, it may be an _autoconf_ version issue; I'm able to recreate

[issue4111] Add DTrace probes

2009-09-18 Thread Dave Malcolm
Changes by Dave Malcolm : -- nosy: +dmalcolm ___ Python tracker <http://bugs.python.org/issue4111> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue5753] CVE-2008-5983 python: untrusted python modules search path

2009-10-16 Thread Dave Malcolm
Changes by Dave Malcolm : -- nosy: +dmalcolm ___ Python tracker <http://bugs.python.org/issue5753> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue1068268] subprocess is not EINTR-safe

2009-10-16 Thread Dave Malcolm
Changes by Dave Malcolm : -- nosy: +dmalcolm ___ Python tracker <http://bugs.python.org/issue1068268> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue4216] subprocess.Popen hangs at communicate() when child exits

2009-10-16 Thread Dave Malcolm
Changes by Dave Malcolm : -- nosy: +dmalcolm ___ Python tracker <http://bugs.python.org/issue4216> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue7187] importlib/_bootstrap.py write_bytecode fails if it can't open the .pyc file for writing

2009-10-22 Thread Dave Malcolm
New submission from Dave Malcolm : I'm working on an RPM package of Python 3.1.1 for Fedora [1]. Within my RPMs are precompiled .pyc and .pyo files that are not writable by users, and are hardlinked together if they have equal content. For example: $ ls -al /usr/lib/python3.1/tk

[issue7187] importlib/_bootstrap.py write_bytecode raises an IOError if it can't open the .pyc file for writing

2009-10-22 Thread Dave Malcolm
Changes by Dave Malcolm : -- title: importlib/_bootstrap.py write_bytecode fails if it can't open the .pyc file for writing -> importlib/_bootstrap.py write_bytecode raises an IOError if it can't open the .pyc file for writing ___ P

[issue7187] importlib/_bootstrap.py write_bytecode raises an IOError if it can't open the .pyc file for writing

2009-10-23 Thread Dave Malcolm
Dave Malcolm added the comment: Aha! Thanks pitrou, looks like I managed to mess up my packaging (I was wondering why no no-one else had run into this, looks like no-one else made this mistake!). -- ___ Python tracker <http://bugs.python.

[issue4359] at runtime, distutils uses buildtime files

2009-10-30 Thread Dave Malcolm
Dave Malcolm added the comment: For Fedora, I've fixed this (I hope) by special-casing those two files: %{_libdir}/python%{pybasever}/config/Makefile /usr/include/python2.6/pyconfig-{32|64}.h making them part of the core python package. See downstream bug here: https://bugzilla.redha

[issue4359] at runtime, distutils uses buildtime files

2009-10-30 Thread Dave Malcolm
Dave Malcolm added the comment: > For Fedora, I've fixed this (I hope) by special-casing those two files: Sorry; for "fixed", read "addressed"; this covers part 1 of the issue, but not part 2. -- ___ Python trac

[issue2422] Automatically disable pymalloc when running under valgrind

2009-11-10 Thread Dave Malcolm
Changes by Dave Malcolm : -- nosy: +dmalcolm ___ Python tracker <http://bugs.python.org/issue2422> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue7353] Why was Include/intobject.h removed in 3.1?

2009-11-18 Thread Dave Malcolm
New submission from Dave Malcolm : I'm attempting to package Python 3 for a Linux distribution, together with a stack of python extension modules; I'm currently using Python-3.1.1. (see https://fedoraproject.org/wiki/Features/Python3F13 ) Many of these extension modules ar

[issue1169193] Handle ungzipped man pages in rpm builds correctly

2009-11-22 Thread Dave Malcolm
Changes by Dave Malcolm : -- nosy: +dmalcolm ___ Python tracker <http://bugs.python.org/issue1169193> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue1448060] gettext.py breaks on plural-forms header (PATCH)

2009-12-02 Thread Dave Malcolm
Changes by Dave Malcolm : -- nosy: +dmalcolm ___ Python tracker <http://bugs.python.org/issue1448060> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue7425] [PATCH] Improve the robustness of "pydoc -k" in the face of broken modules

2009-12-02 Thread Dave Malcolm
New submission from Dave Malcolm : I see occasional failures where a broken module prevents "pydoc -k" ("apropos") from working. Examples of failures (from our downstream bug tracker) are: https://bugzilla.redhat.com/show_bug.cgi?id=461419 : "pydoc -k&

[issue7543] RFE: introduce "enum Py_Opcode"

2009-12-18 Thread Dave Malcolm
New submission from Dave Malcolm : Currently, Python's opcodes are defined as preprocessor #defines. This means that they are invisible to the debugger. I'm attaching: (i) a simple script (fixup-opcode-header.py) which converts Include/opcode.h to use an anonymous enum for

[issue7543] RFE: introduce "enum Py_Opcode"

2009-12-18 Thread Dave Malcolm
Changes by Dave Malcolm : Added file: http://bugs.python.org/file15598/fixup-opcode-header.py ___ Python tracker <http://bugs.python.org/issue7543> ___ ___ Python-bug

[issue7543] RFE: introduce "enum Py_Opcode"

2009-12-18 Thread Dave Malcolm
Changes by Dave Malcolm : Added file: http://bugs.python.org/file15599/opcode.h ___ Python tracker <http://bugs.python.org/issue7543> ___ ___ Python-bugs-list mailin

[issue7543] RFE: introduce "enum Py_Opcode"

2009-12-18 Thread Dave Malcolm
Changes by Dave Malcolm : -- keywords: +patch Added file: http://bugs.python.org/file15600/opcode.h.patch ___ Python tracker <http://bugs.python.org/issue7

[issue7543] RFE: introduce "enum Py_Opcode"

2009-12-18 Thread Dave Malcolm
Changes by Dave Malcolm : Added file: http://bugs.python.org/file15601/use-opcode-enum.patch ___ Python tracker <http://bugs.python.org/issue7543> ___ ___ Python-bug

[issue7543] RFE: introduce "enum Py_Opcode"

2009-12-18 Thread Dave Malcolm
Dave Malcolm added the comment: Ooops, sorry; in an earlier version of this work, I was generating an enum of the form: enum { }; i.e. without an identifier (an anonymous enum) which I later changed to: enum Py_Opcode { }; Mea culpa; I forgot to update the text for this bug when I

[issue7543] RFE: introduce "enum Py_Opcode"

2009-12-18 Thread Dave Malcolm
Changes by Dave Malcolm : Added file: http://bugs.python.org/file15602/diff-in-generated-assembler-for-ceval.diff ___ Python tracker <http://bugs.python.org/issue7

[issue7543] RFE: introduce "enum Py_Opcode"

2009-12-19 Thread Dave Malcolm
Dave Malcolm added the comment: > Are you doing anything specific which requires this change? No. I was looking for ways of making CPython easier to debug, and I experimented with this. It didn't help with debuggability as much as I hoped. Given that CPython's performance i

[issue7647] Add statvfs flags to the posix module

2010-01-06 Thread Dave Malcolm
Changes by Dave Malcolm : -- nosy: +dmalcolm ___ Python tracker <http://bugs.python.org/issue7647> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue6690] BUILD_SET followed by COMPARE_OP (in) can be optimized if all items are consts

2010-01-12 Thread Dave Malcolm
Dave Malcolm added the comment: Attaching a probably over-simplistic attempt at this patch, against the py3k branch. This patch attempts to extend the replacement of LOAD_CONST, , LOAD_CONST, BUILD_LIST, COMPARE_OP(in) with LOAD_CONST(tuple), COMPAREOP(in) so that it also replaces

[issue6690] BUILD_SET followed by COMPARE_OP (in) can be optimized if all items are consts

2010-01-12 Thread Dave Malcolm
Dave Malcolm added the comment: Alex: good point - thanks! Attaching updated version of the patch (again, against py3k, likewise, I'm somewhat new to this code, so I may have missed things) With this: >>> dis.dis(lambda o: o in {1,2,3}) 1 0 LOAD_FAST

[issue6690] BUILD_SET followed by COMPARE_OP (in) can be optimized if all items are consts

2010-01-12 Thread Dave Malcolm
Dave Malcolm added the comment: Thanks for looking at the patch. Attached is an updated version (again against py3k) which adds tests to Lib/test/test_peepholer.py, for both the new folding away of BUILD_SET, and for the pre-existing folding of BUILD_LIST (which didn't seem to have

[issue1634034] Show "expected" token on syntax error

2010-01-13 Thread Dave Malcolm
Dave Malcolm added the comment: I'm attaching a new version of the patch, based on Oliver's (from 3 years ago). This patch is against the py3k branch. I've introduced a new table of (const) strings: _PyParser_TokenDescs, giving descriptions of each token type, so t

[issue4555] Smelly exports

2010-01-13 Thread Dave Malcolm
Dave Malcolm added the comment: Re: msg #77350: > I propose to simply filter out init[_a-z]+ from the set of "bad" > symbols. I'm attaching a patch (to trunk) to Makefile.pre.in which filters out such symbols. Relevant part of output of "make smelly" on my s

[issue6690] BUILD_SET followed by COMPARE_OP (in) can be optimized if all items are consts

2010-01-15 Thread Dave Malcolm
Dave Malcolm added the comment: Thanks for the suggestions. Attached is a revised version of the patch. - I believe I've fixed all tab/space issues in this version of the patch, though I may have missed some (http://www.python.org/dev/tools/ doesn't recommend an automated way o

[issue5753] CVE-2008-5983 python: untrusted python modules search path

2010-05-17 Thread Dave Malcolm
Dave Malcolm added the comment: Attempting to summarize IRC discussion about this. PySys_SetArgv is used to set up sys.argv There is plenty of code which assumes that this is a list containing at least a zeroth string element; for example warnings.warn (see msg89688). It seems reasonable

[issue1621] Do not assume signed integer overflow behavior

2010-05-21 Thread Dave Malcolm
Changes by Dave Malcolm : -- nosy: +dmalcolm ___ Python tracker <http://bugs.python.org/issue1621> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue8892] 2to3 fails with assertion failure on "from itertools import *"

2010-06-03 Thread Dave Malcolm
New submission from Dave Malcolm : fix_itertools_imports.py fails on a "*" import 2to3 fails on this code: from itertools import * with a traceback: File "/home/david/coding/python-svn/trunk-2to3-issues/Lib/lib2to3/tests/test_fixers.py", line 3680, in test_star

[issue8892] 2to3 fails with assertion failure on "from itertools import *"

2010-06-03 Thread Dave Malcolm
Dave Malcolm added the comment: I'm attaching a reproducer for the test suite (though not a fix) -- keywords: +patch Added file: http://bugs.python.org/file17540/itertools_import_star_reproducer.patch ___ Python tracker <http://bugs.py

[issue9054] pyexpat configured with "--with-system-expat" is incompatible with expat 2.0.1

2010-06-21 Thread Dave Malcolm
New submission from Dave Malcolm : pyexpat configured with "--with-system-expat" segfaults in one selftest when built against expat 2.0.1 SVN trunk: $ ./configure --with-system-expat (with expat-2.0.1) $ make $ ./python Lib/test/test_pyexpat.py [snip] test_parse_only_xml_data

[issue9054] pyexpat configured with "--with-system-expat" is incompatible with expat 2.0.1

2010-06-21 Thread Dave Malcolm
Dave Malcolm added the comment: With the attached patch all of Lib/test/test_pyexpat.py passes. -- keywords: +patch Added file: http://bugs.python.org/file17734/fix-issue-9054.patch ___ Python tracker <http://bugs.python.org/issue9

[issue9054] pyexpat configured with "--with-system-expat" is incompatible with expat 2.0.1

2010-06-21 Thread Dave Malcolm
Changes by Dave Malcolm : -- stage: -> patch review type: -> crash versions: +Python 2.7 ___ Python tracker <http://bugs.python.org/issue9054> ___ ___ Pyth

[issue9054] pyexpat configured with "--with-system-expat" is incompatible with expat 2.0.1

2010-06-21 Thread Dave Malcolm
Dave Malcolm added the comment: For reference, I'm tracking this downstream here: https://bugzilla.redhat.com/show_bug.cgi?id=583931 -- ___ Python tracker <http://bugs.python.org/i

[issue9058] PyUnicodeDecodeError_Create asserts that various arguments are less than INT_MAX

2010-06-22 Thread Dave Malcolm
New submission from Dave Malcolm : Running this code (seen via http://bugs.python.org/file10013/python-2.5.2-unicode_resize-utf16.py for issue 2620): >>> msg = 'A'*2147483647 ; msg.decode('utf16') leads to the python process exiting with an assertion failure: pyth

[issue9058] PyUnicodeDecodeError_Create asserts that various arguments are less than INT_MAX

2010-06-22 Thread Dave Malcolm
Dave Malcolm added the comment: Patch to remove the restriction that the fields be < INT_MAX Tested on x86_64 on a machine with > 12GB of RAM, leads to this exception, rather than the python process bailing out: Traceback (most recent call last): File "", line 1, in Fil

[issue9058] PyUnicodeDecodeError_Create asserts that various arguments are less than INT_MAX

2010-06-22 Thread Dave Malcolm
Dave Malcolm added the comment: >>> Actually, you should be able to just remove the asserts. Aha, thanks! Yes: #define PY_SSIZE_T_CLEAN is defined at the top of Objects/exceptions.c, so yes, Py_VaBuildValue is redirected to _Py_VaBuildValue_SizeT, so that PyEval_CallFunct

[issue5673] Add timeout option to subprocess.Popen

2010-07-01 Thread Dave Malcolm
Dave Malcolm added the comment: The patch has bitrotted somewhat; I've had a go at reworking it so it applies against the latest version of trunk (r82429). All tests pass (or are skipped) on this x86_64 Linux box --with-pydebug (Fedora 13) There are still some TODOs in the code: Popen

[issue9146] Segfault in hashlib in OpenSSL FIPS mode using non-FIPS-compliant hashes, if "ssl" imported before "hashlib"

2010-07-02 Thread Dave Malcolm
New submission from Dave Malcolm : Having run: prelink --undo --all the following works OK: OPENSSL_FORCE_FIPS_MODE=1 python -c "import hashlib; m = m = hashlib.md5(); m.update('abc')" but the following segfaults: OPENSSL_FORCE_FIPS_MODE=1 python -c "import s

[issue9146] Segfault in hashlib in OpenSSL FIPS mode using non-FIPS-compliant hashes, if "ssl" imported before "hashlib"

2010-07-02 Thread Dave Malcolm
Dave Malcolm added the comment: Thanks > First, is it only with 2.7 or 2.6? I've seen this with both 2.6 tarball builds and SVN trunk; in both cases against openssl-1.0.0-1.[ > Second, I don't really get the point of the FIPS mode. The PDF you linked to > seems full of

[issue9146] Segfault in hashlib in OpenSSL FIPS mode using non-FIPS-compliant hashes, if "ssl" imported before "hashlib"

2010-07-02 Thread Dave Malcolm
Dave Malcolm added the comment: Attached patch checks for errors in the initialization of _hashlib, and only registers the names that are actually available. It also contains the ssl init from the first patch. I added a _hashlib._errors dict, containing errors, so that you can examine them

[issue9146] Segfault in hashlib in OpenSSL FIPS mode using non-FIPS-compliant hashes, if "ssl" imported before "hashlib"

2010-07-02 Thread Dave Malcolm
Dave Malcolm added the comment: Not quite ready yet: Named methods work: $ OPENSSL_FORCE_FIPS_MODE=1 ./python -c "import hashlib; m = hashlib.md5(); m.update('abc\n'); print m.hexdigest()"0bee89b07a248e27c83fc3d5951213c1 [15741 refs] but lookup by name still fails: OPENS

[issue9146] Segfault in hashlib in OpenSSL FIPS mode using non-FIPS-compliant hashes, if "ssl" imported before "hashlib"

2010-07-06 Thread Dave Malcolm
Dave Malcolm added the comment: I'm attaching an updated patch which: - adds error checking to the various places where EVP_DigestInit is called - adds a test to test_hashlib to ensure that hashlib still works gracefully when OPENSSL_FORCE_FIPS_MODE=1 is set in the environment Note

[issue9163] test_gdb fails

2010-07-06 Thread Dave Malcolm
Dave Malcolm added the comment: Deciphering the output from the assertion, the stdout from gdb when running the test was: --- BEGIN --- Breakpoint 1, PyObject_Print (op=42, fp=0x401cf4e0, flags=1) at Objects/object.c:329 329 { #3 Frame 0x81e322c, for file /home/mike/workspace/Python-2.7

[issue8605] test_gdb can fail with compiler opts

2010-07-06 Thread Dave Malcolm
Dave Malcolm added the comment: Thanks. The patch looks good to me, and appears to also fix issue 8482 and issue 9163: compiler optimization across all different compilers and configurations can somewhat arbitrarily break the ability for the debugger to work, and skipping the test in the

[issue9163] test_gdb fails

2010-07-06 Thread Dave Malcolm
Dave Malcolm added the comment: Thanks. Just to clarify, what's the output of: ./python -c "import sysconfig; print sysconfig.get_config_vars()['PY_CFLAGS']" -- ___ Python tracker <http

[issue9163] test_gdb fails

2010-07-06 Thread Dave Malcolm
Dave Malcolm added the comment: Thanks for the info. The final optimization option passed to gcc is the "-O3", so the build was done with optimization. It's not going to be possible to determine if and when gdb will be able to work in an optimized build across all differen

[issue8605] test_gdb can fail with compiler opts

2010-07-07 Thread Dave Malcolm
Dave Malcolm added the comment: Oops, my bad. Patch looks good as is. -- ___ Python tracker <http://bugs.python.org/issue8605> ___ ___ Python-bugs-list mailin

[issue9146] Segfault in hashlib in OpenSSL FIPS mode using non-FIPS-compliant hashes, if "ssl" imported before "hashlib"

2010-07-07 Thread Dave Malcolm
Dave Malcolm added the comment: Thanks. The relevant code in setup.py is all wrapped with --pydebug: if COMPILED_WITH_PYDEBUG or not have_usable_openssl: All of my testing had been --with-pydebug. Rebuilding without --with-pydebug leads to some interesting failures; as you say, if

[issue9188] test_gdb fails for UCS2 builds with UCS2 gdb

2010-07-07 Thread Dave Malcolm
Dave Malcolm added the comment: The traceback is Traceback (most recent call last): File "/home/antoine/cpython/27/python-gdb.py", line 1084, in to_string return pyop.get_truncated_repr(MAX_OUTPUT_LEN) File "/home/antoine/cpython/27/python-gdb.py", line 183, i

[issue9193] Versioned .so files

2010-07-07 Thread Dave Malcolm
Changes by Dave Malcolm : -- nosy: +dmalcolm ___ Python tracker <http://bugs.python.org/issue9193> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue8482] test_gdb, gdb/libpython.py: Unable to read information on python frame

2010-07-08 Thread Dave Malcolm
Dave Malcolm added the comment: > test_gdb fails (Unable to read information on python frame) on my i386 > computer (32 bits) with -O1 (but it doesn't with -O0). I'm using Debian > Sid: gcc 4.4.3 and gdb 7.1. This should be fixed now that issue 8605 is resolved: we now sk

[issue9163] test_gdb fails

2010-07-08 Thread Dave Malcolm
Dave Malcolm added the comment: This should be fixed now that issue 8605 is resolved: we now skip test_gdb if the compiler optimization level is above -O0 -- resolution: -> fixed stage: -> committed/rejected ___ Python tracker

[issue9163] test_gdb fails

2010-07-08 Thread Dave Malcolm
Changes by Dave Malcolm : -- status: open -> closed ___ Python tracker <http://bugs.python.org/issue9163> ___ ___ Python-bugs-list mailing list Unsubscri

[issue8482] test_gdb, gdb/libpython.py: Unable to read information on python frame

2010-07-08 Thread Dave Malcolm
Changes by Dave Malcolm : -- status: open -> closed ___ Python tracker <http://bugs.python.org/issue8482> ___ ___ Python-bugs-list mailing list Unsubscri

[issue9216] FIPS support for hashlib

2010-07-09 Thread Dave Malcolm
New submission from Dave Malcolm : (taking the liberty of adding gregory.p.smith to the "nosy" list; hope that's OK) This is a higher-level take on issue 9146. Some versions of OpenSSL have a FIPS mode that can refuse the use of non-certified hashes. The idea is that F

[issue9146] Segfault in hashlib in OpenSSL FIPS mode using non-FIPS-compliant hashes, if "ssl" imported before "hashlib"

2010-07-09 Thread Dave Malcolm
Dave Malcolm added the comment: I've filed issue 9216 to discuss this at a higher level, with an API proposal -- ___ Python tracker <http://bugs.python.org/i

[issue9216] FIPS support for hashlib

2010-07-12 Thread Dave Malcolm
Dave Malcolm added the comment: Attached is a patch against the py3k branch which implements this. I've checked that it builds against openssl-0.9.8o.tar.gz, openssl-1.0.0a.tar.gz, and against Fedora 12 and 13's heavily-patched openssl-1.0.0. The bulk of my testing has been agains

[issue9235] missing "import sys" in Tools/gdb/libpython.py

2010-07-12 Thread Dave Malcolm
Changes by Dave Malcolm : -- nosy: +dmalcolm ___ Python tracker <http://bugs.python.org/issue9235> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue9263] Try to print repr() when an C-level assert fails (in the garbage collector, beyond?)

2010-07-14 Thread Dave Malcolm
New submission from Dave Malcolm : Modules/gcmodule.c contains various assertions which can fail due to reference counting errors elsewhere in either python, or an extension module. These can be difficult to track down. In the hope of maximizing the information from crash reports, the

[issue2454] sha and md5 fixer

2010-07-19 Thread Dave Malcolm
Dave Malcolm added the comment: The 'u' prefix went away in Python 3, use an unadorned '' or "" for a unicode value. $ python3 Python 3.1.2 (r312:79147, May 25 2010, 12:21:57) [GCC 4.4.3 20100422 (Red Hat 4.4.3-18)] on linux2 Type "help", &quo

[issue4555] Smelly exports

2010-07-20 Thread Dave Malcolm
Dave Malcolm added the comment: py3k is much cleaner than python 2, due to the change in the module API. Here's "make smelly"'s output on a recent py3k checkout: nm -p libpython3.2.a | \ sed -n "/ [TDB] /s/.* //p" | grep -v "^_*Py

[issue4555] Smelly exports (global symbols in python not prefixed with Py or _Py)

2010-07-20 Thread Dave Malcolm
Dave Malcolm added the comment: Patch to py3k which adds the "_Py" prefix to the four listed symbols. With this, the output from "make smelly" is clean (odorless, perhaps?). However, adding _Py does seem to go against this comment in Include/asdl.h: /* It would be nice i

[issue8912] `make patchcheck` should check the whitespace of .c/.h files

2010-07-21 Thread Dave Malcolm
Changes by Dave Malcolm : -- nosy: +dmalcolm ___ Python tracker <http://bugs.python.org/issue8912> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue9259] Python 2.7 breaks assigned __exit__s

2010-07-26 Thread Dave Malcolm
Changes by Dave Malcolm : -- nosy: +dmalcolm ___ Python tracker <http://bugs.python.org/issue9259> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue9386] Bad indentation in urllib import fixer with multipe imports

2010-07-26 Thread Dave Malcolm
New submission from Dave Malcolm : Running 2to3 on lxml-2.2.6 failed with broken indentation. This fragment from lxml/html/__init__.py: > def open_http_urllib(method, url, values): > ## FIXME: should test that it's not a relative URL or something > try: >f

[issue9386] Bad indentation in urllib import fixer with multiple imports

2010-07-26 Thread Dave Malcolm
Changes by Dave Malcolm : -- title: Bad indentation in urllib import fixer with multipe imports -> Bad indentation in urllib import fixer with multiple imports ___ Python tracker <http://bugs.python.org/iss

[issue5504] ctypes should work with systems where mmap can't be PROT_WRITE and PROT_EXEC

2010-07-28 Thread Dave Malcolm
Dave Malcolm added the comment: FWIW, the patch for this that I'm currently applying to Fedora's python 2.7 rpms can be seen at: http://cvs.fedoraproject.org/viewvc/devel/python/python-2.7rc1-ctypes-noexecmem.patch?revision=1.1&content-type=text%2Fplain&view=co It doesn&#x

<    1   2   3   4   5   >