Fred L. Drake, Jr. wrote:
On Saturday 10 June 2006 12:34, Fredrik Lundh wrote:
if all undocumented modules had as much documentation and articles as
ET, the world would be a lot better documented ;-)
I've posted a text version of the xml.etree.ElementTree PythonDoc here:
Here's a
Kevin Jacobs [EMAIL PROTECTED] wrote:
Try this at home:
import collections
d=collections.defaultdict(int)
d.iterkeys().next() # Seg fault
d.iteritems().next() # Seg fault
d.itervalues().next() # Fine and dandy
This all worked fine for me in rev 46739 and 46849 (Kubuntu 6.06, gcc 4.0.3).
Nick Coghlan wrote:
Kevin Jacobs [EMAIL PROTECTED] wrote:
Try this at home:
import collections
d=collections.defaultdict(int)
d.iterkeys().next() # Seg fault
d.iteritems().next() # Seg fault
d.itervalues().next() # Fine and dandy
This all worked fine for me in rev 46739 and 46849
I wonder if this is similar to Kevin's problem? I couldn't reproduce
his problem though. This happens with both debug and release builds.
Not sure how to reduce the test case. pychecker was just iterating
through the byte codes. It wasn't doing anything particularly
interesting.
./python
Fred L. Drake, Jr. wrote:
With the introduction of the xmlcore package in Python 2.5, should we
document
xml.etree or xmlcore.etree? If someone installs PyXML with Python 2.5, I
don't think they're going to get xml.etree, which will be really confusing.
We can be sure that
On 11 jun 2006, at 12.09, Fredrik Lundh wrote:
Fred L. Drake, Jr. wrote:
With the introduction of the xmlcore package in Python 2.5, should
we document
xml.etree or xmlcore.etree? If someone installs PyXML with Python
2.5, I
don't think they're going to get xml.etree, which will be
Ka-Ping Yee [EMAIL PROTECTED] wrote:
Quite a few people have expressed interest in having UUID
functionality in the standard library, and previously on this
list some suggested possibly using the uuid.py module i wrote:
http://zesty.ca/python/uuid.py
Some comments on the code:
for
Simon Percivall wrote:
how about tweaking the xml loader to map xml.foo to _xmlplus.foo
only if that subpackage really exists ?
I'm a bit confused by what the problem is. I though this was all
handled like it should be now.
that's how I thought things were done, but then I read Fred's
Planet is a feed aggregator written in Python. It depends heavily on
SGMLLib. A recent bug report turned out to be a deficiency in sgmllib,
and I've submitted a test case and a patch[1] (use or discard the patch,
it is the test that I care about).
While looking around, a few things surfaced.
Greg Ewing wrote:
[EMAIL PROTECTED] wrote:
switch raw_input(enter a, b or c: ):
case 'a':
print 'yay! an a!'
case 'b':
print 'yay! a b!'
case 'c':
print 'yay! a c!'
else:
print 'hey dummy! I said a, b or c!'
On Sun, Jun 11, 2006, Sam Ruby wrote:
Planet is a feed aggregator written in Python. It depends heavily on
SGMLLib. A recent bug report turned out to be a deficiency in sgmllib,
and I've submitted a test case and a patch[1] (use or discard the patch,
it is the test that I care about).
Python and Jython import semantics differ on how sub-packages should be accessed after importing some module:Jython 2.1 on java1.5.0 (JIT: null)Type copyright, credits or license for more information.
import xml xml.dommodule xml.dom at 10340434Python 2.4.2 (#67, Sep 28 2005, 12:41:11) [MSC
talin Since you don't have the 'fall-through' behavior of C, I would
talin also assume that you could associate more than one value with a
talin case, i.e.:
talin case 'a', 'b', 'c':
talin...
As Andrew Koenig pointed out, that's not discussed in the PEP. Given
Talin wrote:
I don't have any specific syntax proposals, but I notice that the suite
that follows the switch statement is not a normal suite, but a
restricted one, and I am wondering if we could come up with a syntax
that avoids having a special suite.
don't have KR handy, but I'm pretty
[EMAIL PROTECTED] wrote:
talin Since you don't have the 'fall-through' behavior of C, I would
talin also assume that you could associate more than one value with a
talin case, i.e.:
talin case 'a', 'b', 'c':
talin...
As Andrew Koenig pointed out, that's
In the subprocess module, by default the files handles in the child
are inherited from the parent. To ignore a child's output, I can use
the stdout or stderr options to send the output to a pipe::
p = Popen(command, stdout=PIPE, stderr=PIPE)
However, this is sensitive to the buffer deadlock
Thomas Heller wrote:
I don't know if this is the uuidgen you're talking about, but
on linux there is libuuid:
Thanks!
Okay, that's in there now. Have a look at http://zesty.ca/python/uuid.py .
Phillip J. Eby wrote:
By the way, I'd love to see a uuid.uuid() constructor that simply calls the
I did this earlier:
hex(9)
'0x9184e729fffL'
and found it a little jarring, because i feel there's been a general
trend toward getting rid of the 'L' suffix in Python.
Literal long integers don't need an L anymore; they're automatically
made into longs if the number is too
Terry Jones wrote:
Suppose you have a RNG with a cycle length of 5. There's nothing to stop an
algorithm from taking multiple already returned values and combining them
in some (deterministic) way to generate 5 outcomes.
No, it's not. As long as the RNG output is the only input to
the
BJörn Lindqvist wrote:
I don't know how difficult it is to get rid of the
implicit return None or even if it is doable, but if it is, it
should, IMHO, be done.
It's been proposed before, and the conclusion was that
it would cause more problems than it would solve.
(Essentially it would
Talin wrote:
Since you don't have the 'fall-through' behavior of C, I would also
assume that you could associate more than one value with a case, i.e.:
case 'a', 'b', 'c':
...
Multiple values could be written
case 'a':
case 'b':
case 'c':
...
without conflicting
[EMAIL PROTECTED] wrote:
I agree, but that of course limits the expressions to constants which can be
evaluated at compile-time as I indicated in my previous mail.
A way out of this would be to define the semantics so that
the expression values are allowed to be cached, and the
order of
Greg == Greg Ewing [EMAIL PROTECTED] writes:
Greg Terry Jones wrote:
Suppose you have a RNG with a cycle length of 5. There's nothing to stop an
algorithm from taking multiple already returned values and combining them
in some (deterministic) way to generate 5 outcomes.
Greg No, it's not.
Fred L. Drake, Jr. [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
On Sunday 11 June 2006 16:26, Sam Ruby wrote:
Planet is a feed aggregator written in Python. It depends heavily on
SGMLLib. A recent bug report turned out to be a deficiency in sgmllib,
and I've submitted a
Fabio Zadrozny [EMAIL PROTECTED] wrote in message
Jython 2.1 on java1.5.0 (JIT: null)
Python 2.4.2 (#67, Sep 28 2005, 12:41:11) [MSC v.1310 32 bit (Intel)] on
win32
Jython 2.1 intends to match Python 2.1, I believe.
Python 2.2, which I still have loaded, matches Python 2.4 in the behavior
Martin Blais [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
Any idea how this idiom could be supported using a more portable
solution (i.e. how would I make this idiom under Windows, is there
some equivalent to /dev/null)?
On a DOS/Windows command line, 'NUL:' or 'nul:'
[Ka-Ping Yee]
I did this earlier:
hex(9)
'0x9184e729fffL'
and found it a little jarring, because i feel there's been a general
trend toward getting rid of the 'L' suffix in Python.
Literal long integers don't need an L anymore; they're automatically
made into longs
[Terry Jones]
The code below uses a RNG with period 5, is deterministic, and has one
initial state. It produces 20 different outcomes.
Well, I'd call the sequence of 20 numbers it produces one outcome.
From that view, there are at most 5 outcomes it can produce (at most 5
distinct 20-number
Fred L. Drake, Jr. wrote:
On Sunday 11 June 2006 16:26, Sam Ruby wrote:
Planet is a feed aggregator written in Python. It depends heavily on
SGMLLib. A recent bug report turned out to be a deficiency in sgmllib,
and I've submitted a test case and a patch[1] (use or discard the patch,
Terry Reedy wrote:
Fred L. Drake, Jr. [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
On Sunday 11 June 2006 16:26, Sam Ruby wrote:
Planet is a feed aggregator written in Python. It depends heavily on
SGMLLib. A recent bug report turned out to be a deficiency in sgmllib,
and
On Monday 12 June 2006 00:05, Sam Ruby wrote:
Just to be clear: Planet uses Mark's feed parser, which uses SGMLlib.
Cool.
I was investigating a bug in sgmllib which affected the feed parser (and
therefore Planet), and noticed that there were changes in the SVN head
of Python which broke
Sam Ruby wrote:
Planet is a feed aggregator written in Python. It depends heavily on
SGMLLib. A recent bug report turned out to be a deficiency in sgmllib,
and I've submitted a test case and a patch[1] (use or discard the patch,
it is the test that I care about).
I think (but am not
Neal Norwitz wrote:
The most important outstanding issue is the xmlplus/xmlcore issue.
It's not going to get fixed unless someone works on it. There's only
a few days left before beta 1. Can someone please address this?
From my point of view, I shall consider them resolved/irrelevant:
I'm
Martin v. Löwis wrote:
Alternatively, a callback function could be provided for character
references. Unfortunately, the existing callback is unsuitable,
as it is supposed to do the full processing; this callback should
return the replacement text. Generally assuming Unicode would be
wrong,
34 matches
Mail list logo