Jesús Cea Avión added the comment:
Precedence ordered per row. Same row, same precedence. I don't see any problem.
It is natural math precedence. Closed as invalid.
--
nosy: +jcea
resolution: - invalid
___
Python tracker rep...@bugs.python.org
Changes by Mark Dickinson dicki...@gmail.com:
--
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16438
___
___
Brett Cannon added the comment:
This is a feature request so it won't change in Python 2.7.
As for progress, the answer is no as the hope is to eventually replace
zipimport with something in pure Python thanks to importlib.
--
versions: +Python 3.4 -Python 2.7, Python 3.3
Brett Cannon added the comment:
The fully qualified name requirement is definitely a design flaw where init
functions should just be given the module object with everything already set,
just like what @importlib.util.module_for_loader does. Hopefully we can come up
with a solution through
New submission from Yongzhi Pan:
http://docs.python.org/3/library/stdtypes.html#str.title
The second snippets is not collapsed correctly.
--
assignee: docs@python
components: Documentation
messages: 175171
nosy: docs@python, fossilet
priority: normal
severity: normal
status: open
Changes by Jesús Cea Avión j...@jcea.es:
--
nosy: +jcea
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16439
___
___
Python-bugs-list mailing list
Yongzhi Pan added the comment:
I mean the text at the first link need fix. '+' and '-' are not on the same
row. And the doc says: sorted by ascending priority, that means they have
ascending priority.
The table in the reference is just right.
--
Jesús Cea Avión added the comment:
Looks like a sphinx bug :-??.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16439
___
___
Python-bugs-list
New submission from Yongzhi Pan:
http://docs.python.org/3/library/stdtypes.html#methods
Attempting to set a method attribute results in a TypeError being raised.
But in the example, if we do c.method.whoami = 'c', we get AttributeError
instead of TypeError.
--
assignee: docs@python
Andrew Svetlov added the comment:
No, it isn't sphinx bug, it's markup problem.
Will commit a fix in few minutes.
--
nosy: +asvetlov
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16439
___
New submission from Chris Withers:
gzip.py uses range instead of xrange in two places.
This results in excessive memory usage when opening large .gz files.
I actually bumped into this using tarfile.
Am I right in thinking that range basically *is* xrange in 3.x? If so, this bug
applies only to
Roundup Robot added the comment:
New changeset aeb5c53a1d69 by Andrew Svetlov in branch '3.2':
Issue #16439: Fix markup in example for stdtypes.
http://hg.python.org/cpython/rev/aeb5c53a1d69
New changeset 65499860c6f8 by Andrew Svetlov in branch '3.3':
Merge issue #16439: Fix markup in example
Jesús Cea Avión added the comment:
You are right, Yongzhi Pan. Reopening. Not sure how to solve it. Delegating to
docs@python.
--
resolution: invalid -
status: closed - open
___
Python tracker rep...@bugs.python.org
Andrew Svetlov added the comment:
Fixed. Thanks.
--
resolution: - fixed
stage: - committed/rejected
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16439
___
Serhiy Storchaka added the comment:
Here is a patch that introduces four private function for convert an integer to
uid_t/gid_t and back, and consistently apply these functions in all cases of
uid_t/gid_t conversions. This should fix this issue and issues 4591, 7365,
15301, and a part of
Jesús Cea Avión added the comment:
Yes, range() in python 3 is equivalent to python 2 xrange().
2.6 is in security only fix mode. So, you only need to fix 2.7.
--
nosy: +jcea
___
Python tracker rep...@bugs.python.org
Changes by Jesús Cea Avión j...@jcea.es:
--
versions: -Python 2.6
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16441
___
___
Python-bugs-list
Jesús Cea Avión added the comment:
Good catch. I was not aware of this feature :-).
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16439
___
___
New submission from Trent Nelson:
Two immediate issues identified whilst trying to build on HP-UX and IRIX:
1. Our source is wildly inconsistent with regards to using PATH_MAX versus
MAXPATHLEN.
2. The current logic in osdefs.h is insufficient for ensuring one or the other
always has a
Chris Withers added the comment:
Okay, here's the patch.
I can't imagine any unit tests are needed or will be impacted by this.
I do have commit rights, am I good to commit this?
--
keywords: +patch
stage: needs patch - patch review
Added file:
Serhiy Storchaka added the comment:
I think here should be used something like CommonTest.test_nonascii_abspath()
in Lib/test/test_genericpath.py.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16218
Nadeem Vawda added the comment:
Looks good to me. Go ahead.
You needn't add or change any tests for this, but you should run the
existing tests before committing, just to be safe.
--
nosy: +nadeem.vawda
___
Python tracker rep...@bugs.python.org
Stefan Behnel added the comment:
Triggered discussion on python-dev:
http://thread.gmane.org/gmane.comp.python.devel/135764
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13429
___
New submission from Raymond Hettinger:
The match objects currently do not have useful docstrings. An easy task is to
add docstrings modeled after the text in the regular docs.
import re
mo = re.search('abc', 'abc')
help(mo)
--
assignee: docs@python
components: Documentation
Changes by Meador Inge mead...@gmail.com:
--
nosy: +meador.inge
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16438
___
___
Python-bugs-list
Chris Jerdonek added the comment:
Currently, the built-in types are not treated consistently as to whether their
constructors are documented in the Built-in Functions or Built-in Types
page. There are some open issues related to this topic (see, for example,
issue 16209).
For the purposes
Changes by Chris Jerdonek chris.jerdo...@gmail.com:
--
nosy: +ezio.melotti
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16436
___
___
R. David Murray added the comment:
Given the backward compatibility concerns, and the fact that brace expansion
and wildcard expansion are conceptually separate operations, perhaps what we
should have a is a glob.expand_braces (or some such name) function? (Note: I
haven't looked at whether
Changes by Chris Jerdonek chris.jerdo...@gmail.com:
--
title: Missing anchor in doc - Link directly to set and frozenset in built-in
function docs
type: - enhancement
versions: +Python 2.7, Python 3.2
___
Python tracker rep...@bugs.python.org
Chris Jerdonek added the comment:
I recommend copying for set and frozenset the documentation pattern for dict
(and in particular by stating explicitly in its own sentence that the object is
a class):
http://docs.python.org/3/library/functions.html#func-dict
--
Changes by Ezio Melotti ezio.melo...@gmail.com:
--
components: +Regular Expressions
nosy: +ezio.melotti, mrabarnett
stage: - needs patch
versions: -Python 3.1
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16443
Sasha B added the comment:
Ruby uses the Murmur hash for some types (string integer at least):
http://murmurhash.googlepages.com/
src: http://stackoverflow.com/a/3270836/1332819
The Perl hash implementation:
http://cpansearch.perl.org/src/NWCLARK/perl-5.8.8/hv.c
PHP5 hash implementation:
Changes by Ezio Melotti ezio.melo...@gmail.com:
--
keywords: +easy
nosy: +ezio.melotti
stage: - needs patch
type: - enhancement
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16438
___
Changes by Zachary Ware zachary.w...@gmail.com:
--
versions: +Python 3.2, Python 3.3, Python 3.4
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15861
___
Serhiy Storchaka added the comment:
Given the backward compatibility concerns, and the fact that brace expansion
and wildcard expansion are conceptually separate operations, perhaps what we
should have a is a glob.expand_braces (or some such name) function?
In this case it may be
Zachary Ware added the comment:
Just tested on 3.3 and this still happens with that version of Tkinter, which
should mean the same happens in 3.2 and 3.4.
--
nosy: +zach.ware
___
Python tracker rep...@bugs.python.org
Ezio Melotti added the comment:
Also remember to add a Misc/NEWS entry (and/or run `make patchcheck`) before
committing. If this only affects 2.7 there's no need to merge anything with
3.x, so you can just commit on 2.7 and push.
--
nosy: +ezio.melotti
Changes by Serhiy Storchaka storch...@gmail.com:
--
nosy: +serhiy.storchaka
stage: - needs patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15861
___
Christian Heimes added the comment:
I considered MurMur a year ago, too. Nowadays I don't think it's an option
anymore. JPA and DJB have released a C++ program that is able to generate lots
of collisions:
https://www.131002.net/siphash/
C++ program to find universal (key-independent)
Zachary Ware added the comment:
I don't think 2.7 and 3.3 were meant to be removed from this one and we're now
in 3.4 time.
--
nosy: +zach.ware
versions: +Python 2.7, Python 3.3, Python 3.4
___
Python tracker rep...@bugs.python.org
Christian Heimes added the comment:
From the header of murmurcollisions.cc:
* multicollisions for MurmurHash3
*
* MurmurHash3 C++ implementation is available at
* http://code.google.com/p/smhasher/wiki/MurmurHash3
*
* the function Murmur3Multicollisions finds many different inputs
*
Chris Jerdonek added the comment:
Isn't it better to do this type of within-doc linking with a :ref: (which would
prevent issues like this)?
--
nosy: +chris.jerdonek
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16435
Changes by Ezio Melotti ezio.melo...@gmail.com:
--
assignee: docs@python - ezio.melotti
nosy: +ezio.melotti
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16440
___
Changes by Gregory P. Smith g...@krypto.org:
--
assignee: - gregory.p.smith
nosy: +gregory.p.smith
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16409
___
New submission from STINNER Victor:
Attached patch changes how support.TESTFN_UNDECODABLE is computed on UNIX: use
the filesystem encoding in *strict* mode, not using the surrogateescape error
handler.
So we can use support.TESTFN_UNDECODABLE to check if a function uses correctly
the
STINNER Victor added the comment:
The patch contains two print to help debugging the patch itself, these print
statements must be removed later.
+print(TESTFN_UNDECODABLE = %a % TESTFN_UNDECODABLE)
+print(TESTFN_NONASCII = %a % TESTFN_NONASCII)
--
STINNER Victor added the comment:
We may also use support.TESTFN_UNDECODABLE
in test_cmd_line_script.test_non_ascii() on Windows
Oh, subprocess doesn't support passing bytes arguments to a program anymore
(since Python 3.0).
http://bugs.python.org/issue4036#msg100376
So it's better to use
New submission from Amaury Forgeot d'Arc:
The script below segfaults cpython2.7.
The cause is in BaseException_set_message(), which calls
Py_XDECREF(self-message) and thus can call back into Python code with a
dangling PyObject* pointer. Py_CLEAR should be used instead.
class Nasty(str):
Roundup Robot added the comment:
New changeset 8b181c75792f by Ezio Melotti in branch '2.7':
#16440: fix exception type and clarify example.
http://hg.python.org/cpython/rev/8b181c75792f
New changeset bb39ca6bcd7a by Ezio Melotti in branch '3.2':
#16440: fix exception type and clarify example.
New submission from Xavier de Gaye:
Also, the two oldest frames of the stack are identical (sic),
according to the printed traceback.
$ python3 foo.py
/tmp/foo.py(3)module()
- x = 1
(Pdb) import sys; print(sys.version)
3.2.2 (default, Dec 27 2011, 17:35:55)
[GCC 4.3.2]
(Pdb) list
1
Ezio Melotti added the comment:
Fixed, thanks for the report!
--
resolution: - fixed
stage: - committed/rejected
status: open - closed
type: - enhancement
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16440
Stefan Stuhr added the comment:
I think this is a case of faulty over-engineering in the ttk module. The
following works just fine (imports converted to Python3):
import tkinter as tk
import tkinter.ttk as ttk
root = tk.Tk()
tree = ttk.Treeview(root, columns=1 2 3)
tree.tk.call(tree, insert,
Changes by Ezio Melotti ezio.melo...@gmail.com:
--
keywords: +patch
stage: - patch review
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15680
___
Changes by STINNER Victor victor.stin...@gmail.com:
--
nosy: +haypo
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16445
___
___
Python-bugs-list
Ezio Melotti added the comment:
While this is documented for isinstance, I'm not sure it should be advertised
too much, as it seems to me an implementation detail and doesn't seem too
useful in practice.
This is a side-effect of the fact that
isinstance(x, (A, B, ...))
is equivalent to
STINNER Victor added the comment:
Please test the patch on UNIX, Windows and Mac OS X.
The full test suite pass on:
* Linux with UTF-8 locale encoding
* Linux with ASCII locale encoding
* Windows with cp932 ANSI code page
* Mac OS 10.8 with ASCII locale encoding (and utf-8/surrogateescape
New submission from Amaury Forgeot d'Arc:
Following script crashes all versions of Python. Cause is the
Py_DECREF(et-ht_name) in type_set_name().
class Nasty(str):
def __del__(self):
C.__name__ = other
class C(object):
pass
C.__name__ = Nasty(abc)
C.__name__ = normal
STINNER Victor added the comment:
According to Amaury an IRC, replacing Py_XDECREF(obj-attr); obj-attr =
NULL; pattern with Py_CLEAR(obj-attr); should fix the issue.
Instead of opening one issue per occurence of this pattern, it is possible to
write a semantic patch to do the replace on the
Changes by STINNER Victor victor.stin...@gmail.com:
--
keywords: +patch
Added file: http://bugs.python.org/file27930/python27_pyclear.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16445
STINNER Victor added the comment:
The spatch doesn't match the following macro:
Modules/_testcapimodule.c:#define UNBIND(X) Py_DECREF(X); (X) = NULL
--
Python/Python-ast.c is autogenerated from Parser/asdl_c.py, the .py file should
be fixed instead.
--
STINNER Victor added the comment:
python27_pyclear.patch does fix the use case described in msg175203, but it
doesn't fix #16447.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16445
___
STINNER Victor added the comment:
It looks like the bug is the pattern Py_DECREF(obj-attr); obj-attr =
new_value;. Replacing it with { PyObject *tmp = obj-attr; obj-attr =
new_value; Py_DECREF(tmp); } does fix this specific issue.
We can use the coccinelle tool to replace all such patterns in
Changes by STINNER Victor victor.stin...@gmail.com:
--
keywords: +patch
Added file: http://bugs.python.org/file27932/python27_decref_replace.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16447
STINNER Victor added the comment:
We should maybe use a macro (ex: Py_DECREC_REPLACE) instead of copying the
pattern { PyObject *tmp = obj-attr; obj-attr = new_value; Py_DECREF(tmp); }.
--
___
Python tracker rep...@bugs.python.org
STINNER Victor added the comment:
py_clear.spatch replaces:
Py_DECREF(obj-attr); obj-attr = NULL;
but also:
Py_DECREF(obj); obj = NULL;
If the second pattern is not dangerous, py_clear.spatch can be modified to only
match the first pattern: see py_decref_replace.spatch of issue #16447 for
101 - 165 of 165 matches
Mail list logo