Ned Deily added the comment:
The program works as expected. After the first two writes, the buffer contains
b'abcdef'. Then the seek(0) moves the stream pointer to the beginning of the
buffer and the next write overwrites buffer positions 0 through 2, replacing
b'abc' with b'xyz'. So now
Juan Javier added the comment:
Ok, you are right, serialized is the right name. Also, passing the lock to the
decorator will the correct option.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15634
Juan Javier added the comment:
What about this?
def serialized(lock):
def _serialized(func):
def __serialized(*args, **kwds):
with lock:
return func(*args, **kwds)
__serialized.__doc__ = func.__doc__
return __serialized
return
New submission from Stefan Holek:
After upgrading 3.3.0b1 to b2 (make install to same location) I noticed that
the Grammar pickles for beta.2 were missing (the beta.1 pickles still being
there).
The result is permission errors and/or virtualenv SandboxViolations, when 2to3
is used for the
Robin Schreiber added the comment:
Fixed the dealloc-methods of the types, for proper type dereferencing.
--
Added file: http://bugs.python.org/file26797/csv_pep384_v2.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue14935
Changes by Robin Schreiber robin.schrei...@me.com:
--
versions: +Python 3.4 -Python 3.3
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue14935
___
Stefan Krah added the comment:
Should we go all the way and also explicitly fill the small int cache?
Integers 0-255 should be initialized already, but I'm not sure
about [-5..-1] and 256. I haven't been able to create a test case
for integers though.
--
Added file:
Senthil Kumaran added the comment:
Hi Chris Eli, - Sorry that I missed this issue.
Chris - agree to your rationale. I can see how having self.left and self.right
documented can add value, The diff example was useful. Initially, I did have
some doubts in terms how it could be useful when the
Matthias Klose added the comment:
the configure step sets LIBDIR to /usr/local/lib64. Please find out why this is
not set to /usr/local/lib.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15631
Senthil Kumaran added the comment:
As this is not adding any feature, but just an additional clarification to the
existing attribute together with some useful documentation, I believe this can
go in 2.7, 3.2 and 3.3
Please correct me if I am wrong here.
--
versions: +Python 2.7,
Chris Jerdonek added the comment:
Thanks a lot, Senthil. I appreciate it.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15269
___
___
Chris Jerdonek added the comment:
Updating patch to tip again.
--
Added file: http://bugs.python.org/file26799/issue-15543-5.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15543
___
Stefan Krah added the comment:
Here is a patch implementing by-value comparisons for all format strings
understood by the struct module. It is slightly longer than promised, since
for larger arrays it is necessary to cache an unpacking object for acceptable
performance. The fast path for
New submission from Richard Oudkerk:
If the if __name__ == '__main__' idiom is not used on Windows you can get the
recursive starting of new processes.
This is because importing the main module in a child process starts a new child
process as a side effect.
There is a test intended to
New submission from Matthias Klose:
2.7 only:
isdir should not be exported, but a local symbol instead (this was accidentally
changed after the 2.7.3 release.
currently defined and used in Modules/getpath.c and Python/import.c, and used
in Python/bltinmodule.c
proposal to rename the
Chris Jerdonek added the comment:
only one Popen instance (for the iconv call), but different encodings
for stdin and stdout.
Isn't that the exception rather than the rule? I think it actually makes
sense, in at least 99.83% of cases ;-), to have a common encoding
setting for all streams.
New submission from Chris Jerdonek:
The --help documentation for the python executable says--
PYTHONIOENCODING: Encoding[:errors] used for stdin/stdout/stderr.
However, PYTHONIOENCODING doesn't seem to be respected for the python
executable's refs output to stderr. For example, this--
args
Changes by R. David Murray rdmur...@bitdance.com:
--
nosy: +benjamin.peterson
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15645
___
___
Roundup Robot added the comment:
New changeset e4fe1daef9f7 by Richard Oudkerk in branch '2.7':
Issue #15646: Prevent equivalent of a fork bomb when using multiprocessing
http://hg.python.org/cpython/rev/e4fe1daef9f7
New changeset 20f8a2455ffb by Richard Oudkerk in branch '3.2':
Issue #15646:
Xavier Morel added the comment:
Correction: csv also seems to raise csv.Error if the file contains NUL bytes:
Error: line contains NULL byte
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15639
Roundup Robot added the comment:
New changeset e0e8e70e4035 by Andrew Svetlov in branch '3.2':
Issue #14167: Document return statement in finally blocks.
http://hg.python.org/cpython/rev/e0e8e70e4035
New changeset 05714e9811fa by Andrew Svetlov in branch 'default':
Issue #14167: Document return
Andrew Svetlov added the comment:
Fixed. Thanks.
--
resolution: - fixed
stage: needs patch - committed/rejected
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue14167
___
Nikolaus Rath added the comment:
The call should be read(size), with size a number. I will make sure to check
size, fp, length, chunked and chunk_left when it happens the next time.
--
___
Python tracker rep...@bugs.python.org
Daniel Ellis added the comment:
Thank you for the review Eli. I've made your changes and attached the updated
patch. I did run all of the code snippets that are being added on 2.7, and the
only thing I found different was the changed print statement. I don't believe
I overlooked anything,
Roundup Robot added the comment:
New changeset ffd70c371fee by R David Murray in branch '2.7':
#9161: Fix test to use standard optparse test pattern (what was I thinking?)
http://hg.python.org/cpython/rev/ffd70c371fee
--
___
Python tracker
Stefan Mihaila added the comment:
Maybe we could postpone the review process for a few days
until I fix some known issues
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15642
___
umedoblock added the comment:
thanks Ned.
I understood your comment.
I'm happy!
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15644
___
___
Stefan Krah added the comment:
I didn't get my own comments as mail, so this is just a notification that I've
answered Nick's comments.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15573
Stan Seibert added the comment:
FYI: This bug still exists using the version of clang shipped with OS X 10.8.
Tested with Python 3.3.0b2 and:
Apple clang version 4.0 (tags/Apple/clang-421.0.57) (based on LLVM 3.1svn)
Target: x86_64-apple-darwin12.0.0
Thread model: posix
--
nosy:
Changes by Richard Oudkerk shibt...@gmail.com:
--
resolution: - fixed
stage: - committed/rejected
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15646
___
Matthias Klose added the comment:
fixed for 2.7, made isdir static on windows and posix
--
resolution: - fixed
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15647
___
New submission from Andrew Svetlov:
Currently Popen.communicate accept str is universal_newlines==True and bytes if
universal_newlines==False.
I like to accept both str and bytes if universal_newlines is False and raise
explicit exception for bytes if universal_newlines is True.
Looks like
Roundup Robot added the comment:
New changeset 839bd8f98539 by Andrew Svetlov in branch '3.2':
Add test to explicit check the absence regression in subprocess (issue #15592).
http://hg.python.org/cpython/rev/839bd8f98539
New changeset 9d86480cc177 by Andrew Svetlov in branch 'default':
Issue
Roundup Robot added the comment:
New changeset bdd1b2228c14 by Matthias Klose in branch '2.7':
- Issue #15647: Make isdir static for windows and posix
http://hg.python.org/cpython/rev/bdd1b2228c14
--
nosy: +python-dev
___
Python tracker
Changes by Andrew Svetlov andrew.svet...@gmail.com:
--
components: +Library (Lib)
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15649
___
___
Andrew Svetlov added the comment:
Close the issue. Thanks, Chris.
It was the real regression, 3.2 works fine.
See also #15649 for accepting str if not universal_newlines.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15592
Changes by Andrew Svetlov andrew.svet...@gmail.com:
--
nosy: +asvetlov
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15204
___
___
Chris Jerdonek added the comment:
Thanks, Andrew!
--
resolution: - fixed
stage: patch review - committed/rejected
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15592
Brett Cannon added the comment:
I had a minute free so I just tried inserting an empty module into sys.modules
and then importing an extension module to see if it would get reused. It
doesn't. imp.load_dynamic() actually just blindly overwrites what is in
sys.modules. I'm willing to bet it
Chris Jerdonek added the comment:
What to do if stdin doesn't have `encoding` attribute? Convert to bytes using
filesystemencoding?
If choosing an encoding, it probably makes sense to default to the same as for
when universal_newlines=True, namely locale.getpreferredencoding(False).
Andrew Svetlov added the comment:
I think current behavior is correct.
Every doctest is docstring from tested module, but not every docstring is a
valid doctest.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue14649
Chris Jerdonek added the comment:
To my previous comment, issue 15648 shows the case where I was able to change
the encoding for stdout in the child process but not stderr (which would
require supporting two encodings in Popen to handle).
--
___
R. David Murray added the comment:
Chris isn't suggesting changing the behavior, just the error message. I agree
with his change for exactly the reason you say: currently doctest doesn't
complain if a module does have docstrings but none of those docstrings are
tests. So a module could have
Robin Schreiber added the comment:
Fixed _dealloc methods. Also: Init now returns the previously initialized
module if available.
--
Added file:
http://bugs.python.org/file26803/_datetimemodule_pep3121-384_v1.patch
___
Python tracker
New submission from Robin Schreiber:
Changes proposed in PEP3121 and PEP384 have now been applied to the dbm module!
--
components: Extension Modules
files: _dbmmodule_pep3121-384_v0.patch
keywords: patch
messages: 168216
nosy: Robin.Schreiber
priority: normal
severity: normal
status:
Andrew Svetlov added the comment:
Add Alexander Belopolsky to nosy list as maintainer of datetime module.
--
nosy: +belopolsky
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15390
___
New submission from Robin Schreiber:
Changes proposed in PEP3121 and PEP384 have now been applied to the elementtree
module!
--
components: Extension Modules
files: _elementtree_pep3121-384_v0.patch
keywords: patch
messages: 168217
nosy: Robin.Schreiber
priority: normal
severity:
Changes by Robin Schreiber robin.schrei...@me.com:
--
nosy: +effbot
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15651
___
___
Python-bugs-list
New submission from Robin Schreiber:
Changes proposed in PEP3121 and PEP384 have now been applied to the gdbm module!
--
components: Extension Modules
files: _gdbm_pep3121-384_v0.patch
keywords: patch
messages: 168219
nosy: Robin.Schreiber, anthony_baxter
priority: normal
severity:
New submission from Robin Schreiber:
Changes proposed in PEP3121 and PEP384 have now been applied to the hashopenssl
module!
--
components: Extension Modules
files: _hashopenssl_pep3121-384_v0.patch
keywords: patch
messages: 168220
nosy: Robin.Schreiber, gstein
priority: normal
New submission from Robin Schreiber:
Changes proposed in PEP384 have now been applied to the bz2 module!
--
components: Extension Modules
files: _bz2_pep384_v0.patch
keywords: patch
messages: 168221
nosy: Robin.Schreiber
priority: normal
severity: normal
status: open
title: PEP 384
New submission from Robin Schreiber:
Changes proposed in PEP3121 and PEP384 have now been applied to the json module!
--
components: Extension Modules
files: _json_pep384_v0.patch
keywords: patch
messages: 168222
nosy: Robin.Schreiber
priority: normal
severity: normal
status: open
New submission from Sandro Tosi:
Hello,
this has been reported at
http://mail.python.org/pipermail/docs/2012-July/009223.html but since I have no
experience to judge if it's correct or not, i'll just report it:
I've recenty started to try using C code in python using the wonderful
python
Antoine Pitrou added the comment:
+m = PyState_FindModule(_hashlibmodule);
+if(!m){
+m = PyModule_Create(_hashlibmodule);
+if (m == NULL)
+return NULL;
+} else {
+Py_INCREF(m);
+return m;
+}
Why is this dance needed?
+if((void
Changes by Antoine Pitrou pit...@free.fr:
--
stage: - patch review
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15653
___
___
Python-bugs-list
Antoine Pitrou added the comment:
Something else:
+#define _hashlibstate(o) ((_hashlibstate *)PyModule_GetState(o))
It is really bad style to #define a symbol that shadows another symbol.
Since it's a #define, I would expect to be named something like STATE(o).
--
New submission from Sandro Tosi:
Hello,
it has been reported at
http://mail.python.org/pipermail/docs/2012-April/008215.html but given it
raises some question whether it's a bug in the doc or in the code, i'd rather
report the issue here and hear what other think:
In the Python 3.2.2
Antoine Pitrou added the comment:
+// in case init is called multiple times within one interpreter,
+// we do not have to repeat all of the initialization
First, you shouldn't use C++-style comments (//).
Second, I find this comment a bit weird. Even if init is called a second time,
Chris Jerdonek added the comment:
Every doctest is docstring from tested module, but not every docstring is a
valid doctest.
Actually, I'm not sure even this is correct. doctest will form a unittest
*TestSuite* from a module if it has docstrings, but it will not necessarily
create a test
Antoine Pitrou added the comment:
+Py_CLEAR(_datetimemodulestate(m)-PyDateTime_DateTimeType);
+Py_CLEAR(_datetimemodulestate(m)-PyDateTime_DeltaType);
+Py_CLEAR(_datetimemodulestate(m)-PyDateTime_TimeType);
+Py_CLEAR(_datetimemodulestate(m)-PyDateTime_TimeZoneType);
+
Antoine Pitrou added the comment:
Same review comments as in issue15653.
--
nosy: +pitrou
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15654
___
Antoine Pitrou added the comment:
See issue15390 review comments :)
--
nosy: +eli.bendersky, pitrou
stage: - patch review
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15651
___
Chris Jerdonek added the comment:
I suspect the intent was to raise an error if there were no *tests*, not if
there were no docstrings.
That, or the implementor thought that if no docstrings were found, then that
might indicate something went wrong with the parsing.
For background
R. David Murray added the comment:
That's a good question. Perhaps you could argue for it as a bug fix since it
doesn't seem to be documented either way...except for the 'exclude_empty'
argument of testmod. If testmod throws an error when there are no docstrings
instead of returning a 0
Changes by Michael Welsh Duggan m...@sei.cmu.edu:
--
nosy: +md5i
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15657
___
___
Python-bugs-list
Robin Schreiber added the comment:
Regarding the macro definition, I would be fine with changing it to
_hashlib_state.
The dance you have found inside the Init, makes shure that the very same module
is returned if Init is called twice or multiple times, before the Module is
unloaded. A month
Antoine Pitrou added the comment:
The last code snipped verifies, that we only dereference the type if
the dealloc function is not being called from inside the
subtype_dealloc function. This is necessary because the
subtype_dealloc function itself contains a decref of the respective
type
Robin Schreiber added the comment:
Hey Antoine,
This comment describes exactly what I intended with the dance in issue15653.
For example the json testsuite issued multiple calls to the init function
before unloading and consequently clearing the module.
However it seems as if the behavior
Changes by Nadeem Vawda nadeem.va...@gmail.com:
--
nosy: +nadeem.vawda
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15654
___
___
Robin Schreiber added the comment:
Well, as I have changed the static type to a HeapType (as I am now using the
stable ABI from PEP 384 for this type), we have to start perfoming proper
reference counting with this object. This includes increfing the type in case a
new object of that type is
Robin Schreiber added the comment:
Incidentally, I am deeply sorry for the C++-Style comments. I thought those
would be detected by the patchcheck.py.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15655
Antoine Pitrou added the comment:
Le mardi 14 août 2012 à 19:55 +, Robin Schreiber a écrit :
As of now, I do not know of HeapTypes being excluded from refcounting.
No, but see http://bugs.python.org/issue15142
It's not obvious to me that the type should be explicitly decref'ed from the
Robin Schreiber added the comment:
As subtype_dealloc decref'ed the HeapType I thought the dealloc method was the
most appropriate place to decrement the refcount of the type.
However you still agree that these types need to be recounted properly, don't
you? In that case, where would you place
Antoine Pitrou added the comment:
Le mardi 14 août 2012 à 20:16 +, Robin Schreiber a écrit :
However you still agree that these types need to be recounted
properly, don't you?
Yes, of course.
In that case, where would you place the decref of the type?
That's a good question. Perhaps
Serhiy Storchaka added the comment:
Patch updated. Now private pyobjects (readnl, accu) counted.
Note all three patches rather different.
--
Added file: http://bugs.python.org/file26810/stringio_sizeof-3.3_2.patch
___
Python tracker
Changes by Serhiy Storchaka storch...@gmail.com:
Added file: http://bugs.python.org/file26811/stringio_sizeof-3.2_2.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15490
___
Changes by Serhiy Storchaka storch...@gmail.com:
Added file: http://bugs.python.org/file26812/stringio_sizeof-2.7_2.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15490
___
Serhiy Storchaka added the comment:
Patches updated to reflect Antoine's comments.
--
Added file: http://bugs.python.org/file26813/istrue_check-3.3_2.patch
Added file: http://bugs.python.org/file26814/istrue_check-3.2_2.patch
Added file:
New submission from Oskars:
For some years I used Python with IDLE, including my Windows 7 machine. In
January IDLE stopped working. Whenever I tried to open with file with IDLE,
nothing happened. No error message. Nothing.
After some help from h...@python.org I typed at the command line
Chris Jerdonek added the comment:
Senthil, here is a recent e-mail and response in which I asked about
documentation changes and adding tests during feature freeze:
http://mail.python.org/pipermail/python-dev/2012-July/121138.html
Also, here is a recent example of a documentation
Chris Jerdonek added the comment:
The problem seems to be restricted only to DocTestSuite. testmod and
DocTestFinder both seem to work fine. DocTestSuite calls DocTestFinder but not
the other way around: nothing calls DocTestSuite.
If in certain versions we do not treat raising the
Raymond Hettinger added the comment:
The only people affected by deprecating U are the people who are currently
using it for some reason -- presumably they are expecting that it does
something useful for their code.
Ideally, this proposed deprecation should be mentioned on python-dev so that
R. David Murray added the comment:
Yeah, we might as well be consistent, though it's not a big deal either way.
I'd prefer that as a separate patch.
Any interest in backporting this to 2.7? Being so close to final release on
3.2 I think we can skip 3.2, unless you feel like doing it.
R. David Murray added the comment:
I believe this is a duplicate of issue 4625.
--
nosy: +r.david.murray
resolution: - duplicate
stage: - committed/rejected
status: open - closed
superseder: - IDLE won't open anymore, .idlerc unaccessible
type: crash - behavior
Chris Jerdonek added the comment:
Sure, I'd be happy to do both 2.7 and 3.2. I can upload the patch for the
default branch as a delta to apply after the 3.2 change has been forward-ported
from 3.2 to default. Thanks for taking an interest in this!
--
versions: +Python 2.7, Python
New submission from Michael:
if I import any python script in the beginning of the code in then I haver next
errors:
Error in atexit._run_exitfuncs:
Traceback (most recent call last):
File /usr/lib/python2.7/atexit.py, line 24, in _run_exitfuncs
func(*targs, **kargs)
File
R. David Murray added the comment:
The example you uploaded doesn't call multiprocessing, yet the traceback you
show does. Can you provide more details on what you are actually doing? Note
that if you are importing a module that does a fork when it is imported, you
are doing something
Roundup Robot added the comment:
New changeset 7590dec388a7 by R David Murray in branch '3.2':
#15269: document dircmp.left and right, and add tests for them.
http://hg.python.org/cpython/rev/7590dec388a7
New changeset c592e5a8fa4f by R David Murray in branch 'default':
Merge #15269: document
R. David Murray added the comment:
Thanks, Chris.
--
nosy: +r.david.murray
resolution: - fixed
stage: - committed/rejected
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15269
Éric Araujo added the comment:
I noticed a long-standing typo in the latest commit: the country is named
Liechtenstein :)
--
nosy: +eric.araujo
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15586
Changes by Éric Araujo mer...@netwok.org:
--
nosy: +r.david.murray
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15649
___
___
Python-bugs-list
Changes by Jesús Cea Avión j...@jcea.es:
--
nosy: +jcea
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15657
___
___
Python-bugs-list mailing list
Michael added the comment:
thanks David,
scripts which I imported were relying on some librarary which I did not
understand. I was able to get rid of it and I don't have these errors any more.
It was bug in my program. Thank you again.
--
resolution: - fixed
status: open - closed
Nick Coghlan added the comment:
Yeah, as soon as I got your email I realised I'd only been searching for usage
*in the patch* rather than the full file. Oops :(
More comments in the review.
--
___
Python tracker rep...@bugs.python.org
New submission from py.user:
'{:02}'.format('a')
Traceback (most recent call last):
File stdin, line 1, in module
ValueError: '=' alignment not allowed in string format specifier
according to http://docs.python.org/py3k/library/string.html#formatspec
the default alignment is '' or ''
Changes by Ezio Melotti ezio.melo...@gmail.com:
--
nosy: +eric.smith, ezio.melotti
stage: - needs patch
versions: +Python 2.7, Python 3.3, Python 3.4
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15660
py.user added the comment:
found a small string in the doc about zero padding, which enables alignment
equal to =
--
versions: -Python 2.7, Python 3.3, Python 3.4
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15660
Raymond Hettinger added the comment:
I also agree that the itertools module doesn't need this. (Reasons of
symmetry are insufficient to make the module fatter that it already is). In
addition, there are already a number of simple ways to do this.
--
resolution: - rejected
status:
98 matches
Mail list logo