[issue14119] Ability to adjust queue size in Executors
Victor Varvariuc added the comment: Maybe I should have created another issue for this, but without this issue being solved, the new issue will not help much. Here it is: http://hg.python.org/cpython/file/37caaf21f827/Lib/concurrent/futures/thread.py#l63 After running an work item `work_queue.task_done()` is not called. So it's difficult to know if worker threads have any more work to do. http://stackoverflow.com/questions/20965754/determine-if-worker-threads-are-doing-any-work?noredirect=1#comment31495804_20965754 -- nosy: +Victor.Varvariuc ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14119 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20157] Argument Clinic generates wrong keyword parameter name for default
New submission from Serhiy Storchaka: For the default keyword parameter Argument Clinic generates wrong name default_value in the _keywords array. /*[clinic] module spam spam.ham default: int = 1 [clinic]*/ ... static PyObject * spam_ham(PyModuleDef *module, PyObject *args, PyObject *kwargs) { PyObject *return_value = NULL; static char *_keywords[] = {default_value, NULL}; int default_value = 1; if (!PyArg_ParseTupleAndKeywords(args, kwargs, |i:ham, _keywords, default_value)) goto exit; ... -- components: Build files: spammodule.c messages: 207513 nosy: larry, serhiy.storchaka priority: release blocker severity: normal stage: needs patch status: open title: Argument Clinic generates wrong keyword parameter name for default type: behavior versions: Python 3.4 Added file: http://bugs.python.org/file7/spammodule.c ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20157 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue19081] zipimport behaves badly when the zip file changes while the process is running
Roundup Robot added the comment: New changeset e09644eb6b20 by Gregory P. Smith in branch '2.7': Should fix the issue19081 fix on Windows. Don't let the previous http://hg.python.org/cpython/rev/e09644eb6b20 -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19081 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20158] Argument Clinic: add --clean option
New submission from Serhiy Storchaka: It will be helpful to add the --clean option for the clinic tool, which removes all Argument Clinic generated code. -- messages: 207515 nosy: larry, serhiy.storchaka priority: normal severity: normal status: open title: Argument Clinic: add --clean option type: enhancement ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20158 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20158] Argument Clinic: add --clean option
Larry Hastings added the comment: When would you want this? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20158 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20157] Argument Clinic generates wrong keyword parameter name for default
Larry Hastings added the comment: I'll fix this but it's low priority for today. It's not a release blocker; we could release Python 3.4 with this bug. -- assignee: - larry priority: release blocker - normal ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20157 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20159] Convert the ElementTree module to use Argument Clinic
New submission from Serhiy Storchaka: Here is a patch which converts xml.etree.ElementTree accelerator module to use Argument Clinic. 34 methods are converted. Not converted __init__ methods (is Argument Clinic support it?) and the SubElement function which seems can't be converted. -- components: Extension Modules, XML files: etree_clinic.patch keywords: patch messages: 207518 nosy: eli.bendersky, larry, scoder, serhiy.storchaka priority: normal severity: normal stage: patch review status: open title: Convert the ElementTree module to use Argument Clinic type: enhancement versions: Python 3.4 Added file: http://bugs.python.org/file8/etree_clinic.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20159 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20159] Convert the ElementTree module to use Argument Clinic
Changes by Serhiy Storchaka storch...@gmail.com: -- dependencies: +Argument Clinic generates wrong keyword parameter name for default, Argument Clinic: broken support for 'O!' ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20159 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue19081] zipimport behaves badly when the zip file changes while the process is running
Gregory P. Smith added the comment: updated 3.3 patch based off the changes made to the 2.7 one. -- Added file: http://bugs.python.org/file9/issue19081-33-gps05.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19081 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue19081] zipimport behaves badly when the zip file changes while the process is running
Changes by Gregory P. Smith g...@krypto.org: Removed file: http://bugs.python.org/file33323/issue19081-33-gps04.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19081 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20160] broken ctypes calling convention on MSVC / 64-bit Windows (large structs)
New submission from Mark Dickinson: The argument-passing code for passing structs larger than 8 bytes is broken on 64-bit Windows, leading to potential segmentation faults or other unpredictable behaviour. According to http://msdn.microsoft.com/en-us/library/zthk2dkh.aspx structs not of size 1, 2, 4 or 8 bytes should be passed by pointer. ctypes instead puts sizeof(struct) bytes onto the stack. The offending code is in ffi_prep_args in /Modules/_ctypes/libffi_msvc/ffi.c, which apparently hasn't been kept up to date with the /Modules/_ctypes/libffi/src/x86/ffi.c. The latter module works correctly: it has an extra #ifdef X86_WIN64 block (shown below) to take care of structs not of size 1, 2, 4 or 8. That block is missing in the libffi_msvc version. z = (*p_arg)-size; #ifdef X86_WIN64 if (z sizeof(ffi_arg) || ((*p_arg)-type == FFI_TYPE_STRUCT (z != 1 z != 2 z != 4 z != 8)) #if FFI_TYPE_DOUBLE != FFI_TYPE_LONGDOUBLE || ((*p_arg)-type == FFI_TYPE_LONGDOUBLE) #endif ) { z = sizeof(ffi_arg); *(void **)argp = *p_argv; } else if ((*p_arg)-type == FFI_TYPE_FLOAT) { memcpy(argp, *p_argv, z); } else #endif It looks to me as though issue 17310 may be related. Credit for this discovery should go to Freek Mank. -- components: ctypes messages: 207520 nosy: mark.dickinson priority: high severity: normal status: open title: broken ctypes calling convention on MSVC / 64-bit Windows (large structs) type: crash versions: Python 2.7, Python 3.3, Python 3.4 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20160 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20161] inspect.signature fails on some functions which use Argument Clinic
New submission from Serhiy Storchaka: inspect.signature fails on some functions which use Argument Clinic. For example after applying issue20133 or issue20151 it fails for audioop.ratecv and binascii.a2b_qp. inspect.signature(audioop.ratecv) Traceback (most recent call last): File stdin, line 1, in module File /home/serhiy/py/cpython/Lib/inspect.py, line 1468, in signature return Signature.from_builtin(obj) File /home/serhiy/py/cpython/Lib/inspect.py, line 1989, in from_builtin p(name, default) File /home/serhiy/py/cpython/Lib/inspect.py, line 1982, in p default = default.n AttributeError: type object '_empty' has no attribute 'n' -- messages: 207521 nosy: larry, serhiy.storchaka priority: release blocker severity: normal status: open title: inspect.signature fails on some functions which use Argument Clinic type: behavior versions: Python 3.4 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20161 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20151] Convert the binascii module to use Argument Clinic
Changes by Serhiy Storchaka storch...@gmail.com: -- dependencies: +inspect.signature fails on some functions which use Argument Clinic ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20151 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20148] Convert the _sre module to use Argument Clinic
Changes by Serhiy Storchaka storch...@gmail.com: -- dependencies: +inspect.signature fails on some functions which use Argument Clinic ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20148 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20133] Convert the audioop module to use Argument Clinic
Changes by Serhiy Storchaka storch...@gmail.com: -- dependencies: +inspect.signature fails on some functions which use Argument Clinic ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20133 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20161] inspect.signature fails on some functions which use Argument Clinic
Larry Hastings added the comment: I already noticed this; it'll be fixed in the patch for #20144. But thanks for the report! -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20161 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20160] broken ctypes calling convention on MSVC / 64-bit Windows (large structs)
Larry Hastings added the comment: For the record, I'd be very happy to accept a patch for this into 3.4 at any time. -- nosy: +larry ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20160 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20158] Argument Clinic: add --clean option
Serhiy Storchaka added the comment: As fast as it is possible. This shouldn't be hard task, Argument Clinic already clean old generated code before inserting new code. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20158 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20158] Argument Clinic: add --clean option
Larry Hastings added the comment: I meant, under what circumstances would you want to use this? I don't know why you would ever want --clean. Removing the output from the Argument Clinic blocks would break any file using it. And Argument Clinic is sufficiently fast, if you were worried about the output being wrong you could just run it again. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20158 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20144] Argument Clinic doesn't support named constants as default values
Larry Hastings added the comment: Here's a second patch; I think this is ready to go in I cleaned up the node parsing a lot. It now knows how to parse the following types of default values: * Number (this applies to both ints and floats) * String ('hello') * Attribute (sys.maxsize) * Named constant (None, True, False) As long as I'm fixing this, I want to add support for any other values we're going to want. Did I miss any? Note that we can't really support container types, because initializing them on the C side isn't practical. Also, the tests don't exercise all of the above possible node types, just because I couldn't remember builtins that used those types. We'll fill in the remaining tests as we port new functions to Argument Clinic. If I can get a quick LGTM review, I'll check this in. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20144 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20144] Argument Clinic doesn't support named constants as default values
Larry Hastings added the comment: Oops! I forgot to actually attach the new patch. I'm dumb. -- Added file: http://bugs.python.org/file33340/larry.simple.symbolic.constant.default.values.diff.2.txt ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20144 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue19723] Argument Clinic should add markers for humans
Larry Hastings added the comment: Antoine just suggested that, if we used this accumulator thing, we'd want a convention for where the generated text should go. I actually have an answer for that: near the end, below the implementations of the module / class methods, but above the methoddef/type structures and the module init function. My reasoning: when I navigate CPython C files implementing a module or a type, when I know what entry point I want I just search for its name. When I don't know what I want, I jump to the end, then scroll up until I find the name in the init function or the structures. So I wouldn't want the code at the very end; that would screw up that navigation mode. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19723 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue19723] Argument Clinic should add markers for humans
Stefan Krah added the comment: I think maybe I only showed it to Stefan Krah, who said it wouldn't help his use case so I dropped it. I think we were talking about _decimal, where any tool will interfere with the 100% code coverage patches. But that's a special case. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19723 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20158] Argument Clinic: add --clean option
Serhiy Storchaka added the comment: This would just make sources more readable and editable. While I read, write or edit code, I don't want generated code distract me. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20158 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue2263] struct.pack() + numpy int raises SystemError
Changes by STINNER Victor victor.stin...@gmail.com: -- nosy: +haypo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue2263 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue9307] Py_TPFLAGS_LONG_SUBCLASS is not documented
Changes by STINNER Victor victor.stin...@gmail.com: -- nosy: +haypo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9307 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20158] Argument Clinic: add --clean option
Larry Hastings added the comment: I don't think Argument Clinic should do this. It would leave the file in a broken state. But if it's an option on clinic.py it might tempt somebody into using it, then they'd be confused. If you want this functionality, please hack it up yourself locally. I wouldn't accept this as a patch. Personally I just got used to the Clinic generated code. -- resolution: - rejected stage: - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20158 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20141] Argument Clinic: broken support for 'O!'
Larry Hastings added the comment: Attached is a new, simpler approach for supporting O!. The object() converter now takes two arguments: * type, which is the type you want the parameter declared as (e.g. PyUnicodeObject *) * subclass_of, which is the PyTypeObject you want to enforce the value is an instance of (e.g. PyUnicode_Type) The old approach was kind of a lovely idea, but was too complicated, and it would have meant registering any new type (like third-party types). This is less convenient, but simple. And it would lend itself well to making a custom converter if you used it a lot. I'll write some documentation for it now, but I wanted to post the code so I could get a review. p.s. Why was is marked crash and release blocker? That's very inaccurate. And assigned to docs? WTH? -- assignee: docs@python - larry nosy: -docs@python priority: release blocker - normal stage: - patch review type: crash - behavior Added file: http://bugs.python.org/file33341/larry.argument.clinic.o-bang.rethink.diff.1.txt ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20141 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20162] Test test_hash_distribution fails on RHEL 6.5 / ppc64
New submission from Yury V. Zaytsev: Hi, When I try the following: ./python -m test -v test_hash on a self-compiled Python 3.4.0b2 on RHEL 6.5 / ppc64, it fails. Please let me know which additional information I can supply to diagnose the problem. The complete traceback below: == CPython 3.4.0b2 (default, Jan 6 2014, 15:23:43) [GCC 4.4.7 20120313 (Red Hat 4.4.7-4)] == Linux-2.6.32-431.el6.ppc64-ppc64-with-redhat-6.5-Santiago big-endian == hash algorithm: siphash24 64bit == /XXX/build/test_python_13082 Testing with flags: sys.flags(debug=0, inspect=0, interactive=0, optimize=0, dont_write_bytecode=0, no_user_site=0, no_site=0, ignore_environment=0, verbose=0, bytes_warning=0, quiet=0, hash_randomization=1, isolated=0) [1/1] test_hash test_empty_string (test.test_hash.BytesHashRandomizationTests) ... ok test_fixed_hash (test.test_hash.BytesHashRandomizationTests) ... ok test_long_fixed_hash (test.test_hash.BytesHashRandomizationTests) ... ok test_null_hash (test.test_hash.BytesHashRandomizationTests) ... ok test_randomized_hash (test.test_hash.BytesHashRandomizationTests) ... ok test_randomized_hash (test.test_hash.DatetimeDateTests) ... ok test_randomized_hash (test.test_hash.DatetimeDatetimeTests) ... ok test_randomized_hash (test.test_hash.DatetimeTimeTests) ... ok test_hashes (test.test_hash.HashBuiltinsTestCase) ... ok test_hash_distribution (test.test_hash.HashDistributionTestCase) ... FAIL test_coerced_floats (test.test_hash.HashEqualityTestCase) ... ok test_coerced_integers (test.test_hash.HashEqualityTestCase) ... ok test_numeric_literals (test.test_hash.HashEqualityTestCase) ... ok test_unaligned_buffers (test.test_hash.HashEqualityTestCase) ... ok test_default_hash (test.test_hash.HashInheritanceTestCase) ... ok test_error_hash (test.test_hash.HashInheritanceTestCase) ... ok test_fixed_hash (test.test_hash.HashInheritanceTestCase) ... ok test_hashable (test.test_hash.HashInheritanceTestCase) ... ok test_not_hashable (test.test_hash.HashInheritanceTestCase) ... ok test_empty_string (test.test_hash.MemoryviewHashRandomizationTests) ... ok test_fixed_hash (test.test_hash.MemoryviewHashRandomizationTests) ... ok test_long_fixed_hash (test.test_hash.MemoryviewHashRandomizationTests) ... ok test_null_hash (test.test_hash.MemoryviewHashRandomizationTests) ... ok test_randomized_hash (test.test_hash.MemoryviewHashRandomizationTests) ... ok test_empty_string (test.test_hash.StrHashRandomizationTests) ... ok test_fixed_hash (test.test_hash.StrHashRandomizationTests) ... ok test_long_fixed_hash (test.test_hash.StrHashRandomizationTests) ... ok test_null_hash (test.test_hash.StrHashRandomizationTests) ... ok test_randomized_hash (test.test_hash.StrHashRandomizationTests) ... ok test_ucs2_string (test.test_hash.StrHashRandomizationTests) ... ok == FAIL: test_hash_distribution (test.test_hash.HashDistributionTestCase) -- Traceback (most recent call last): File /XXX/Lib/test/test_hash.py, line 340, in test_hash_distribution self.assertGreater(len(s15), 8, prefix) AssertionError: 1 not greater than 8 : abc -- Ran 30 tests in 0.694s FAILED (failures=1) 1 test failed: test_hash Thanks! -- components: Tests messages: 207533 nosy: zaytsev priority: normal severity: normal status: open title: Test test_hash_distribution fails on RHEL 6.5 / ppc64 type: crash versions: Python 3.4 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20162 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20162] Test test_hash_distribution fails on RHEL 6.5 / ppc64
Changes by Antoine Pitrou pit...@free.fr: -- components: +Interpreter Core nosy: +David.Edelsohn, christian.heimes, dmalcolm priority: normal - high type: crash - behavior ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20162 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20162] Test test_hash_distribution fails on RHEL 6.5 / ppc64
Yury V. Zaytsev added the comment: As requested by Victor Stinner: ./python -c 'import sys; print(sys.hash_info)' sys.hash_info(width=64, modulus=2305843009213693951, inf=314159, nan=0, imag=103, algorithm='siphash24', hash_bits=64, seed_bits=128, cutoff=0) -- components: -Interpreter Core type: behavior - crash ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20162 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20162] Test test_hash_distribution fails on RHEL 6.5 / ppc64
Yury V. Zaytsev added the comment: Sorry for accidentally rolling back your changes to the bug, Antoine! -- components: +Interpreter Core -Tests type: crash - behavior ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20162 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20162] Test test_hash_distribution fails on RHEL 6.5 / ppc64
Changes by Yury V. Zaytsev y...@shurup.com: -- components: +Tests ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20162 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20162] Test test_hash_distribution fails on RHEL 6.5 / ppc64
Roundup Robot added the comment: New changeset 81f8b4744f1a by Victor Stinner in branch 'default': Issue #20162: test_hash_distribution() uses subTest() to mention the prefix in http://hg.python.org/cpython/rev/81f8b4744f1a -- nosy: +python-dev ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20162 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20162] Test test_hash_distribution fails on RHEL 6.5 / ppc64
Yury V. Zaytsev added the comment: == FAIL: test_hash_distribution (test.test_hash.HashDistributionTestCase) (prefix='abc') -- Traceback (most recent call last): File /XXX/Lib/test/test_hash.py, line 341, in test_hash_distribution self.assertGreater(len(s15), 8, prefix) AssertionError: 1 not greater than 8 : abc == FAIL: test_hash_distribution (test.test_hash.HashDistributionTestCase) (prefix='abcdefghabc') -- Traceback (most recent call last): File /XXX/Lib/test/test_hash.py, line 341, in test_hash_distribution self.assertGreater(len(s15), 8, prefix) AssertionError: 1 not greater than 8 : abcdefghabc -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20162 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20141] Argument Clinic: broken support for 'O!'
Serhiy Storchaka added the comment: It is marked crash because Argument Clinic generates code which crashes. It is assigned to docs because this feature documentation is misleading. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20141 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20162] Test test_hash_distribution fails on RHEL 6.5 / ppc64
Yury V. Zaytsev added the comment: To check whether the problem is in the _le64toh() macro as suggested by Victor Stinner, I've tried the attached patch and the problem is gone. As it turns out, there actually seem to be two problems: First, HAVE_ENDIAN_H is properly defined, because the correct include file is found, but HAVE_LETOH64 is not defined, even though it exists in the system and is working. Therefore, the macro implementation is used instead. However, the second problem is that apparently something is wrong about the macro, even though Victor says it looks fine on the paper, because when macro is replaced by a function from glibc like in my patch, it works. The solution to the first problem, I guess, is to add a proper check to the configure script. I don't have a solution for the second problem. For the record, the test output with the patch applied: bash-4.1$ ./python -m test -v test_hash == CPython 3.4.0b2 (default, Jan 7 2014, 15:03:44) [GCC 4.4.7 20120313 (Red Hat 4.4.7-4)] == Linux-2.6.32-431.el6.ppc64-ppc64-with-redhat-6.5-Santiago big-endian == hash algorithm: siphash24 64bit == /XXX/build/test_python_27880 Testing with flags: sys.flags(debug=0, inspect=0, interactive=0, optimize=0, dont_write_bytecode=0, no_user_site=0, no_site=0, ignore_environment=0, verbose=0, bytes_warning=0, quiet=0, hash_randomization=1, isolated=0) [1/1] test_hash test_empty_string (test.test_hash.BytesHashRandomizationTests) ... ok test_fixed_hash (test.test_hash.BytesHashRandomizationTests) ... ok test_long_fixed_hash (test.test_hash.BytesHashRandomizationTests) ... ok test_null_hash (test.test_hash.BytesHashRandomizationTests) ... ok test_randomized_hash (test.test_hash.BytesHashRandomizationTests) ... ok test_randomized_hash (test.test_hash.DatetimeDateTests) ... ok test_randomized_hash (test.test_hash.DatetimeDatetimeTests) ... ok test_randomized_hash (test.test_hash.DatetimeTimeTests) ... ok test_hashes (test.test_hash.HashBuiltinsTestCase) ... ok test_hash_distribution (test.test_hash.HashDistributionTestCase) ... ok test_coerced_floats (test.test_hash.HashEqualityTestCase) ... ok test_coerced_integers (test.test_hash.HashEqualityTestCase) ... ok test_numeric_literals (test.test_hash.HashEqualityTestCase) ... ok test_unaligned_buffers (test.test_hash.HashEqualityTestCase) ... ok test_default_hash (test.test_hash.HashInheritanceTestCase) ... ok test_error_hash (test.test_hash.HashInheritanceTestCase) ... ok test_fixed_hash (test.test_hash.HashInheritanceTestCase) ... ok test_hashable (test.test_hash.HashInheritanceTestCase) ... ok test_not_hashable (test.test_hash.HashInheritanceTestCase) ... ok test_empty_string (test.test_hash.MemoryviewHashRandomizationTests) ... ok test_fixed_hash (test.test_hash.MemoryviewHashRandomizationTests) ... ok test_long_fixed_hash (test.test_hash.MemoryviewHashRandomizationTests) ... ok test_null_hash (test.test_hash.MemoryviewHashRandomizationTests) ... ok test_randomized_hash (test.test_hash.MemoryviewHashRandomizationTests) ... ok test_empty_string (test.test_hash.StrHashRandomizationTests) ... ok test_fixed_hash (test.test_hash.StrHashRandomizationTests) ... ok test_long_fixed_hash (test.test_hash.StrHashRandomizationTests) ... ok test_null_hash (test.test_hash.StrHashRandomizationTests) ... ok test_randomized_hash (test.test_hash.StrHashRandomizationTests) ... ok test_ucs2_string (test.test_hash.StrHashRandomizationTests) ... ok -- Ran 30 tests in 0.759s OK 1 test OK. -- keywords: +patch Added file: http://bugs.python.org/file33342/pyhash.c.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20162 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20162] Test test_hash_distribution fails on RHEL 6.5 / ppc64
Yury V. Zaytsev added the comment: I was also asked to mention this: https://github.com/majek/csiphash/blob/master/csiphash.c as an alternative implementation of siphash and platform checks. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20162 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue19723] Argument Clinic should add markers for humans
Larry Hastings added the comment: Patch attached. I tweaked the punctuation in the last line, from this: /*[clinic end generated code; checksum: {checksum}]*/ ^ ^ to this: | | v v /*[clinic end generated code: checksum={checksum}]*/ Guido, can you live with that? I think it's a slight improvement but I'm not committed enough to fight about it. I'll change it back if you want it your way. -- Added file: http://bugs.python.org/file33343/larry.change.clinic.markers.diff.1.txt ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19723 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20163] ValueError: time data does not match format
New submission from dellair jie: Hello, We are using Python 3.3.2 for HPUX11.31. The following error happens only on HPUX, works on SunOS, RHEL, AIX. python Python 3.3.2 (default, Dec 9 2013, 14:04:25) [C] on hp-ux11 Type help, copyright, credits or license for more information. from datetime import datetime datetime.strptime (10-Dec-13.20:07:49, %d-%b-%y.%H:%M:%S) Traceback (most recent call last): File stdin, line 1, in module File /python/lib/python3.3/_strptime.py, line 500, in _strptime_datetime tt, fraction = _strptime(data_string, format) File /python/lib/python3.3/_strptime.py, line 337, in _strptime (data_string, format)) ValueError: time data '10-Dec-13.20:07:49' does not match format '%d-%b-%y.%H:%M:%S' It looks like a bug. Could you please shed some lights? Thanks in advance, Br, Li -- components: Library (Lib) messages: 207542 nosy: dellair.jie priority: normal severity: normal status: open title: ValueError: time data does not match format type: behavior versions: Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20163 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20126] sched doesn't handle events added after scheduler starts
Giampaolo Rodola' added the comment: I don't think this should be documented as personally I wouldn't expect this use case to be working in the first place. -- nosy: +giampaolo.rodola ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20126 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20163] ValueError: time data does not match format
STINNER Victor added the comment: Try to isolate which field fails. Example: import time time.strptime (10-Dec-13.20:07:49, %d-%b-%y.%H:%M:%S) time.struct_time(tm_year=2013, tm_mon=12, tm_mday=10, tm_hour=20, tm_min=7, tm_sec=49, tm_wday=1, tm_yday=344, tm_isdst=-1) time.strptime (10-Dec-13, %d-%b-%y) time.struct_time(tm_year=2013, tm_mon=12, tm_mday=10, tm_hour=0, tm_min=0, tm_sec=0, tm_wday=1, tm_yday=344, tm_isdst=-1) time.strptime (10-Dec, %d-%b) time.struct_time(tm_year=1900, tm_mon=12, tm_mday=10, tm_hour=0, tm_min=0, tm_sec=0, tm_wday=0, tm_yday=344, tm_isdst=-1) time.strptime (Dec, %b) time.struct_time(tm_year=1900, tm_mon=12, tm_mday=1, tm_hour=0, tm_min=0, tm_sec=0, tm_wday=5, tm_yday=335, tm_isdst=-1) -- nosy: +haypo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20163 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20158] Argument Clinic: add --clean option
Larry Hastings added the comment: Consider: if you ran clinic.py --clean on a C file, then tried to use make clinic, the makefile would first try to build the C file. But since the C file is now broken, the make would fail. And you can't use make clinic to regenerate the Clinic output. Obviously this is fixable, but for someone unfamiliar with Argument Clinic this could be very confusing. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20158 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20141] Argument Clinic: broken support for 'O!'
Larry Hastings added the comment: There are lots of ways you can crash Python by giving erroneous input to Argument Clinic. Clinic has no visibility into the C type system, so it has no way of verifying whether or not the type objects you pass in are correct. That's unfixable and not really interesting. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20141 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20144] Argument Clinic doesn't support named constants as default values
Larry Hastings added the comment: At Antoine's suggestion, I added a custom function to testcapi that exercises all the different possible types for default values in a text signature. Also the docs have been updated. LGTU? -- Added file: http://bugs.python.org/file33344/larry.simple.symbolic.constant.default.values.diff.3.txt ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20144 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20163] ValueError: time data does not match format
dellair jie added the comment: Victor, Thanks for the comment. Isolated, the error happens at: import time time.strptime (Dec, %b) Traceback (most recent call last): File stdin, line 1, in module File /python/lib/python3.3/_strptime.py, line 494, in _strptime_time tt = _strptime(data_string, format)[0] File /python/lib/python3.3/_strptime.py, line 340, in _strptime data_string[found.end():]) ValueError: unconverted data remains: Dec -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20163 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20163] ValueError: time data does not match format
dellair jie added the comment: The output of command: $ date +'%b' Jan $ uname -a HP-UX test5 B.11.31 U ia64 4201936010 unlimited-user license -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20163 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue19723] Argument Clinic should add markers for humans
Guido van Rossum added the comment: The new syntax is fine; I was only giving an example. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19723 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20163] ValueError: time data does not match format
STINNER Victor added the comment: time.strptime (Dec, %b) ValueError: unconverted data remains: Dec Ok, so what is the name of the December month? import time time.strftime(%b, time.gmtime(1387036705)) 'Dec' -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20163 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20164] Undocumented KeyError from os.path.expanduser
New submission from Chris Adams: This is a more general version of #10496: os.path.expanduser is documented as returning the unmodified string if it cannot be expanded (http://docs.python.org/3/library/os.path.html#os.path.expanduser) but there's one edge case where this can fail: when running without HOME in the environment: https://github.com/python/cpython/blob/3.3/Lib/posixpath.py#L259-L263 In this case, pwd.getpwuid is called and although it's not documented as such, it raises a KeyError anytime the underlying POSIX getpwuid() call fails: https://github.com/python/cpython/blob/3.3/Modules/pwdmodule.c#L119-L120 Reproducing this deliberately: cadams@Io:~ $ sudo -H python Python 2.7.5 (default, Aug 25 2013, 00:04:04) [GCC 4.2.1 Compatible Apple LLVM 5.0 (clang-500.0.68)] on darwin Type help, copyright, credits or license for more information. import os import posix posix.setuid(1001) posix.seteuid(1001) os.environ.pop('HOME') '/var/root' os.path.expanduser(~) Traceback (most recent call last): File stdin, line 1, in module File /System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/posixpath.py, line 269, in expanduser userhome = pwd.getpwuid(os.getuid()).pw_dir KeyError: 'getpwuid(): uid not found: 1001' Context: * https://github.com/toastdriven/django-haystack/issues/924 * https://github.com/kennethreitz/requests/issues/1846. -- components: Library (Lib) messages: 207552 nosy: acdha priority: normal severity: normal status: open title: Undocumented KeyError from os.path.expanduser versions: Python 2.7, Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20164 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20163] ValueError: time data does not match format
dellair jie added the comment: We get an empty string for the name. :) time.strftime(%b, time.gmtime(1387036705)) '' -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20163 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20162] Test test_hash_distribution fails on RHEL 6.5 / ppc64
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. Assembly output is attached, unfortunately, I'm no ppc64 expert, so I can't immediately tell what exactly went wrong. In any case, the first half of the bug (missing check for HAVE_LETOH64) which triggered the second half still seems valid. I think it's not feasible to upgrade the compiler on RHEL 6.5 (unless someone with a subscription wants to have a go), but fixing the first part should avoid the compiler bug altogether. -- Added file: http://bugs.python.org/file33345/le64toh.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20162 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20164] Undocumented KeyError from os.path.expanduser
Yury V. Zaytsev added the comment: Amusingly, it's also the case on BG/Q compute nodes. Only this morning, I cooked up the following patch: --- a/Lib/posixpath.py +++ b/Lib/posixpath.py @@ -237,7 +237,11 @@ def expanduser(path): if i == 1: if 'HOME' not in os.environ: import pwd -userhome = pwd.getpwuid(os.getuid()).pw_dir +try: +userhome = pwd.getpwuid(os.getuid()).pw_dir +except KeyError: +import warnings +warnings.warn('Unable to auto-detect $HOME, export it or functionality such as user-installed modules will not work!', RuntimeWarning) else: userhome = os.environ['HOME'] else: I think it's a bit harsh to fail completely, but returning silently also doesn't sound like a good idea, so I decided to issue a warning instead; the wording should be probably tweaked by a native speaker of English though. What do you think? -- nosy: +zaytsev type: - behavior versions: +Python 3.4 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20164 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20162] Test test_hash_distribution fails on RHEL 6.5 / ppc64
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. Can you reduce the suspected compiler bug to a minimal reproducer? Please then run it through the preprocessor using gcc's -E option, and then attach it to this bug. What exact version of the compiler are you using, and with what flags? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20162 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20163] ValueError: time data does not match format
STINNER Victor added the comment: We get an empty string for the name. :) Ok, it's maybe time to upgrade to Linux :-) (How old is HPUX? I didn't know that it's still in use.) I don't see how Python could workaround the issue if strftime(%b) doesn't work. An option would be to reimplemenet strftime() (in Python?), see #3173. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20163 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20096] Mention modernize and future in Python 2/3 porting HOWTO
Roundup Robot added the comment: New changeset e4d98ed54c53 by Brett Cannon in branch 'default': Issue #20096: Update the Python 2/3 porting HOWTO to focus on http://hg.python.org/cpython/rev/e4d98ed54c53 -- nosy: +python-dev ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20096 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20162] Test test_hash_distribution fails on RHEL 6.5 / ppc64
Yury V. Zaytsev added the comment: Hi David, It's gcc from RHEL 6.5 gcc-4.4.7-4.el6.ppc64, the flags are -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes vs. -DNDEBUG -g -fwrapv -O1 -Wall -Wstrict-prototypes. The problem is, I can't isolate it. We honestly tried it with Victor, but gcc doesn't want to miscompile a trivial example. You can see in the attachment as far as I could get: I wrapped the macro in a function, so that it doesn't inline and compared the assembly of the good and bad object files. Hope that helps! -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20162 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20158] Argument Clinic: add --clean option
Serhiy Storchaka added the comment: How it differs from the case when you just edit clinic declaration and *_impl function? Until you run clinic on this source file, it is broken. I see that peoples already confused by Argument Clinic and manually edit generated code. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20158 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20162] Test test_hash_distribution fails on RHEL 6.5 / ppc64
Yury V. Zaytsev added the comment: Look for _le64toh ;-) -- Added file: http://bugs.python.org/file33347/pyhash.preproc.c ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20162 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20157] Argument Clinic generates wrong keyword parameter name for default
Larry Hastings added the comment: The problem was an easy fix. However, while fixing it I discovered another problem (if [clinic]*/ was the last line, and it didn't have an eol, Clinic would append another [clinic]*/). I fixed that too and added a regression test. Okay? -- Added file: http://bugs.python.org/file33346/larry.clinic.keyword.renamer.diff.1.txt ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20157 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20096] Mention modernize and future in Python 2/3 porting HOWTO
Changes by Brett Cannon br...@python.org: -- assignee: docs@python - brett.cannon resolution: - fixed status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20096 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20158] Argument Clinic: add --clean option
Larry Hastings added the comment: If you edit the Clinic input and don't run clinic.py on it, it's out-of-date but not broken. If you edit the Clinic output and make a mistake, it's *your* fault. If you ran clinic.py --clean, now you've broken your file *and* the normal Clinic build system and you were using the tool correctly. It's the *tool's* fault. I will admit to having very little interest in adding a command-line option called --clean that breaks everything. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20158 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20162] Test test_hash_distribution fails on RHEL 6.5 / ppc64
Yury V. Zaytsev added the comment: Digging more into it, I guess I know why we couldn't come up with a minimal reproducer for this problem. If I compile with -O2 instead of -O1, I get the following warning from gcc: Python/pyhash.c:413: warning: dereferencing pointer 'pt.32' does break strict-aliasing rules which points to the following line: case 4: *((PY_UINT32_T*)pt[0]) = *((PY_UINT32_T*)m[0]); break; If I re-compile with -O2, but -fno-strict-aliasing, then the result doesn't fail. Not sure if siphash code can be changed to not require aliasing, though. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20162 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20162] Test test_hash_distribution fails on RHEL 6.5 / ppc64
STINNER Victor added the comment: Python/pyhash.c:413: warning: dereferencing pointer 'pt.32' does break strict-aliasing rules Attached patch siphash_ppc64.patch should fix this aliasing issue. -- nosy: +haypo Added file: http://bugs.python.org/file33349/siphash_ppc64.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20162 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10496] Python startup should not require passwd entry
Changes by Yury V. Zaytsev y...@shurup.com: -- nosy: +zaytsev ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10496 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue19713] Deprecate various things in importlib thanks to PEP 451
Arfrever Frehtes Taifersar Arahesis added the comment: New changeset 37caaf21f827 by Eric Snow in branch 'default': Issue 19713: Add PEP 451-related deprecations. http://hg.python.org/cpython/rev/37caaf21f827 ... -spec.loader.load_module(spec.name) +try: +_warnings +except NameError: +# We must be importing builtins in setup(). +spec.loader.load_module(spec.name) +else: +spec.loader.load_module(spec.name) Is this correct? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19713 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20144] Argument Clinic doesn't support named constants as default values
Larry Hastings added the comment: Incorporated suggestions from Serhiy. Thanks, Serhiy! -- Added file: http://bugs.python.org/file33348/larry.simple.symbolic.constant.default.values.diff.4.txt ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20144 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20162] Test test_hash_distribution fails on RHEL 6.5 / ppc64
Yury V. Zaytsev added the comment: Related issue where memcpy() was discussed: http://bugs.python.org/issue19183 . -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20162 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20162] Test test_hash_distribution fails on RHEL 6.5 / ppc64
STINNER Victor added the comment: Attached patch siphash_ppc64.patch should fix this aliasing issue. It looks like memcpy was discussed in the initial issue #19183 for performances. IMO the function must first produce the good result, and then be fast :-) -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20162 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20072] Ttk tests fail when wantobjects is false
Roundup Robot added the comment: New changeset 2d81d0d42ae2 by Serhiy Storchaka in branch '3.3': Issue #20072: Fixed multiple errors in tkinter with wantobjects is False. http://hg.python.org/cpython/rev/2d81d0d42ae2 New changeset 1628cd94db52 by Serhiy Storchaka in branch 'default': Issue #20072: Fixed multiple errors in tkinter with wantobjects is False. http://hg.python.org/cpython/rev/1628cd94db52 New changeset 89b3836f7378 by Serhiy Storchaka in branch '2.7': Issue #20072: Fixed multiple errors in tkinter with wantobjects is False. http://hg.python.org/cpython/rev/89b3836f7378 -- nosy: +python-dev ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20072 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue18515] zipfile._ZipDecryptor generates wasteful crc32 table on import
Changes by Serhiy Storchaka storch...@gmail.com: -- resolution: - fixed stage: patch review - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue18515 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20162] Test test_hash_distribution fails on RHEL 6.5 / ppc64
Christian Heimes added the comment: Oh heck ... I didn't run into this issue when I was testing siphash on all platforms. Could it be a compiler bug? I'd rather not change the code and deviate from the reference implementation. It's a performance critical part... -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20162 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20163] ValueError: time data does not match format
dellair jie added the comment: Victor, HPUX 11.31 was first released in 2007, we keep upgrading and the latest update is in 2013. ^_^ A workaround sounds fine. By re-implementing strftime(), do you mean to patch it from: http://bugs.python.org/issue1777412? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20163 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20078] zipfile - ZipExtFile.read goes into 100% CPU infinite loop on maliciously binary edited zips
Serhiy Storchaka added the comment: Looks as 2.7 is not affected. If there are no objections I will commit this patch tomorrow. -- versions: -Python 2.7 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20078 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20162] Test test_hash_distribution fails on RHEL 6.5 / ppc64
Serhiy Storchaka added the comment: On platforms where unaligned access is not an issue, gcc produces for memcpy() an optimal binary code equivalent to simple assignment of 32-bit value. Only MSVC produces slow code, but Windows works only on platforms where unaligned access is not an issue. So we can use simple assignment when _MSC_VER is defined and memcpy() in other cases (it is what I was proposed in issue19183 for PY_UHASH_CPY). -- nosy: +serhiy.storchaka ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20162 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20162] Test test_hash_distribution fails on RHEL 6.5 / ppc64
Yury V. Zaytsev added the comment: Hi Christian, Dave says it's not a compiler bug; the code is slightly violating the C standard, and the compiler optimizes based on a strict reading of the rules. If I compile with -O2 and higher (while -O3 is the default for Python, as far as I can understand), the compiler correctly warns me about possible issues; as you can see, the macro itself is not at fault, even. It's just that in my particular (rare) mix of circumstances: being big endian, using the macro instead of the glibc function due to the first part of the bug, etc. it results in miscompilation, and in your case, it remains a warning, but the result still works. I think the clean solutions to this problem are as follows: 1) Do not break strict aliasing (use memcpy() instead or something) 2) Disable strict aliasing based optimizations (-fno-strict-aliasing) In addition, fixing the first part of the bug (wrongly using a macro even if le64toh is available), will mask the second part for me again, but I'm not sure if it will re-surface at some point later or not :) Hope that helps! -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20162 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue18960] First line can be executed twice
Serhiy Storchaka added the comment: Benjamin, current version (without switch) looks more clean to me. Are you insist? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue18960 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20162] Test test_hash_distribution fails on RHEL 6.5 / ppc64
STINNER Victor added the comment: Only MSVC produces slow code, but Windows works only on platforms where unaligned access is not an issue. My patch uses Py_MEMCPY() which uses a loop to copy bytes on Visual Studio for length smaller than 16 bytes (SipHash copies 4 bytes). -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20162 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20158] Argument Clinic: add --clean option
Serhiy Storchaka added the comment: If you ran clinic.py --clean and then not ran clinic.py without --clean, it's *your* fault. And you will noticed this when run make. I have named this option --clean because it is similar to 'make clean' and 'make distclean'. If you want make automatically call clinic.py, lets 'make clinic' create the .clinic file, 'clinic.py --clean' remove it, and 'make' check if this file exists and run 'make clinic' otherwise. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20158 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20164] Undocumented KeyError from os.path.expanduser
Chris Adams added the comment: Other than hoisting the warnings import to the top (PEP-8) that seems entirely reasonable to me. The user report which we got was confusing because it was non-obvious where it came from - a warning or other pointer would have helped the original reporter get an idea as to what was failing earlier. The other two changes I'd suggest would be documentation updates: os.path.expanduser noting that KeyError may be raised when HOME is undefined and pwd.getpwuid fails for the active user pwd.getpwuid noting that KeyErrors will be raised when the underlying POSIX call fails -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20164 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20158] Argument Clinic: add --clean option
Larry Hastings added the comment: I must admit I am losing patience with this conversation. Argument Clinic is not going to provide an attractively-named option that breaks your build and requires fixing by hand. The bug is closed, the feature is not happening, it's my hope that we can now move on. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20158 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue19255] Don't wipe builtins at shutdown
Antoine Pitrou added the comment: Here is simpler patch with a test. -- Added file: http://bugs.python.org/file33350/builtins_cleanup.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19255 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20165] unittest TestResult wasSuccessful returns True when there are unexpected successes
New submission from Gregory P. Smith: Python 3.3.3+ (3.3:28337a8fb502+, Jan 7 2014, 01:32:44) [GCC 4.6.3] on linux Type help, copyright, credits or license for more information. import unittest r = unittest.result.TestResult() r.wasSuccessful() True r.addUnexpectedSuccess(weird!) r.wasSuccessful() True An unexpected success is not a good thing and indicates a problem. the wasSuccessful() method should include a check for len(self.unexpectedSuccesses) == 0 as part of its condition. -- assignee: gregory.p.smith messages: 207582 nosy: gregory.p.smith priority: normal severity: normal stage: needs patch status: open title: unittest TestResult wasSuccessful returns True when there are unexpected successes type: behavior versions: Python 2.7, Python 3.3, Python 3.4 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20165 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20165] unittest TestResult wasSuccessful returns True when there are unexpected successes
Gregory P. Smith added the comment: somewhat related - https://code.google.com/p/unittest-ext/issues/detail?id=22 -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20165 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20166] window x64 c-extensions not works on python3.4.0b2
New submission from jarod: After installing python3.4.0b2.amd64 and rebuild modules, most of them stoped works. List of modules is [psutil, ujson]. Exception occurs on importing module: import error: dynamic module does not define init function PyInit_module_name and I found solution (workaround) - need change declaration of init function: Line: PyObject *PyInit_module_name(void) was changed to: PyMODINIT_FUNC PyInit_module_name(void) and module works fine after rebuild. All works fine with 3.4.0b1 and all alpha versions. I have windows8.1 x64. -- components: Build, Windows messages: 207584 nosy: jarod priority: normal severity: normal status: open title: window x64 c-extensions not works on python3.4.0b2 versions: Python 3.4 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20166 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20144] Argument Clinic doesn't support named constants as default values
Roundup Robot added the comment: New changeset c96dba33f019 by Larry Hastings in branch 'default': Issue #20144: Argument Clinic now supports simple constants as parameter http://hg.python.org/cpython/rev/c96dba33f019 -- nosy: +python-dev ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20144 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20144] Argument Clinic doesn't support named constants as default values
Larry Hastings added the comment: Argument Clinic now supports simple constants like sys.maxsize as default values for arguments for builtins. I'm assuming this gets you basically what you wanted; if this isn't sufficient please open a new issue. -- assignee: - larry resolution: - fixed stage: - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20144 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20141] Argument Clinic: broken support for 'O!'
Roundup Robot added the comment: New changeset ddb5cd3e0860 by Larry Hastings in branch 'default': Issue #20141: Improved Argument Clinic's support for the PyArg_Parse O! http://hg.python.org/cpython/rev/ddb5cd3e0860 -- nosy: +python-dev ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20141 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20141] Argument Clinic: broken support for 'O!'
Larry Hastings added the comment: Argument Clinic's support for O! is now simpler and more flexible. It's not as convenient as the previous API, but that API wasn't really sustainable. I'm assuming this fixes your problem; if not please open a new issue. -- resolution: - fixed stage: patch review - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20141 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20157] Argument Clinic generates wrong keyword parameter name for default
Roundup Robot added the comment: New changeset f61c63ec4e70 by Larry Hastings in branch 'default': Issue #20157: When Argument Clinic renames a parameter because its name http://hg.python.org/cpython/rev/f61c63ec4e70 -- nosy: +python-dev ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20157 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20157] Argument Clinic generates wrong keyword parameter name for default
Changes by Larry Hastings la...@hastings.org: -- resolution: - fixed stage: needs patch - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20157 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue19273] Update PCbuild/readme.txt
Roundup Robot added the comment: New changeset e8307cf23af4 by Larry Hastings in branch 'default': Issue #19273: The marker comments Argument Clinic uses have been changed http://hg.python.org/cpython/rev/e8307cf23af4 -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19273 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue19723] Argument Clinic should add markers for humans
Larry Hastings added the comment: I'm assuming this is sufficient. If further bikeshedding is needed please reopen the issue. -- resolution: - fixed stage: needs patch - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19723 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20166] window x64 c-extensions not works on python3.4.0b2
Changes by Antoine Pitrou pit...@free.fr: -- nosy: +brian.curtin, tim.golden ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20166 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue19719] add importlib.abc.SpecLoader and SpecFinder
Roundup Robot added the comment: New changeset 21786a7f8036 by Brett Cannon in branch 'default': Issue #19719: Update various finder and loader ABCs such that their http://hg.python.org/cpython/rev/21786a7f8036 -- nosy: +python-dev ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19719 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue19719] add importlib.abc.SpecLoader and SpecFinder
Changes by Brett Cannon br...@python.org: -- resolution: - fixed status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19719 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20161] inspect.signature fails on some functions which use Argument Clinic
Larry Hastings added the comment: Fixed as a side effect of fixing #20144. And by the way this was never a release blocker. -- assignee: - larry priority: release blocker - normal resolution: - fixed stage: - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20161 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20148] Derby: Convert the _sre module to use Argument Clinic
Larry Hastings added the comment: Can you refresh the patch? I think all the problems you cited are fixed, and also the comments Argument Clinic uses were all changed. I'll review when you have a fresh patch. -- title: Convert the _sre module to use Argument Clinic - Derby: Convert the _sre module to use Argument Clinic ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20148 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20133] Derby: Convert the audioop module to use Argument Clinic
Larry Hastings added the comment: Can you refresh the patch? I think all the problems you cited are fixed, and also the comments Argument Clinic uses were all changed. I'll review when you have a fresh patch. -- title: Convert the audioop module to use Argument Clinic - Derby: Convert the audioop module to use Argument Clinic ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20133 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue20151] Derby: Convert the binascii module to use Argument Clinic
Larry Hastings added the comment: Can you refresh the patch? The comments Argument Clinic uses were all changed. I'll review when you have a fresh patch. -- title: Convert the binascii module to use Argument Clinic - Derby: Convert the binascii module to use Argument Clinic ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20151 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com