Changes by Alexandre Vassalotti <[EMAIL PROTECTED]>:
Removed file: http://bugs.python.org/file9090/io-misc-fixes.patch
__
Tracker <[EMAIL PROTECTED]>
<http://bugs.pytho
Alexandre Vassalotti <[EMAIL PROTECTED]> added the comment:
Yes, that was a leak. It should be fixed now.
Merci Antoine!
Added file: http://bugs.python.org/file9899/bytesio+misc-fixes-4.patch
__
Tracker <[EMAIL PROTECTED]>
<http://bugs.pytho
Alexandre Vassalotti <[EMAIL PROTECTED]> added the comment:
Oops, I forgot to include the unit tests, with "svn add", when I made
the diff.
Added file: http://bugs.python.org/file9904/bytesio+misc-fixes-5.patch
__
Tracker <[EMAI
Alexandre Vassalotti <[EMAIL PROTECTED]> added the comment:
There is a small bug in the last patch I posted. The unit tests assumed
(wrongly) that accelerator module for io.StringIO (i.e., _stringio) was
present.
Added file: http://bugs.python.org/file9905/bytesio+misc-fixes-6
Alexandre Vassalotti <[EMAIL PROTECTED]> added the comment:
I think that check in write_bytes() is a guard to avoid resize_buffer()
from truncating the string stored in the buffer. However, I am not sure
if it is still necessary.
I don't know why help() doesn't work on BytesI
Alexandre Vassalotti <[EMAIL PROTECTED]> added the comment:
Python 3.0 shouldn't have any problem unpickling old-style classes.
However, they will be unpickled as new-style classes. Therefore, there
might be a few corner-cases that might cause some problems. For example,
if an old-
Alexandre Vassalotti <[EMAIL PROTECTED]> added the comment:
I revised the patch with respect to Alexander's comments. In summary,
here is what I changed from the previous patch:
- Removed the unnecessary "fixes" to Objects/structseq.c
and Modules/timemodule.
Alexandre Vassalotti <[EMAIL PROTECTED]> added the comment:
Here's an updated patch.
Added file: http://bugs.python.org/file10023/bytesio+misc-fixes-7.patch
__
Tracker <[EMAIL PROTECTED]>
<http://bugs.
Alexandre Vassalotti <[EMAIL PROTECTED]> added the comment:
Oops, I forgot again to "svn add" the new files.
Added file: http://bugs.python.org/file10024/bytesio+misc-fixes-8.patch
__
Tracker <[EMAIL PROTECTED]>
<http://
Changes by Alexandre Vassalotti <[EMAIL PROTECTED]>:
Removed file: http://bugs.python.org/file10023/bytesio+misc-fixes-7.patch
__
Tracker <[EMAIL PROTECTED]>
<http://bugs.pytho
Alexandre Vassalotti <[EMAIL PROTECTED]> added the comment:
Hi Guido,
The patch changes a minor things to io.py to allow io.BytesIO to pass my
test suite, so you may want to check it out. Other than that, I think
the review is going fine.
__
Tracker &
Alexandre Vassalotti <[EMAIL PROTECTED]> added the comment:
So, any comment on the latest patch?
If everything is all right, I would like to commit the patch to py3k.
__
Tracker <[EMAIL PROTECTED]>
<http://bugs.pytho
Alexandre Vassalotti <[EMAIL PROTECTED]> added the comment:
Guido fixed this issue in r61467.
Closing.
--
resolution: -> fixed
status: open -> closed
__
Tracker <[EMAIL PROTECTED]>
<http://bugs
Alexandre Vassalotti <[EMAIL PROTECTED]> added the comment:
Personally, I don't see how adding this feature would create a security
hole (or more properly said, grow the giant hole that are the GLOBAL and
REDUCE opcodes). I don't see either why this should be included in the
Changes by Alexandre Vassalotti <[EMAIL PROTECTED]>:
--
status: open -> pending
Tracker <[EMAIL PROTECTED]>
<http://bugs.python.org/issue558238>
___
Alexandre Vassalotti <[EMAIL PROTECTED]> added the comment:
This has almost no-chance to get included in the standard library. Also,
Python 2.6 will include ``namedtuple`` (see
http://docs.python.org/dev/library/collections.html#collections.namedtuple),
which provides similar functi
Alexandre Vassalotti <[EMAIL PROTECTED]> added the comment:
Bob Kline wrote:
> I just ran into this behavior with an attempt to pickle a dom tree
> for an XML document whose nesting level never got deeper than nine
> child nodes, and indeed it crashed the interpreter.
Pickling
Alexandre Vassalotti <[EMAIL PROTECTED]> added the comment:
Alexander Belopolsky wrote:
> The patch looks good. Just a question: I thought the strings returned
> by PyUnicode_AsStringAndSize are 0-terminated, while your patch at
> several places attempts to explicitly 0-terminate
Alexandre Vassalotti <[EMAIL PROTECTED]> added the comment:
Marc-Andre Lemburg wrote:
[SNIP]
> The above cast needs to be (Py_ssize_t). size_t is an unsigned length
type.
Actually, the cast is right (even though it is not strictly necessary).
It just the patch that is confusing. He
Alexandre Vassalotti <[EMAIL PROTECTED]> added the comment:
Committed to r62667.
Thank you all for your comments!
--
resolution: -> fixed
status: open -> closed
__
Tracker <[EMAIL PROTECTED]>
<http://bugs
Changes by Alexandre Vassalotti <[EMAIL PROTECTED]>:
--
nosy: +alexandre.vassalotti
__
Tracker <[EMAIL PROTECTED]>
<http://bugs.python.org/issue2523>
__
__
Alexandre Vassalotti <[EMAIL PROTECTED]> added the comment:
Patch committed in r62778.
Antoine wrote:
> Also, I stand by the suggestion I made about the resizing logic, but it
> shouldn't be a showstopper either. We can improve that later.
I made your suggested change to t
Alexandre Vassalotti <[EMAIL PROTECTED]> added the comment:
I see that the code is still using the immutable bytes object for its
buffer (which forces Python to create a new buffer every time its
modified). Also, I think it worthwhile to check if using a pre-allocated
bytearray objec
Alexandre Vassalotti <[EMAIL PROTECTED]> added the comment:
I have a slightly different .hgignore for my personal mercurial branch.
Although, I don't really like the idea of polluting the main subversion
repository with the ignore files of other VCS.
--
nosy: +alexandre.vassa
New submission from Alexandre Vassalotti <[EMAIL PROTECTED]>:
Marc-Andre Lemburg noted:
BTW: The API PyUnicode_AsString() is pretty useless by itself - there's
no way to access the size information of the returned string without
again going to the Unicode object.
I
Alexandre Vassalotti <[EMAIL PROTECTED]> added the comment:
Honestly, I am not sure if removing PyUnicode_AsString() is a good idea.
There is many cases where the size of the returned string is not needed.
Furthermore, this would be a rather major backward-incompatible change
to be include
Alexandre Vassalotti <[EMAIL PROTECTED]> added the comment:
Oops, it seems Marc-André has already opened an issue about this.
Closing as duplicate.
--
resolution: -> duplicate
status: open -> closed
superseder: -> Remove PyUnicode_AsString(), rework
PyUnicode_AsStrin
Alexandre Vassalotti <[EMAIL PROTECTED]> added the comment:
Honestly, I am not sure if removing PyUnicode_AsString() is a good idea.
There is many cases where the size of the returned string is not needed.
Furthermore, this would be a rather major backward-incompatible change
to be include
Changes by Alexandre Vassalotti <[EMAIL PROTECTED]>:
--
nosy: +alexandre.vassalotti
__
Tracker <[EMAIL PROTECTED]>
<http://bugs.python.org/issue2295>
__
__
Alexandre Vassalotti <[EMAIL PROTECTED]> added the comment:
Oops. I must have been quite tired when I submitted that.
Here's the patch for the fix and the test case.
--
keywords: +patch
Added file: http://bugs.python.org/file11814/issue36
Alexandre Vassalotti <[EMAIL PROTECTED]> added the comment:
Could explain me how this feature could be used, other than for
providing the efficient and backward-compatible pickling mechanism for
new-style classes?
--
nosy: +alexandre.vass
Alexandre Vassalotti <[EMAIL PROTECTED]> added the comment:
> Without the __reduce__ method the information in __dict__ and
> the class would be lost.
Are you sure about that?
Python 2.5.2 (r252:60911, Jul 31 2008, 17:28:52)
[GCC 4.2.3 (Ubuntu 4.2.3-2ubuntu7)] on linux2
>
Alexandre Vassalotti <[EMAIL PROTECTED]> added the comment:
Thank you, Amaury, for fixing this. However, you forgot to also patch
the Python implementation of pickle, which makes the following test fail:
=
Alexandre Vassalotti <[EMAIL PROTECTED]> added the comment:
Iterators only need to provide a __next__() method. So, you don't have
to check __iter__.
Other than that, the patch looks good.
___
Python tracker <[EMAIL PROTECTED]>
<ht
Alexandre Vassalotti <[EMAIL PROTECTED]> added the comment:
Hirokazu Yamamoto wrote
> Hmm, but python document says,
> (http://docs.python.org/library/stdtypes.html#typeiter)
>
> >The iterator objects themselves are required to support the
> >following two metho
Alexandre Vassalotti <[EMAIL PROTECTED]> added the comment:
Amaury Forgeot d'Arc wrote:
> Regarding the consistency between python and C, I don't think it is
> necessary to be so strict. If the python version can allow a weaker
> version of the "iterator"
Alexandre Vassalotti <[EMAIL PROTECTED]> added the comment:
I think the best way to fix this is to add sanity checks similar to the
ones in _pickle. The checks are obviously useless in pickle.py, but I
think it is simpler than to try to skip tests, and it gives a nicer
error message to
Alexandre Vassalotti added the comment:
Sorry, I still cannot reproduce it. Could you attach your test file?
Maybe it is some weird encoding bug.
a...@helios:~$ 2to3 -f imports test.py
--- test.py (original)
+++ test.py (refactored)
@@ -1,2 +1,2 @@
-import urlparse, cStringIO
-import cStringIO
Alexandre Vassalotti added the comment:
Benjamin, your example fails for a different reason--i.e. the fixer for
HTMLParser is missing.
Sorry Lennart, I still cannot reproduce it.
___
Python tracker
<http://bugs.python.org/issue4
Alexandre Vassalotti added the comment:
I got it. It is a regression from a previous version of 2to3's
fix_imports. I was able to reproduce your problem using the sandbox's 2to3.
And to answer your question, I still running an older RC release of
Python 3.0. That explains why
Alexandre Vassalotti added the comment:
Fixed in r67934. Backported to 2.6 in r67936. Thanks!
--
nosy: +alexandre.vassalotti
resolution: -> fixed
status: open -> closed
___
Python tracker
<http://bugs.python.org/
Alexandre Vassalotti added the comment:
Committed in r67940.
___
Python tracker
<http://bugs.python.org/issue4374>
___
___
Python-bugs-list mailing list
Unsubscribe:
Changes by Alexandre Vassalotti :
--
resolution: -> fixed
status: open -> closed
___
Python tracker
<http://bugs.python.org/issue4374>
___
___
Python-bugs-
Alexandre Vassalotti added the comment:
You may want to check out issue1408710 in which a similar patch was
provided, but failed to deliver the desired results.
I didn't get the advertised ~15% speed-up, but only 4% on my Intel Core2
laptop and 8% on my AMD Athlon64 X2 desktop. I attache
Changes by Alexandre Vassalotti :
Added file: http://bugs.python.org/file12513/intel-core2-mobile-pybench.txt
___
Python tracker
<http://bugs.python.org/issue4
Alexandre Vassalotti added the comment:
Antoine Pitrou wrote:
> [...] count the number of indirect jump instructions in ceval.c:
>
> grep -E "jmp[[:space:]]\*%" ceval.s
>
> There should be 85 to 90 of them, roughly. If there are many less, then
> the compiler h
Changes by Alexandre Vassalotti :
Added file:
http://bugs.python.org/file12522/amd-athlon64-x2-gcc-sunos-pybench.txt
___
Python tracker
<http://bugs.python.org/issue4
Alexandre Vassalotti added the comment:
> Attached new patch for fixes suggested by Alexandre (rename
> opcode_targets.c to opcode_targets.h, replace USE_THREADED_CODE with
> USE_COMPUTED_GOTOS).
You forgot to update your script to use the
Alexandre Vassalotti added the comment:
The patch make a huge difference on 64-bit Linux. I get a 20% speed-up
and the lowest run time so far. That is quite impressive!
At first glance, it seems the extra registers of the x86-64 architecture
permit GCC to avoid spilling registers onto the
Alexandre Vassalotti added the comment:
One more thing, the patch causes the following warnings to be emited by
GCC when USE_COMPUTED_GOTOS is undefined.
Python/ceval.c: In function ‘PyEval_EvalFrameEx’:
Python/ceval.c:2420: warning: label ‘_make_function’ defined but not used
Python/ceval.c
Alexandre Vassalotti added the comment:
Paolo wrote:
> So, can you try dropping the switch altogether, using always computed
> goto and seeing how does the resulting code get compiled?
Removing the switch won't be possible unless we change the semantic
EXTENDED_ARG. In addition,
Alexandre Vassalotti added the comment:
> Removing the switch won't be possible unless we change the semantic
> EXTENDED_ARG. In addition, I doubt the improvement, if any, would worth
> the increased complexity.
Nevermind what I have said. I managed to remove switch pretty ea
Alexandre Vassalotti added the comment:
> I managed to remove switch pretty easily by moving opcode fetching
> in the FAST_DISPATCH macro and abstracting the control flow of the
> switch.
Here is the diff against threadceval5.patch.
Added file: http://bugs.python.org/file12584
New submission from Alexandre Vassalotti :
This is a 2to3 fixer for the removal of obsolete functions in r68962.
--
components: 2to3 (2.x to 3.0 conversion tool)
files: fix_operator.py
messages: 80624
nosy: alexandre.vassalotti
severity: normal
stage: patch review
status: open
title
Changes by Alexandre Vassalotti :
Added file: http://bugs.python.org/file12875/fix_operator.py
___
Python tracker
<http://bugs.python.org/issue5077>
___
___
Python-bug
Changes by Alexandre Vassalotti :
Removed file: http://bugs.python.org/file12874/fix_operator.py
___
Python tracker
<http://bugs.python.org/issue5077>
___
___
Python-bug
Changes by Alexandre Vassalotti :
--
title: 2to3 fixers for the removal of operator functions -> 2to3 fixer for the
removal of operator functions
___
Python tracker
<http://bugs.python.org/iss
Alexandre Vassalotti added the comment:
The patch for cPickle doesn't do the same thing as the pickle one. In
the cPickle one, you are only interning slot attributes, which, I
believe, is not what you intended. :-)
--
assignee: -> alexandre.vassalotti
nosy: +alexandre.va
Alexandre Vassalotti added the comment:
Oh, you are right. I was looking at py3k's version of pickle, which uses
PyDict_Update instead of a while loop; that is why I got confused.
___
Python tracker
<http://bugs.python.org/i
Change by Alexandre Vassalotti :
--
assignee: -> alexandre.vassalotti
resolution: -> fixed
stage: patch review -> resolved
status: open -> closed
versions: -Python 3.7, Python 3.8
___
Python tracker
<https://bugs.python
Change by Alexandre Vassalotti :
--
stage: patch review -> resolved
status: open -> closed
___
Python tracker
<https://bugs.python.org/issue27635>
___
___
Alexandre Vassalotti added the comment:
We will need to bump the protocol number to add support for None, Ellipsis, and
NotImplemented. Antoine, can you add this to PEP 3154?
--
___
Python tracker
<http://bugs.python.org/issue13
Alexandre Vassalotti added the comment:
PR 9841 looks good to me. I wouldn't worry about the performance hit.
--
___
Python tracker
<https://bugs.python.org/is
Alexandre Vassalotti added the comment:
Stefan, could you address my review comments soon? The improved support for
globals is the only big piece missing from the implementation of PEP, which I
would like to get done and submitted by the end of the month
Alexandre Vassalotti added the comment:
I am still working on it. I am implemented support for nested globals last week
(http://hg.python.org/features/pep-3154-alexandre/rev/c8991b32a47e). At this
point, the only big piece remaining is the support for method descriptors.
There are other minor
Alexandre Vassalotti added the comment:
I reviewed the patch here
http://bugs.python.org/review/15513/#ps5596
--
___
Python tracker
<http://bugs.python.org/issue15
Alexandre Vassalotti added the comment:
Amazing! Though, it would probably be good idea to benchmarks non-ASCII strings
as well.
--
___
Python tracker
<http://bugs.python.org/issue15
New submission from Alexandre Vassalotti:
Stefan Mihaila has been working on the implementation of PEP 3154, plus some
other enhancements. His work is pretty complete and ready to be reviewed. I
will do my best to finish a thorough review of his changes by the end of next
week
Changes by Alexandre Vassalotti :
Added file: http://bugs.python.org/file26794/pickle4.diff
___
Python tracker
<http://bugs.python.org/issue15642>
___
___
Python-bug
Changes by Alexandre Vassalotti :
Removed file: http://bugs.python.org/file26794/pickle4.diff
___
Python tracker
<http://bugs.python.org/issue15642>
___
___
Python-bug
Changes by Alexandre Vassalotti :
Added file: http://bugs.python.org/file26795/pickle4.diff
___
Python tracker
<http://bugs.python.org/issue15642>
___
___
Python-bug
Alexandre Vassalotti added the comment:
I get warnings when compiling with the patch:
/home/avassalotti/pickle4/Modules/_pickle.c: In function ‘save_global_binary’:
/home/avassalotti/pickle4/Modules/_pickle.c:2952: warning: pointer targets in
passing argument 2 of ‘_Pickler_Write’ differ in
Alexandre Vassalotti added the comment:
There are reference leaks in the _pickle.c part that will need to be fixed too.
22:36:29 [~/pickle4]$ ./python -m test.regrtest -R :: test_pickle
[1/1] test_pickle
beginning 9 repetitions
123456789
.
test_pickle leaked [14780, 14780, 14780
Changes by Alexandre Vassalotti :
Added file: http://bugs.python.org/file26881/pickle4-2.diff
___
Python tracker
<http://bugs.python.org/issue15642>
___
___
Python-bug
Changes by Alexandre Vassalotti :
--
dependencies: +Unbinding of methods
___
Python tracker
<http://bugs.python.org/issue15642>
___
___
Python-bugs-list mailin
Changes by Alexandre Vassalotti :
Removed file: http://bugs.python.org/file26881/pickle4-2.diff
___
Python tracker
<http://bugs.python.org/issue15642>
___
___
Python-bug
Alexandre Vassalotti added the comment:
Oops, wrong patch. Uploading the right one.
--
Added file: http://bugs.python.org/file26882/pickle4-2.diff
___
Python tracker
<http://bugs.python.org/issue15
Alexandre Vassalotti added the comment:
Some quick thoughts about the new implicit memoization scheme in Stefan's
implementation.
- The new scheme will need to be documented in PEP 3154 before we can accept
the change.
- I don't really like the idea of changing the semantics of t
Alexandre Vassalotti added the comment:
pickle.py is the buggy one here. Its use of the marshal module is really a
hack. Plus, it is slower than both struct and int.from_bytes.
14:40:57 [~/cpython]$ ./python -m timeit "int.from_bytes(b'\xff\xff\xff\xff',
'big')&
Alexandre Vassalotti added the comment:
Let's close this. There is no point keeping this languishing any further.
The profile and cProfile modules are different enough that we can't merge them
without breaking compatibility. They should treated as two separate profilers.
Maybe in
New submission from Alexandre Vassalotti:
The value of __qualname__ for globals declared in function scope doesn't seems
right to me:
>>> def f():
...global C
...class C: pass
...return C.__qualname__
...
>>> f()
'f..C'
It would be much more usef
Alexandre Vassalotti added the comment:
Supporting nonlocal variables would be nice. However, unless it is easy to
implement, I don't think it is worth the effort since these variables can't be
accessed outside the enclosing functi
Alexandre Vassalotti added the comment:
It seems that we are missing support for nested globals:
>>> def f():
... global C
... class C:
... class D:
... pass
...
>>> f()
>>> C.D.__qualname__
'f..C.D
Changes by Alexandre Vassalotti :
Added file: http://bugs.python.org/file32639/f87b455af573.diff
___
Python tracker
<http://bugs.python.org/issue17810>
___
___
Python-bug
Changes by Alexandre Vassalotti :
Added file: http://bugs.python.org/file32640/8434af450da0.diff
___
Python tracker
<http://bugs.python.org/issue17810>
___
___
Python-bug
Changes by Alexandre Vassalotti :
Removed file: http://bugs.python.org/file32639/f87b455af573.diff
___
Python tracker
<http://bugs.python.org/issue17810>
___
___
Pytho
Alexandre Vassalotti added the comment:
Hi folks,
I consider my implementation of PEP-3154 mostly feature complete at this point.
I still have a few things left to do. For example, I need to update the
documentation about the new protocol. However, these can mostly be done along
the review
Alexandre Vassalotti added the comment:
Merged with issue #17810
--
resolution: -> duplicate
status: open -> closed
superseder: -> Implement PEP 3154 (pickle protocol 4)
___
Python tracker
<http://bugs.python.or
Alexandre Vassalotti added the comment:
I have been looking again at Stefan's previous proposal of making memoization
implicit in the new pickle protocol. While I liked the smaller pickles it
produced, I didn't the invasiveness of the implementation, which requires a
change for al
Changes by Alexandre Vassalotti :
--
resolution: -> duplicate
status: open -> closed
superseder: -> Implement PEP 3154 (pickle protocol 4)
___
Python tracker
<http://bugs.python.or
Alexandre Vassalotti added the comment:
I've finalized the framing implementation in de9bda43d552.
There will be more improvements to come until 3.4 final. However, feature-wise
we are done. Thank you everyone for the help!
--
status: open ->
Alexandre Vassalotti added the comment:
The patch is too complicated for too little.
--
resolution: -> rejected
stage: patch review -> committed/rejected
status: open -> closed
___
Python tracker
<http://bugs.python.or
Changes by Alexandre Vassalotti :
--
resolution: -> wont fix
stage: needs patch -> committed/rejected
status: open -> closed
___
Python tracker
<http://bugs.python.or
Alexandre Vassalotti added the comment:
Optimizing the output of the pickler class should be fine during the feature
freeze as long the semantics of the current opcodes stay unchanged.
--
___
Python tracker
<http://bugs.python.org/issue17
Alexandre Vassalotti added the comment:
Thanks Zachary for the notice! Look like my change fixed the warnings on the
Windows x86 build.
http://buildbot.python.org/all/builders/x86%20Windows%20Server%202008%20%5BSB%5D%203.x/builds/1801
--
resolution: -> fixed
status: open ->
Alexandre Vassalotti added the comment:
Serhiy, I am not able to reproduce your results. I don't get any significant
performance improvements with your patch.
22:34:03 [ ~/PythonDev/cpython-baseline ]$ ./python.exe -m timeit "import
pickle" "with open('test.pickle4&
Alexandre Vassalotti added the comment:
As part of the implementation of PEP 3154 (Pickle protocol 4), I've introduced
support for pickling methods for all pickle protocols (and not just for the new
protocol 4). This was implemented by adding the appropriate __reduce__ method
on bui
Alexandre Vassalotti added the comment:
> Test data are too small, they all less than frame size.
Ah, good point! It seems your patch helps when the reads are *very* slow and
buffering is disabled.
### unpickle_file ###
Min: 1.125320 -> 0.663367: 1.70x faster
Avg: 1.237206 -> 0.7013
Changes by Alexandre Vassalotti :
--
assignee: -> alexandre.vassalotti
resolution: -> fixed
stage: commit review -> committed/rejected
status: open -> closed
___
Python tracker
<http://bugs.pytho
Changes by Alexandre Vassalotti :
--
assignee: -> alexandre.vassalotti
resolution: -> duplicate
stage: patch review -> committed/rejected
status: open -> closed
superseder: -> Implement PEP 3154 (pickle protocol 4)
versions: +Python
201 - 300 of 602 matches
Mail list logo