> >>> fp = open('raro.txt')
> >>> mail = email.message_from_file(fp)
> never return
When you think you found a problem with python, please submit an issue
in the python issue tracker:
http://bugs.python.o
s
not listed in the run_unittest() call :-(.
I found the cause of the problem: in io.py, TextIOWrapper.tell() calls
decode() with a bytearray, without any reason it seems.
I will take care of this tonight, if bugs.python.org is available.
--
Amaury Forgeot d'Arc
_
}
Of course, if you call sock.dup() or sock.makefile(),
there is another reference to the underlying _sock, and you must
close() all these objects.
--
Amaury Forgeot d'Arc
___
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailm
17-63618,
63714,63718,63742,63745,63799 (jesus.cea, gregory.p.smith): bsddb module
This is a important list of changes, and may require heavy adaptations
to the code.
issue2887 has been filed for this task.
Do you think these tasks should be considered as Release Blockers?
Beta1 is close...
--
Amaury
#x27;AF_INET':
-return ('localhost', 0)
+return ('', 0)
elif family == 'AF_UNIX':
return tempfile.mktemp(prefix='listener-', dir=get_temp_dir())
elif family == 'AF_PIPE':
And the test started to pass for
Hello,
2008/6/18 Jean-Paul Calderone <[EMAIL PROTECTED]>:
> On Wed, 18 Jun 2008 18:35:26 +0200, Amaury Forgeot d'Arc
> <[EMAIL PROTECTED]> wrote:
>>
>> [snip]
>>
>> I just found the cause of the problem ten minutes ago:
>> It seems tha
No, it is *not* different than localhost - it *is* localhost as that
> is the object.address of the server.
Well, on my win2k machine getfqdn('127.0.0.1') returns the actual name
of the machine.
This is the name that was stored in server.address.
Hence my patch that simply remove t
op
I remember that a similar issue was discussed some months ago:
http://bugs.python.org/issue2607
In short: the gc is tuned for typical usage. If your usage of python
is specific,
use gc.set_threshold and increase its values.
--
Amaury Forgeot d'Arc
___
(1 given
It's possible that "event" contains an object that cannot be copied.
>From the traceback, one can see that your object has an attribute that
is a list of lists, and the failing object is there.
Googling for the error message suggests that the object could be an
array.array.
The
fixed.
> The one thing that may be missing from Python is things like
> interpretation of surrogates by functions like isalpha() and I'm okay
> with adding that (since those have to loop over the entire string
> anyway).
In this case, a new .isascii() method would be needed for so
rrors I see lots of bsdbd errors, many of the form:
>>
>> | DBFileExistsError: (17, 'File exists -- __fop_file_setup: Retry limit
>> (100) exceeded')
>
> Maybe this one is due to the fact that Windows, unlike POSIX, doesn't
> allow unlinking an open file?
I see that some t
90.dll runtime:
http://bugs.python.org/issue3308
For example, if the extension module contains standard date functions
(using time_t), it won't load.
--
Amaury Forgeot d'Arc
___
Python-Dev mailing list
Python-Dev@python.org
http://mail.python
ted,
nor is any function declared in codecs.h.
Is it part of the public API?
--
Amaury Forgeot d'Arc
___
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe:
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
sions, and it either succeeds,
or fails with a meaningful (for an expert) error message.
Which extensions did you try? is there some output before the error?
--
Amaury Forgeot d'Arc
___
Python-Dev mailing list
Python-Dev@python.org
http://mail.python
a list iterator is
collected by the garbage collector, but a cycle with a dict iterator
is not.
This is worth a bug report IMO.
--
Amaury Forgeot d'Arc
import gc, weakref
def test_container_iterator(i):
class C(object):
pass
obj = C()
ref = weakref.ref(obj)
if i
//bugs.python.org/issue3561
--
Amaury Forgeot d'Arc
___
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe:
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
)
Your example crashes because it calls python API functions when the
GIL is not held,
and is so invalid.
There are two solutions:
- re-acquire the GIL in your C functions with PyGILState_Ensure() & co
- use ctypes.PyDLL( "./tst.so" ), which does not release the GIL.
Hope this helps,
r to (for example)
http://svn.python.org/projects/python/trunk/Lib/distutils/
and download the desired files from there?
--
Amaury Forgeot d'Arc
___
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe:
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
e648658
It's very unlikely that such a change can be made at this stage.
There is not even a patch to review...
But the tracker seems to contains a workaround.
It seems to work without any modification of the standard library
Does it actually work? Could bzr use it?
-
on this b) pypy
> implements it differently)
Note that python 3.0 has a different behaviour; in the first sample, it prints:
A ( ...
B (, ...
See the subtle differences between
http://docs.python.org/dev/library/sys.html#sys.exc_info
http://docs.python.org/dev/3.0/library/sys.html#sys
hat this is THE unresolved issue of python 3.0.
--
Amaury Forgeot d'Arc
___
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe:
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
, where many people can work on
the same files.
Do other subscribed people receive these commit messages?
Is there a problem with the mailer, or some SVN trigger?
--
Amaury Forgeot d'Arc
___
Python-Dev mailing list
Python-Dev@python.org
followed by LOAD_ATTR:
0 LOAD_GLOBAL 0 (codecs)
3 LOAD_ATTR 1 (ascii_decode)
...
I fail to imagine a reason, apart from a creeping memory error (in
dictionary lookup; chilling idea).
Thoughts?
--
Amaury Forgeot d'Arc
LDIR", ".")
#install python30.dll into root dir for now
dlldir = root
They were added by r61109: " Bundle msvcr90.dll as a "private assembly". "
but I don't know if simply restoring the previous value will work in every case:
If the C Run-T
ch with few restrictions:
it's here to share code with others and experiment with the next
python release. The need for stability is much lower.
--
Amaury Forgeot d'Arc
___
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailm
e "value" string object must be created anyway, and this
could be avoided in most Getattr cases.
--
Amaury Forgeot d'Arc
___
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe:
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Please send this kind of questions to the comp.lang.python newsgroup,
or the wxPython-users mailing list.
There are many python users there willing to help.
Furthermore wxPython is not developed here (or is it PythonCard?), so
you'll get little expertise from us.
(a hint however: "result.pa
everyone...)
By the way, it seems that this python-checkins mailing list did not
archive the recent commits:
http://mail.python.org/pipermail/python-checkins/2008-October/date.html#end
I miss them... Can someone fix it?
--
Amaury Forgeot d'Arc
_
kly get a response there.
--
Amaury Forgeot d'Arc
___
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe:
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
x27;t prove that. Has anyone investigated this kind of valgrind
> report?
Did you use the suppressions file as suggested in Misc/README.valgrind?
--suppressions=Misc/valgrind-python.supp
--
Amaury Forgeot d'Arc
___
Python-Dev mailing list
de of the interpreter is
generated, and it already proposes a "Taint" option at translation
time.
http://codespeak.net/pypy/dist/pypy/doc/objspace-proxies.html#taint
With only 300 lines of elegant python code...
--
Amaury Forgeot d'Arc
___
ee bottom of
http://www.python.org/dev/buildbot/3.0/x86%20W2k8%203.0/builds/486/step-test/0
)
--
Amaury Forgeot d'Arc
___
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe:
http://mail.python.org/
on a grammar that
> wants to support Python 3.0?
An issue was already filed about this:
http://bugs.python.org/issue4199
It should be ready for inclusion in 3.0.1.
--
Amaury Forgeot d'Arc
___
Python-Dev mailing list
Python-Dev@python.org
http://m
'ascii' codec come from?
It's sys.getdefaultencoding default value.
sys.stdout.write() expects a bytes string. What you see here is the
coercion of the unicode to a string.
--
Amaury Forgeot d'Arc
___
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe:
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
tributeError, NameError):
> pass
I suggest "except Exception": SystemExit and KeyboardInterrupt inherit
from BaseException, not from Exceptions
And close() is likely to raise IOErrors.
--
Amaury Forgeot d'Arc
___
Pyt
n active distutils maintainer, and many
> stale distutil tickets are in need of attention I'm sure Tarek could
> provide. Tarek has also been providing many useful patches of his own.
+1 from me as well.
--
Amaury Forgeot d'Arc
___
en I
> look at the code of PyRun_InteractiveOne, it seems it should be
> possible to kill it off.
How would you display multiple lines, like:
>>> for x in range(3):
...x, x * x
...
(0, 0)
(1, 1)
(2, 4)
>>> if 1:
... "some line"
... "another
n newsgroup.
Be prepared to provide the complete error output: I fail to see how a
crash in IDLE 3.0b3 would be similar to some problem with cherrypy!
--
Amaury Forgeot d'Arc
___
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/
a bit cleverer (or perhaps a bit less
> cleverer) than i'm expecting it to be?
On Windows, you must turn on the --enable_shared option if you want to
build extension modules.
You could take the cygwin build as an example, see what's done in
./configure.in.
--
Amaury Forgeot d'Arc
___
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe:
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
ewhere else?
Cheers,
--
Amaury Forgeot d'Arc
___
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe:
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
gt; (it starts with an underscore), so how can it be a limited API function?
It's not a proposal of any kind; it's just the workaround I used to compile
and test.
OTOH, it seems that many modules already use this function. Is there
another method that d
getting the sliding window algorithm):
> I'm not sure of what percentage of strings/buffers are concerned in a
> "typical" program.
Most usages of _PyBytes_Resize() are in compression libraries.
256K payloads are not rare in this area.
--
Amaury Forgeot d'Arc
__
d prefer it was written :
if (PyUnicode_READY(*filename) < 0)
because "< 0" clearly indicates an error condition.
That's how all calls to PyType_Ready are written, for example.
Am I the only one to be distracted by this idiom?
--
Amaury Forgeot d'Arc
_
low one of two ways to
indicate an error:
- functions that return PyObject* will return NULL
- functions that return an int will return -1
--
Amaury Forgeot d'Arc
___
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/py
y key, I don't
remember which one though :-(
--
Amaury Forgeot d'Arc
___
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe:
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
date");
>_Py_IdentifierAdd(&s_update);
> }
>
It should also check for errors; in this case the initialization is a bit
more verbose:
if (PY_IDENTIFIER_INIT(update) < 0)
;
--
Amaury Forgeot d'Arc
___
Python-Dev mailing lis
e development *of* python.
For development *with* python, please ask your question on the python-list
mailing list, or the comp.lang.python newsgroup.
There are many friendly people there ready to answer your questions.
Thank you!
--
Amaury Forgeot d'Arc
___
stom alignments.
IMO a good thing would be a way to specify a function that computes sizes
and alignments, that one can override to implement specific compiler
features.
--
Amaury Forgeot d'Arc
___
Python-Dev mailing list
Python-Dev@python.org
http://
Hi,
2011/11/9 Barry Warsaw
> I think we should have an official pronouncement about Python 2.8, and PEPs
> are as official as it gets 'round here.
>
Do we need to designate a release manager?
--
Amaury Forgeot d'Arc
___
Pyth
new non-movable buffer (since all memory allocated
by PyPy is movable). So cpyext could support the new API for sure, but
it's unlikely to give any performance benefit to an extension module.
--
Amaury Forgeot d'Arc
___
Python-Dev mailin
t;
> The easiest solution is to do nothing in Python 3.3: the API changed, but
> it
> doesn't really matter. Developers just have to be careful on this
> particular
> issue (which is not well documented today).
>
+1. A note in the "Porting C
Hi,
2011/11/22 Giampaolo Rodolà
> Sorry, thanks (fixed).
>
You also modified Lib/sched.py in the same commit.
Was it intended? If not, please revert it.
--
Amaury Forgeot d'Arc
___
Python-Dev mailing list
Python-Dev@pyth
without any merge tool.
OTOH when PyPy changed minor versions (from 2.7.0 to 2.7.2 IIRC) most of
the work was to follow the various tiny fixes made to the built-in modules:
_io, _ssl and _multiprocessing.
--
Amaury Forgeot d'Arc
___
Python
on of
dict specialized for string keys, and the 2.7 range() returns a list that
does not need to allocate its items, and can turn into a "real" list as
soon as you modify it), so I would not qualify this task as a big hurdle,
compared to other optimizations done in similar areas.
--
not a good idea to rely on
> it (and it's especially unwise to base benchmarks on it working :-))
>
Note that this string optimization hack is still present in Python 3,
but it now acts on *unicode* strings, not bytes.
--
Amaury Forgeot d'Arc
_
mple to me, but also the
pickle/copy modules which were modified because of subtle differences
around built-in methods (or was it the __builtins__ module?)
And oh, I almost forgot distutils, which needs to parse some Makefile which
of course does not exist in PyPy.
- Differences between C extensions and pure P
velopment headers so that they can build the new module.
>
And don't worry about Windows builbots, they will automatically download
the XZ prebuilt binaries from the usual place.
(svn export http://svn.python.org/projects/external/xz-5.0.3)
Next step: add support for tar.xz files (issue5
of the documentation:
http://docs.python.org/library/stdtypes.html#mutable-sequence-types
and only considers python 2.2 or older...
--
Amaury Forgeot d'Arc
___
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsub
nly held by a local variable in listsort().
even gc.get_referrers() can return the empty list...
--
Amaury Forgeot d'Arc
___
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe:
http://mail.p
g = self.detect_modules()
> File "./setup.py", line 1154, in detect_modules
>for arg in sysconfig.get_config_var("**CONFIG_ARGS").split()]
> AttributeError: 'NoneType' object has no attribute 'split'
> make: *** [sharedmods] Error 1
>
r particular question: keep in mind that PyObject_Call takes
arguments as a tuple;
if you want to pass one tuple, you need to build a 1-tuple around your
tuple]
--
Amaury Forgeot d'Arc
___
Python-Dev mailing list
Python-Dev@python.org
http://mail.p
ns of similar
constructs,
and works very well in debug mode.
If you can isolate a reproducible case, please file a ticket on
bugs.python.org,
with all details: code, versions of the compiler, etc.
--
Amaury Forgeot d'Arc
___
Python-Dev mailing l
d code to do allocation of the str field even
> that is questionable (i don't think there are?).
There are. Unfortunately.
https://github.com/numpy/numpy/blob/master/numpy/core/src/multiarray/scalarapi.c#L710
--
Amaury Forgeot d'Arc
__
at the start of a block
- No designated initializers for structures
- Ascii-only identifiers:
http://msdn.microsoft.com/en-us/library/e7f8y25b.aspx
--
Amaury Forgeot d'Arc
___
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailm
the behaviour of the "mbcs" codec
> under Windows. "locale" would be the moral (*) equivalent of that under
> Unix.
With the difference that mbcs cannot change during execution.
I don't even know if it is possible to change it
rm is different from others
mostly because
a pointer (64bit) is larger than a long (32bit on all Windows flavors)
Is the 32-bit build safe to use on 64-bit Windows?
Yes, like many other 32-bit programs pypy for win32 works on Windows 64-bit.
It will be limited to 3Gb of
the solution should still
> be
> built. (I'm not absolutely sure, as I use the full Visual Studio).
I confirm: you can safely ignore this warning message.
The "Solution folder" is a convenient place to group files not related to
plete shambles we should go
> ahead and deprecate, then remove, that functionality.
Not that I disagree with the conclusion, but the obvious thing to do here
is to fix dir() and return only string attributes, i.e. those you can
access with getattr.
Cheers,
--
Amaury Forgeot d'Arc
yPy to 3.3 will be more work ;-)
Fortunately the libmpdec directory should be reusable as is.
Nice work!
--
Amaury Forgeot d'Arc
___
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe:
Hi,
2012/4/16 Stefan Behnel
> > On the down side, we would depend on Cython for evolving .
>
> Right, although not as a strict dependency. The code would still work just
> fine in plain Python.
Not quite, we are talking of the imp module here...
--
Amaur
doesn't PyPy read and write .pyc files (
>> http://doc.pypy.org/en/latest/config/objspace.usepycfiles.html suggests
>> you do)? So I would assume you are not affected by this. Jython and
>> IronPython, though, would be (I think).
>>
>
>
ail.python.org/mailman/listinfo/python-dev
> Unsubscribe:
> http://mail.python.org/mailman/options/python-dev/amauryfa%40gmail.com
>
--
Amaury Forgeot d'Arc
___
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe:
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
ng, psyco did exactly this.
--
Amaury Forgeot d'Arc
___
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe:
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
oblem becomes more and more difficult each time
one thinks about it)
--
Amaury Forgeot d'Arc
___
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe:
http://mail.python.org/mailman/option
s that play tricky games with the API;
PyQt for example uses metaclasses with a custom tp_alloc slot, to have access
to the PyTypeObject structure during the construction of the type...
The Python C API is quite complete, but some use cases are still
poorly
gt; import hashlib
>>> hashlib.new(1)
TypeError: name must be a string
But if the _hashlib extension module is not available, the python
version is used and ValueError is raised:
>>> import sys
>>> sys.modules['_hashlib'] = None
>>> import hashli
ich at the time was 3.3.
But this does not prevent anyone from creating and maintaining such a
patch, outside of the official python.org repository.
--
Amaury Forgeot d'Arc
___
Python-Dev mailing list
Python-Dev@python.org
http://mail.p
cate a better presentation of
its content.
Could we have at least clear sections, with titles and descriptions?
And use the ^L page separator for Emacs users?
Code in posixmodule.c could also benefit of a better layout.
--
Amaury Forgeot d'Arc
___
Python-Dev mailing list
> Python-Dev@python.org
> http://mail.python.org/mailman/listinfo/python-dev
> Unsubscribe:
> http://mail.python.org/mailman/options/python-dev/amauryfa%40gmail.com
--
Amaury Forgeot d'Arc
___
Python-Dev mailing list
P
is in the same line as
> WORD, DWORD etc. The way you look at memory contents in assembly.
In this case you should use ctypes.wintypes.BYTE
... which is unfortunately defined as c_byte!
This is the bug :-(
--
Amaury Forgeot d'Arc
___
Python-Dev ma
t;group" command will not run
> forever. What can'i do
> Mybe this is my fase, please give me some advise.
>
>
> ___
> Python-Dev mailing list
> Python-Dev@python.org
> http://mail.python.org/mailman/listinfo/python-de
link which causes the rest of the line to be shifted.
--
Amaury Forgeot d'Arc
___
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe:
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
2013/1/23 Antoine Pitrou
> On Wed, 23 Jan 2013 20:41:11 +0100
> "Amaury Forgeot d'Arc" wrote:
> > 2013/1/22 Antoine Pitrou
> >
> > > I've upgraded the Mercurial version on hg.python.org. If there any
> > > problems, don't hesitate t
e the GIL.
>
> One reasonable heuristic is to check the man page: if the syscall can
> return EINTR, then the GIL should be released.
Should the call be retried in the EINTR case?
(After a PyErr_CheckSignals)
--
Amaury Forgeot d'Arc
___
cessary to
follow the rules, even if they were written by a lawyer and we don't
understand all the reasons.
--
Amaury Forgeot d'Arc
___
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe:
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
returns True,
> the two classes will either be identical, or the second will be in the MRO
> of the first. What have I missed?
>
Ah, the magic of ABCs...
KeysView overrides __instancecheck__, and can pretend to be any other class.
This is precisely set in Lib/collections/abc.py:
eing slow both on CPython and PyPy. Although
> using .format() is even slower. :-)
Did you really try it?
PyPy is really fast with str.__mod__, when the format string is a constant.
Yes, it's jitted.
--
Amaury Forgeot d'Arc
___
Python-Dev
2013/2/13 Christian Tismer
> On 13.02.13 15:27, Amaury Forgeot d'Arc wrote:
>
>
> 2013/2/13 Lennart Regebro
>
>> On Wed, Feb 13, 2013 at 1:10 PM, Serhiy Storchaka
>> wrote:
>> > I prefer "x = '%s%s%s%s' % (a, b, c, d)" when string
2013/2/13 Lennart Regebro
> On Wed, Feb 13, 2013 at 3:27 PM, Amaury Forgeot d'Arc
> wrote:
> > Yes, it's jitted.
>
> Admittedly, I have no idea in which cases the JIT kicks in, and what I
> should do to make that happen to make sure I have the best possible
>
Hello,
Purify is not so difficult to use: just run and learn to read the output ;-)
My config: Win2k using VC6sp5, and only 512Mb RAM.
I downloaded the snapshot dated 2005/11/21 05:01,
commented out #define WITH_PYMALLOC,
built in debug mode,
modified the rt.bat file to use purify,
and ran "rt -d"
101 - 190 of 190 matches
Mail list logo