Nick Coghlan added the comment:
Yes, since OpenSSL 1.0.2 is still in beta, the target version for 2.7.7 would
be 1.0.1g
--
nosy: +benjamin.peterson
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue21462
Serhiy Storchaka added the comment:
I think it is enough to get rid of this function.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue21474
___
Changes by Ethan Furman et...@stoneleaf.us:
--
nosy: +ethan.furman
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue21469
___
___
Python-bugs-list
Mateusz Łoskot added the comment:
On 9 May 2014 19:21, Tim Golden rep...@bugs.python.org wrote:
Fixed. Thanks for the report
Thank you for the fix.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue21452
Changes by Jakub Wilk jw...@jwilk.net:
--
nosy: +jwilk
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue1599254
___
___
Python-bugs-list mailing list
Changes by Jakub Wilk jw...@jwilk.net:
--
nosy: +jwilk
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20115
___
___
Python-bugs-list mailing list
Berker Peksag added the comment:
There is a patch for Crawl-delay in issue 16099.
--
nosy: +berker.peksag
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue21475
___
Changes by Jakub Wilk jw...@jwilk.net:
--
nosy: +jwilk
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue21221
___
___
Python-bugs-list mailing list
Changes by Martin Dengler mar...@martindengler.com:
--
nosy: +mdengler
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue21423
___
___
Michael Foord added the comment:
It looks like the simplest fix would be to change NameError: to NameError,
as the problem is that they're (sometimes!?) on separate lines.
This still tests what we want to test.
--
___
Python tracker
Matthias Klose added the comment:
sure, doing this. my follow-up question was if it is necessary to fix anything
else in unittest.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue17756
___
New submission from Dmitry Andreychuk:
Calls to autospecced mock functions are not recorded to mock_calls list of
parent mock. This only happens if autospec is used and the original object is a
function.
Example:
import unittest.mock as mock
def foo():
pass
parent = mock.Mock()
Changes by Martin Dengler mar...@martindengler.com:
--
nosy: +mdengler
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue9400
___
___
Python-bugs-list
Changes by Martin Dengler mar...@martindengler.com:
--
nosy: +mdengler
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8296
___
___
Python-bugs-list
Changes by Berker Peksag berker.pek...@gmail.com:
--
nosy: +berker.peksag, serhiy.storchaka
stage: needs patch - patch review
Added file: http://bugs.python.org/file35223/issue21198.diff
___
Python tracker rep...@bugs.python.org
mattip added the comment:
Updated patch for default for empty shape, thanks eryksun
--
Added file:
http://bugs.python.org/file35224/hg-default-ctypes-fix-pep3118-format-strings-for-arrays-update.patch
___
Python tracker rep...@bugs.python.org
Changes by Raymond Hettinger raymond.hettin...@gmail.com:
--
assignee: - rhettinger
nosy: +rhettinger
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16099
___
New submission from Berker Peksag:
The patch also updates the signature of TarFile.open().
--
assignee: docs@python
components: Documentation
files: tarfile-open-classmethod.diff
keywords: patch
messages: 218323
nosy: berker.peksag, docs@python, serhiy.storchaka
priority: normal
Changes by Berker Peksag berker.pek...@gmail.com:
--
keywords: +patch
nosy: +berker.peksag
stage: needs patch - patch review
versions: -Python 3.3
Added file: http://bugs.python.org/file35226/issue20872.diff
___
Python tracker rep...@bugs.python.org
New submission from Skip Montanaro:
It's been awhile since I pulled from Mercurial and built, but I tried
today. I almost immediately ran into an error. The configure step
worked fine, but make, not so much:
% make
python ./Tools/scripts/generate_opcode_h.py ./Lib/opcode.py ./Include/opcode.h
Tal Einat added the comment:
Changes LGTM.
This module could certainly use some cleanup and updates. For example,
last_changed should be a property and always accessed one way (instead of
either .mtime() or .last_changed) and should be initialized to None instead of
zero to avoid ambiguity,
New submission from Joe Borg:
See example:
import argparse
a = argparse.ArgumentParser()
b = a.parse_args([])
if b != None:
... print hey
File stdin, line 2
print hey
^
SyntaxError: invalid syntax
if b != None:
... print(hey)
...
Traceback (most
New submission from Joe Chan:
cannot return correct gcc version if the path name contains space.
Suggest to change to:
$ diff -rupN cygwinccompiler.py.original cygwinccompiler.py
--- cygwinccompiler.py.original 2014-05-12 23:54:01.296303800 +0800
+++ cygwinccompiler.py 2014-05-12
Antoine Pitrou added the comment:
Does make touch work for you as well?
--
components: +Devguide
nosy: +eli.bendersky, ezio.melotti, pitrou
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue21480
Berker Peksag added the comment:
Here's a patch. I followed Antoine's name suggestion.
PSF would more suitable for the epub_publisher option:
http://sphinx-doc.org/config.html#confval-epub_publisher
--
keywords: +patch
nosy: +berker.peksag
stage: needs patch - patch review
Added file:
Joe Borg added the comment:
I believe this comes from doing vars(None). But why would this be happening if
Namespace is empty.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue21481
___
Eli Bendersky added the comment:
Skip, PTAL at the devguide.
https://docs.python.org/devguide/setup.html#avoiding-re-creating-auto-generated-files
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue21480
Joe Chan added the comment:
better to parenthesis all three exes[gcc, ld and dllwrap] with %s to better
support path names that contain non-alphanumeric characters.
$ diff -rupN cygwinccompiler.py.original cygwinccompiler.py
--- cygwinccompiler.py.original 2014-05-12 23:54:01.296303800 +0800
Skip Montanaro added the comment:
Does make touch work for you as well?
Hadn't tried, and wasn't aware of its existence. I searched Makefile
for things like AST_H. Perhaps:
* Note make touch where the A build now requires... comment
exists. That comment currently discourages users, as it
Antoine Pitrou added the comment:
Here is a much faster patch, around 30x faster than the original code.
With exhuma's data set and tester.py, the original code gives:
$ time python3.4 tester.py
Execution time: 5.949284339199949 seconds
real0m30.152s
user0m30.104s
sys 0m0.016s
Josh Triplett added the comment:
This rejection is indeed problematic. If mmap.mmap receives an explicit size,
checking that size against stat will break on devices or special files. It's
perfectly reasonable that mmap.mmap's automatic logic when passed length=0 (to
map the entire file)
New submission from Skip Montanaro:
I got a strange error during make test in a fresh build (hg clone ;
./configure ; make ; make test)
Traceback (most recent call last):
File Lib/test/test_import.py, line 293, in test_timestamp_overflow
os.utime(source, (2 ** 33 - 5, 2 ** 33 - 5))
Antoine Pitrou added the comment:
Uh, those measurements are wrong, sorry, since tester.py doesn't consume the
iterator. When consuming the iterator, the patch is ~ 4x faster than the
original code, which is more reasonable :-)
--
___
Python
New submission from Feliks:
In Sec. 7.2.1 of the Language Reference, in the description of += we have:
Also, when possible, the actual operation is performed in-place, meaning that
rather than creating a new object and assigning that to the target, the old
object is modified instead.
Although
Changes by Antoine Pitrou pit...@free.fr:
--
stage: needs patch - patch review
versions: +Python 3.5 -Python 3.4
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16531
___
Josh Rosenberg added the comment:
It seems to me like that is one of the most obvious consequences. How is this
not an immediately obvious consequence?
--
nosy: +josh.rosenberg
___
Python tracker rep...@bugs.python.org
Antoine Pitrou added the comment:
It seems like the speed of Network.supernet() is a bottleneck here. issue16531
would probably allow making supernet() much faster.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20826
Antoine Pitrou added the comment:
Updated patch with more tests, documentation updates, and an optimized version
of the supernet() that's now 5x faster than the original.
I would like to commit this if there's no further comment.
--
Added file:
Changes by Eric Snow ericsnowcurren...@gmail.com:
--
nosy: +eric.snow
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13742
___
___
Python-bugs-list
Changes by Eric Snow ericsnowcurren...@gmail.com:
--
nosy: +eric.snow
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue17794
___
___
Python-bugs-list
New submission from akira:
The current code example contains [1]:
print(Python failed with exit code %s: % exitcode)
sys.stdout.flush()
sys.stdout.buffer.flush()
sys.stdout.buffer.write(stdout)
sys.stdout.buffer.flush()
that looks bizarre.
Either a comment should be added
Changes by Eric Snow ericsnowcurren...@gmail.com:
--
nosy: +eric.snow
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue1475692
___
___
Francisco Martín Brugué added the comment:
Hi,
sorry if it's trivial but shouldn't we add a 'shifted_true' test
some were to make sure that this behavior change gets noticed next time?
def test_shifted_true(self):
self.assertEqual(True 0, 1)
self.assertEqual(True 1, 2)
--
Changes by Antoine Pitrou pit...@free.fr:
--
dependencies: +Allow IPNetwork to take a tuple
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue21486
___
New submission from Antoine Pitrou:
Here is a patch to optimize ipv4 netmask parsing by maintaining a cache (there
are not many valid ipv4 netmask representations). This should be especially
useful with #16531.
--
components: Library (Lib)
files: v4_netmask.patch
keywords: patch
pmoody added the comment:
fine by me. this has been on my todo list forever by $payingjob and $family
have prevented me from devoting any time.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16531
Roundup Robot added the comment:
New changeset 4e33c343a264 by Antoine Pitrou in branch 'default':
Issue #16531: ipaddress.IPv4Network and ipaddress.IPv6Network now accept an
(address, netmask) tuple argument, so as to easily construct network objects
from existing addresses.
Antoine Pitrou added the comment:
Thanks for the approval, Peter!
--
resolution: - fixed
stage: patch review - resolved
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16531
R. David Murray added the comment:
Francisco: I'd say that was a good idea. Would you like to propose a patch?
(ie: figure out where it should go)
--
nosy: +r.david.murray
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue21422
Antoine Pitrou added the comment:
Updated patch, also optimizing v6 netmask parsing (same principle).
Before patch:
$ ./python -m timeit -s import ipaddress net =
ipaddress.IPv6Network(('2001:db8::', 96))
1 loops, best of 3: 26.1 usec per loop
$ ./python -m timeit -s import ipaddress net
Arfrever Frehtes Taifersar Arahesis added the comment:
Use assertIs, since True == 1, but True is not 1.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue21422
___
Charles-François Natali added the comment:
From a cursory inspection, we only check the size for regular files. What
exception are you seeing exactly?
What does stat return on this file?
--
___
Python tracker rep...@bugs.python.org
Joe Chan added the comment:
To prevent system crashes, I have to exclude msvc runtime library
$ diff -rupN cygwinccompiler.py.original cygwinccompiler.py
--- cygwinccompiler.py.original 2014-05-12 23:54:01.296303800 +0800
+++ cygwinccompiler.py 2014-05-13 02:59:37.870414900 +0800
@@ -341,7
Changes by Barry A. Warsaw ba...@python.org:
--
nosy: +barry
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7776
___
___
Python-bugs-list mailing
Changes by Berker Peksag berker.pek...@gmail.com:
--
nosy: +giampaolo.rodola, gvanrossum, haypo, pitrou, yselivanov
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue21485
___
Charles-François Natali added the comment:
Scratch that.
I'll try to work on a patch that doesn't break guarantees for regular
files (we try to limit the possibilities of segfault).
--
___
Python tracker rep...@bugs.python.org
Antoine Pitrou added the comment:
Updated patch, a bit faster yet. After issue16531 is committed, it is now ~15x
faster than 3.4.
--
Added file: http://bugs.python.org/file35233/faster_collapse2.patch
___
Python tracker rep...@bugs.python.org
Donald Stufft added the comment:
Just an update, the issue is fixed in urllib3 and that has been pulled into
requests. Requests is currently prepping to release a new version which I'll
pull into pip and issue a pip 1.5.6 release which can be pulled into CPython
which should fix this.
Skip Montanaro added the comment:
Can this change be (easily) tested? If so, a test case akin to your original
example would be nice.
--
nosy: +skip.montanaro
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue21469
New submission from Antoine Pitrou:
Now that issue #16531 has been committed, it becomes possible to make some
operations faster. Attached patch makes summarize_address_range() ~2x faster
and Network.subnets() ~4x faster.
--
components: Library (Lib)
files: ipaddr_perf.patch
keywords:
Roundup Robot added the comment:
New changeset ef49aaad3812 by Victor Stinner in branch '3.4':
Issue #21422: Add a test to check that bool int and bool int return an int
http://hg.python.org/cpython/rev/ef49aaad3812
New changeset 3da4aed1d18a by Victor Stinner in branch 'default':
(Merge 3.4)
STINNER Victor added the comment:
Ok, 3 core dev are opposed to the change, I close the issue.
I added a test on bool int and bool int to ensure that the result is an
int.
--
resolution: - rejected
status: open - closed
___
Python tracker
Changes by Ned Deily n...@acm.org:
--
nosy: +michael.foord
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue21478
___
___
Python-bugs-list mailing
STINNER Victor added the comment:
My main motivation was to use calloc() (issue #21419) for 2**n. It looks like
using calloc() for this is only useful for very rare cases (very large value of
n: result larger than 1 MB). I close the issue.
--
resolution: - rejected
status: open -
STINNER Victor added the comment:
The optimization of 2**n looks to be only useful for very large value of n,
result larger than 1 MB. This use case is very rare, and you should probably
use another library (GMP, numpy, or something else) for such large numbers. I
close the issue.
--
Michael Foord added the comment:
Mock objects detect when another mock is added as a child, but they don't
currently detect that a function created by autospec has been added. It should
be a fairly easy fix.
--
assignee: - michael.foord
___
Python
Changes by Michael Foord mich...@voidspace.org.uk:
--
nosy: +kushal.das
stage: - needs patch
versions: +Python 3.5
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue21478
___
Francisco Martín Brugué added the comment:
I Victor you were so fast, I started with one patch also in bool (at least the
place was right). The problem is that I was getting some extrage (for me at
least). As far I hat:
def test_shifted_true(self):
with
STINNER Victor added the comment:
What I was doing wrong?
The is operator should only be used to compare identical objects. Small
integers (range -5..255 if I remember correctly) are singletons. I prefer to
not rely on this implementation detail in a unit test of the Python standard
STINNER Victor added the comment:
For example, hCryptProv in Python/random.c is inheritable or not?
This is not a standard handle. GetHandleInformation() fails with a Windows
error 6 (invalid descriptor).
I listed inheritable handles with a loop on range(0, 0x1001): only handles of
stdin,
Roundup Robot added the comment:
New changeset c0404f0da01a by Victor Stinner in branch '3.4':
Issue #21485: remove unnecesary .flush() calls in the asyncio subprocess code
http://hg.python.org/cpython/rev/c0404f0da01a
New changeset 3c26389d741c by Victor Stinner in branch 'default':
(Merge
STINNER Victor added the comment:
I wrote the example and the first call to buffer.flush() is a mistake. Thanks
for your patch, I applied it.
--
resolution: - fixed
status: open - closed
___
Python tracker rep...@bugs.python.org
STINNER Victor added the comment:
MT is equidistributed. This a major point in its favor but also implies that
there are long stretches of uninteresting sequences. When we seed with only
a subset the state space, there is a risk of systematically landing in those
stretches.
What is an
STINNER Victor added the comment:
Py_MIN(SOMAXCONN, 128)
On Windows, it's not the best choice to use this hardcoded limit.
socket.SOMAXCONN is 2^31-1.
listen() documentation says that Windows chooses a reasonable backlog value for
you if you pass SOMAXCONN:
Tim Peters added the comment:
[haypo]
What is an uninteresting sequence? What are the problem of these
sequences?
A sequence that would greatly surprise a user. For example, if you generate
32-bit ints from the Twister in one obvious way, there are starting places
where you'll get 623
STINNER Victor added the comment:
A sequence that would greatly surprise a user.
No user complained past years. I don't think that we should worry so much,
because it looks like reading more data from /dev/urandom can be a more serious
and concrete issue.
--
R. David Murray added the comment:
Arfrever's advice was misleading...the test would have needed to be
assertIsNot(True 0, 1), but the fact that True is not preserved is not
really what we want to test. What we want to test is that the return value is
of type 'int', which is what Victor's
Tim Peters added the comment:
[haypo]
No user complained past years.
Raymond said We've previously had this problem with MT (since resolved, where
it is was landed in a very non-random zone). Do you believe he was wrong?
I don't think that we should worry so much, because it looks like
STINNER Victor added the comment:
An article suggests to use max(1024, socket.SOMAXCONN) (to listen() backlog as
large as possible) instead of socket.SOMAXCONN because the OS maximum can be
larger than SOMAXCONN (and that it's not possible in Python to get the OS
value):
Antoine Pitrou added the comment:
There is no useful theory that allows us to predict the
characteristics of the produced sequences from a set of possible
seeds, so limiting the set of possible seeds is potentially dangerous.
I still find it difficult to understand where is the said danger.
R. David Murray added the comment:
Arfrever pointed out on irc that I misread. It would indeed be assertIs(True
0, 1), but that wouldn't make a good test because the fact that '1 is 1' is
an implementation detail of CPython and can't be relied upon.
--
Changes by STINNER Victor victor.stin...@gmail.com:
--
nosy: +gvanrossum, haypo, yselivanov
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue21437
___
Roundup Robot added the comment:
New changeset cee528d44b1e by Victor Stinner in branch '3.4':
Issue #21418: Fix a crash in the builtin function super() when called without
http://hg.python.org/cpython/rev/cee528d44b1e
New changeset 53cf343c4fff by Victor Stinner in branch 'default':
(Merge
STINNER Victor added the comment:
While embedding the Python interpreter in an application, I have encountered a
crash when the built-in function 'super' is invoked with no arguments.
This is not supported. When super() is invoked with no arguments, the class is
retrieved (indirectly) from
Changes by STINNER Victor victor.stin...@gmail.com:
--
resolution: - fixed
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue21418
___
Tim Peters added the comment:
[pitrou]
I still find it difficult to understand where is the said danger.
The theoretical properties that make the Twister so attractive were all proved
based on mathematical analysis of its entire period. The only way to get at
the whole period is to allow
New submission from Brad Aylsworth:
The documentation page for codecs
(https://docs.python.org/2/library/codecs.html) shows keyword arguments for
codecs.encode and codecs.decode, but they throw an error if keyword arguments
are used. codecs.decode.__doc__ reports 'decode(obj,
STINNER Victor added the comment:
Can we now close this issue?
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue21088
___
___
Python-bugs-list
Changes by Mark Nottingham m...@mnot.net:
--
nosy: +mnot
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue21308
___
___
Python-bugs-list mailing list
Antoine Pitrou added the comment:
The theoretical properties that make the Twister so attractive were
all proved based on mathematical analysis of its entire period. The
only way to get at the whole period is to allow for all possible
seeds.
If the seeds Python can use are drawn from a
STINNER Victor added the comment:
With the development version (Python 3.5), I reproduce the crash when Python is
compiled in debug mode:
$ ./python astlinenotest.py
python: Python/compile.c:3975: assemble_lnotab: Assertion `d_lineno = 0'
failed.
Abandon (core dumped)
The problem is that
Tim Peters added the comment:
Thanks for the explanation. It's much clearer now.
Maybe, but it's also overblown - LOL ;-) That is, no matter what the starting
seed, the user will see a microscopically tiny span of the Twister's entire
period. So all those provably correct properties that
New submission from Matthew Fernandez:
Perhaps others wouldn't consider this a bug, but it was definitely surprising
to me. When switching between optimisation levels -OO (optimise and strip
docstrings) and -O (just optimise), you will find the docstrings are still
stripped. E.g.
$ ls
STINNER Victor added the comment:
Victor: sure; see attached.
Ok, so the error occurs when Python tries to import the _heapq dynamic module:
PyModule_Create2() calls PyThreadState_Get() to retrieve to current thread, but
it fails. There is a current thread because PyModule_Create2() is
Antoine Pitrou added the comment:
Not really intentional, it's just a limitation of the current implementation
(where the same .pyo files are used for both -O and -OO). Already reported as
issue1538778 (which was closed as won't fix).
--
nosy: +barry, pitrou
superseder: - pyo's are
Roundup Robot added the comment:
New changeset 89a29e92416f by Victor Stinner in branch '3.4':
Issue #21398: Fix an unicode error in the pydoc pager when the documentation
http://hg.python.org/cpython/rev/89a29e92416f
New changeset 3424d65ad5ce by Victor Stinner in branch 'default':
(Merge 3.4)
STINNER Victor added the comment:
I fixed the initial bug and so I close the issue.
Open a new issue if you have an idea to restore the terminal state when the
pager breaks the terminal. I don't think that it's possible to save/restore the
terminal state in a portable way.
--
Matthew Fernandez added the comment:
Ah thanks, Antoine. Sorry, failed to find that issue in my prior searching.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue21489
___
Roundup Robot added the comment:
New changeset 7d20e30bd540 by Eric Snow in branch '3.4':
Issue #21226: Set all attrs in PyImport_ExecCodeModuleObject.
http://hg.python.org/cpython/rev/7d20e30bd540
New changeset bc324a49d0fc by Eric Snow in branch 'default':
Merge from 3.4 (for #21226).
Changes by Eric Snow ericsnowcurren...@gmail.com:
--
resolution: - fixed
stage: patch review - resolved
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue21226
___
1 - 100 of 119 matches
Mail list logo