From the web site it looks like the free version does not include the
debugging stuff.
I've been using the paid version with the debugger functionality and I
find it easy to use and incredibly nice for trying to understand what
the code is doing. The built-in debugger has saved me tons of t
Would Python be an efficient language to go about coding something
like the toolbar from http://www.wibiya.com/index.php ?
And then, how would I implement it?
-Kenny Ledet
Owner of Hotontheblock.com, Urban News Blog
--
http://mail.python.org/mailman/listinfo/python-list
Colin J. Williams wrote:
Steven
D'Aprano wrote:
On Fri, 14 Aug 2009 15:54:54 +, Alan G Isaac wrote:
`lst` is a nested list
`tpl` is the indexes for an item in the list
What is the nice way to retrieve the item? (Speedy access is nice.)
Assuming you want to do this frequently, write a
Dave Angel wrote:
Colin J. Williams wrote:
Steven
D'Aprano wrote:
On Fri, 14 Aug 2009 15:54:54 +, Alan G Isaac wrote:
`lst` is a nested list
`tpl` is the indexes for an item in the list
What is the nice way to retrieve the item? (Speedy access is nice.)
Assuming you want to do thi
On Aug 14, 11:28 am, Asanka Wasala wrote:
> Hi
> I am developing a spell checker for my language, and I came across
> solving an interesing problem. It would be great if you can suggest
> me an optimized solution for the problem described below:
>
> I have certain group of letters like these:
>
>
Grant Edwards wrote:
On 2009-08-14, Steven D'Aprano wrote:
What the hell
would it actually do???
IIRC in C++,
cout << "Hello world";
is equivalent to this in C:
printf("Hellow world");
or this in Python:
print "hellow world"
Well, plus or minus newlines.
--
Erik Max Francis
On 2009-08-14, Erik Max Francis wrote:
> Grant Edwards wrote:
>> On 2009-08-14, Steven D'Aprano wrote:
>>> What the hell
>>> would it actually do???
>>
>> IIRC in C++,
>>
>>cout << "Hello world";
>>
>> is equivalent to this in C:
>>
>>printf("Hellow world");
>>
>> or this in Python:
Grant Edwards wrote:
On 2009-08-14, Erik Max Francis wrote:
Grant Edwards wrote:
On 2009-08-14, Steven D'Aprano wrote:
What the hell
would it actually do???
IIRC in C++,
cout << "Hello world";
is equivalent to this in C:
printf("Hellow world");
or this in Python:
print "hello
Steven D'Aprano wrote:
On Fri, 14 Aug 2009 18:49:26 +0200, Jean-Michel Pichavant wrote:
Sorry guys (means guys *and* gals :op ), I realized I've not been able
to describe precisely what I want to do. I'd like the base class to be
virtual (aka abstract). However it may be abstract but it does
Sometimes I want to split a string into lines, preserving the
end-of-line markers. In Perl this is really easy to do, by splitting
on the beginning-of-line anchor:
@lines = split /^/, $string;
But I can't figure out how to do the same thing with Python. E.g.:
>>> import re
>>> re.split('^'
I want to do some rrd in a python cgi script, but am having trouble
getting an easy install module.
py-rrdTool looks good, but is distributed in c source, and is missing
a header file in the distribution. Thus the install fails when it
tries to reference rrd.h which is not there.
Are there better
kj wrote:
Sometimes I want to split a string into lines, preserving the
end-of-line markers. In Perl this is really easy to do, by splitting
on the beginning-of-line anchor:
@lines = split /^/, $string;
But I can't figure out how to do the same thing with Python. E.g.:
import re
re.spl
On Fri, Aug 14, 2009 at 3:23 PM, kj wrote:
> [snip]
import re
re.split('^', 'spam\nham\neggs\n')
> ['spam\nham\neggs\n']
re.split('(?m)^', 'spam\nham\neggs\n')
> ['spam\nham\neggs\n']
bol_re = re.compile('^', re.M)
bol_re.split('spam\nham\neggs\n')
> ['spam\nham\neggs\n']
>
guthrie schrieb:
I want to do some rrd in a python cgi script, but am having trouble
getting an easy install module.
py-rrdTool looks good, but is distributed in c source, and is missing
a header file in the distribution. Thus the install fails when it
tries to reference rrd.h which is not there
On Fri, Aug 14, 2009 at 5:23 PM, kj wrote:
>
import re
re.split('^', 'spam\nham\neggs\n')
> ['spam\nham\neggs\n']
re.split('(?m)^', 'spam\nham\neggs\n')
> ['spam\nham\neggs\n']
bol_re = re.compile('^', re.M)
bol_re.split('spam\nham\neggs\n')
> ['spam\nham\neggs\n']
>
> Am I
On Fri, Aug 14, 2009 at 2:23 PM, kj wrote:
>
>
> Sometimes I want to split a string into lines, preserving the
> end-of-line markers. In Perl this is really easy to do, by splitting
> on the beginning-of-line anchor:
>
> @lines = split /^/, $string;
>
> But I can't figure out how to do the same
On Fri, Aug 14, 2009 at 12:42 PM, Douglas Alan wrote:
>
> P.S. Overloading "left shift" to mean "output" does indeed seem a bit
> sketchy, but in 15 years of C++ programming, I've never seen it cause
> any confusion or bugs.
The only reason it hasn't is because people use it in "Hello World". I
Dave Angel wrote:
Jean-Michel Pichavant wrote:
Nigel
Rantor wrote:
Jean-Michel Pichavant wrote:
Your solution will work, for sure. The problem is that it will dumb
down the Base class interface, multiplying the number of methods by
2. This would not be an issue in many cases, in mine there'
On Fri, Aug 14, 2009 at 3:28 PM, Kee Nethery wrote:
> From the web site it looks like the free version does not include the
> debugging stuff.
>
> I've been using the paid version with the debugger functionality and I find
> it easy to use and incredibly nice for trying to understand what the code
Personally, I rather like Wing
From: Kee Nethery
To: python-list@python.org
Sent: Friday, August 14, 2009 3:28:54 PM
Subject: Re: Komodo(!)
>From the web site it looks like the free version does not include the
>debugging stuff.
I've been using the paid versi
Gary Herron wrote:
kj wrote:
Sometimes I want to split a string into lines, preserving the
end-of-line markers. In Perl this is really easy to do, by splitting
on the beginning-of-line anchor:
@lines = split /^/, $string;
But I can't figure out how to do the same thing with Python. E.g.:
> akonsu (a) wrote:
>a> hello,
>a> i am looking for a module with functionality similar to that of the
>a> Perl's Mail::GPG package. I need to verify multipart emails that are
>a> PGP-signed.
I don't know Perl's GPG package, but to verify PGP-signed stuff you can
use gnupg. It doesn't have s
kj wrote:
Sometimes I want to split a string into lines, preserving the
end-of-line markers. In Perl this is really easy to do, by splitting
on the beginning-of-line anchor:
@lines = split /^/, $string;
But I can't figure out how to do the same thing with Python. E.g.:
import re
re.spli
-On [20090814 18:39], Prateek (prateekkakir...@gmail.com) wrote:
>Can somebody please provide me link to a good online resource or e-
>book for doing natural language processing programming in Python.
http://www.nltk.org/ comes to mind.
--
Jeroen Ruigrok van der Werven / asmodai
イェルーン
> kj (k) wrote:
>k> Sometimes I want to split a string into lines, preserving the
>k> end-of-line markers. In Perl this is really easy to do, by splitting
>k> on the beginning-of-line anchor:
>k> @lines = split /^/, $string;
>k> But I can't figure out how to do the same thing with Python
On Aug 14, 2:23 pm, kj wrote:
> Sometimes I want to split a string into lines, preserving the
> end-of-line markers. In Perl this is really easy to do, by splitting
> on the beginning-of-line anchor:
>
> @lines = split /^/, $string;
>
> But I can't figure out how to do the same thing with Pytho
class Vertex(tuple):
pass
class Positioned_Vertex(Vertex):
def __init__(self, a, b):
Vertex.__init__(a)
a=Positioned_Vertex((0,0,0), 1)
This gives:
TypeError: tuple() takes at most 1 argument (2 given)
It looks like the explicit call to Vertex.__init__ is never made and
Vertex
Jean-Michel Pichavant wrote:
talking about approaches:
1/
class Interface:
def foo(self):
if self.__class__.foo == Interface.foo:
raise NotImplementedError
2/
class Interface:
def foo(self):
self._foo()
def _foo(sef):
raise NotImplementedError
Pleas
With your help, Franck, I think I finally got it to work. This is how
I did it:
# In the main program, launch the 2 threads CStoreData and
CTransferData, which will run indefinitely until they are stopped (if
the threads were launched inside the while loop, there would be an
infinitely growing num
With your help, Franck, I think I finally got it to work. This is how
I did it:
# In the main program, launch the 2 threads CStoreData and
CTransferData, which will run indefinitely until they are stopped (if
the threads were launched inside the while loop, there would be an
infinitely growing num
With your help, Franck, I think I finally got it to work. This is how
I did it:
# In the main program, launch the 2 threads CStoreData and
CTransferData, which will run indefinitely until they are stopped (if
the threads were launched inside the while loop, there would be an
infinitely growing num
Ethan Furman wrote:
kj wrote:
Sometimes I want to split a string into lines, preserving the
end-of-line markers. In Perl this is really easy to do, by splitting
on the beginning-of-line anchor:
@lines = split /^/, $string;
But I can't figure out how to do the same thing with Python. E.g.:
On Fri, 14 Aug 2009 19:57:17 +0200, Jean-Michel Pichavant
wrote:
> vippstar wrote:
>> On Aug 14, 8:25 pm, fortunatus wrote:
>>
>>> On Aug 14, 1:01 pm, vippstar wrote:
>>>
>>>
Why would you fill your website with junk?
>>> The OP made it clear:
>>>
>>>
Just wanted to exp
David wrote:
With your help, Franck, I think I finally got it to work. This is how
I did it:
# In the main program, launch the 2 threads CStoreData and
CTransferData, which will run indefinitely until they are stopped (if
the threads were launched inside the while loop, there would be an
infinit
>> Specifically, put the source code into /net/source/python/foo/*.py.
>> Then, on each system, put symlinks to all .py files into
>> lib/site-packages/foo. Then Python will place the .pyc files next
>> to the symlinks, not next to the actual .py files.
>
> Why would he need two sets of .py files?
> He's assuming:
>1) an OS that supports symlinks
>2) two versions of Python on same system
>3) one set of pure-python sources that want to stay in synch for both
> versions.
Actually, the OP said he has HP(-UX, I assume), and Linux, so it would
be two versions of Python on different
On Fri, Aug 14, 2009 at 4:46 PM, magicus wrote:
> On Fri, 14 Aug 2009 19:57:17 +0200, Jean-Michel Pichavant
> wrote:
>
> > vippstar wrote:
> >> On Aug 14, 8:25 pm, fortunatus wrote:
> >>
> >>> On Aug 14, 1:01 pm, vippstar wrote:
> >>>
> >>>
> Why would you fill your website with junk?
> >>
MRAB wrote:
Ethan Furman wrote:
kj wrote:
Sometimes I want to split a string into lines, preserving the
end-of-line markers. In Perl this is really easy to do, by splitting
on the beginning-of-line anchor:
@lines = split /^/, $string;
But I can't figure out how to do the same thing with
pinkisntwell wrote:
class Vertex(tuple):
pass
class Positioned_Vertex(Vertex):
def __init__(self, a, b):
def __init__(self, a): # just take out b
Vertex.__init__(a)
a=Positioned_Vertex((0,0,0), 1)
a=Positioned_Vertex( ( (0,0,0), 1) ) # and add a pair of brackets
print a
Th
On Aug 13, 11:41 pm, naaman wrote:
> On Aug 13, 7:50 am, Dave Angel wrote:
>
>
>
> > naaman wrote:
> > > On Aug 12, 1:35 pm, Dave Angel wrote:
>
> > >> naaman wrote:
>
> > >>> I'm writing my first Python script and
> > >>> I want to use fileinput to open a file in r+ mode.
> > >>> Tried fileinpu
En Fri, 14 Aug 2009 19:24:26 -0300, pinkisntwell
escribió:
class Vertex(tuple):
pass
class Positioned_Vertex(Vertex):
def __init__(self, a, b):
Vertex.__init__(a)
a=Positioned_Vertex((0,0,0), 1)
This gives:
TypeError: tuple() takes at most 1 argument (2 given)
It looks l
Suppose you need to split a string into substrings of a given size (except
possibly the last substring). I make the hypothesis the first slice is at the
end of the string.
A typical example is provided by formatting a decimal string with thousands
separator.
What is the pythonic way to do this ?
En Fri, 14 Aug 2009 21:22:57 -0300, candide
escribió:
Suppose you need to split a string into substrings of a given size
(except
possibly the last substring). I make the hypothesis the first slice is
at the
end of the string.
A typical example is provided by formatting a decimal string wi
I wrote the following correct but inefficient test of primality for purposes
of demonstrating that the simplest algorithm is often not the most
efficient. But, when I try to run the following code with a value of n that
is large enough to produce a significant amount of running time, I get an
out
dippim wrote:
On Aug 14, 10:48 am, Dave Angel wrote:
dippim wrote:
On Aug 14, 2:34 am, Raymond Hettinger wrote:
[David]
I am new to Python and I have a question about descriptors. If I have
a class as written below, is there a way to use descriptors to be
certain that the datetime in
>
> It seems as though Python is actually expanding range(2,n) into a list of
> numbers, even though this is incredibly wasteful of memory. There should be
> a looping mechanism that generates the index variable values incrementally
> as they are needed.
This has nothing to do with Python's for l
Dr. Phillip M. Feldman wrote:
I wrote the following correct but inefficient test of primality for purposes
of demonstrating that the simplest algorithm is often not the most
efficient. But, when I try to run the following code with a value of n that
is large enough to produce a significant amoun
Charles Yeomans wrote:
On Aug 14, 2009, at 12:09 AM, Scott David Daniels wrote:
Charles Yeomans wrote:
On Aug 11, 2009, at 3:30 PM, Ethan Furman wrote:
Ethan Furman wrote:
Greetings!
I have seen posts about the assert statement and PbC (or maybe it
was DbC), and I just took a very b
Dr. Phillip M. Feldman wrote:
I wrote the following correct but inefficient test of primality for purposes
of demonstrating that the simplest algorithm is often not the most
efficient. But, when I try to run the following code with a value of n that
is large enough to produce a significant amoun
dippim wrote:
will say that as this particular requirement is imposed on this class
by the writer, shouldn't it be the writer's responsibility to enforce
it, especially, when the cost of enforcement is so low?
I would say that it is the writer's responsibility to set the
requirement and be cl
greg wrote:
You can't read and write with the same stdio file object
at the same time. Odd things tend to happen if you try.
I believe the C standard specifies that the behavior of mixed reads and
writes is undefined without intervening seek and/or flush, even if the
seek is ignored (as it i
On Aug 14, 8:25 pm, "Dr. Phillip M. Feldman"
wrote:
> I wrote the following correct but inefficient test of primality for purposes
> of demonstrating that the simplest algorithm is often not the most
> efficient. But, when I try to run the following code with a value of n that
> is large enough t
15-08-2009 candide wrote:
Suppose you need to split a string into substrings of a given size
(except
possibly the last substring). I make the hypothesis the first slice is
at the end of the string.
A typical example is provided by formatting a decimal string with
thousands separator.
I'd
Benjamin Kaplan wrote:
On Fri, Aug 14, 2009 at 12:42 PM, Douglas Alan wrote:
P.S. Overloading "left shift" to mean "output" does indeed seem a bit
sketchy, but in 15 years of C++ programming, I've never seen it cause
any confusion or bugs.
The only reason it hasn't is because people
15-08-2009 Jan Kaliszewski wrote:
15-08-2009 candide wrote:
Suppose you need to split a string into substrings of a given size
(except
possibly the last substring). I make the hypothesis the first slice is
at the end of the string.
A typical example is provided by formatting a decimal str
On Aug 14, 3:39 pm, Christian Heimes wrote:
> guthrie schrieb:
>
>
>
> > I want to do some rrd in a python cgi script, but am having trouble
> > getting an easy install module.
>
> > py-rrdTool looks good, but is distributed in c source, and is missing
> > a header file in the distribution. Thus t
I am writing an application which has many command line arguments.
For example: foo.py -args "bar bee"
I would like to create a test suit using unittest so when I add
features to "foo.py" I don't want to break other things. I just heard
about unittest and would love to use it for this type of thin
"Tim Arnold" wrote in message
news:h61gld$it...@foggy.unx.sas.com...
> Hi,
> I've got a python based system that has to run on hp unix and red hat
> linux. The Python version on the HP is 2.4 and the version on the Linux
> box is 2.6. There's nothing I can do about that.
>
> I think that means
Chris Withers writes on Thu, 13 Aug 2009 08:20:37
+0100:
> ...
> I've already established that the file downloads in seconds with
> [something else], so I'd like to understand why python isn't doing the
> same and fix the problem...
A profile might help to understand what the time is used for.
I'm checking back with some new info.
Apparently the maintainer of the ogss package indicated that this is
definately an issue with the libgmail package.
Now I have already submtted help to the maintainer of libgmail to get some
help it making his project work again.
I am also interesetd in how
On Aug 8, 3:27 pm, Mark Lawrence wrote:
> Kee Nethery wrote:
> > As someone trying to learn the language I want to say that the tone on
> > this list towards people who are trying to learn Python feels like it
> > has become anti-newbies.
>
> [snip]
>
> > Kee Nethery
>
> My gut feeling (which cou
I'm bored for posting this, but here it is:
def add_commas(str):
str_list = list(str)
str_len = len(str)
for i in range(3, str_len, 3):
str_list.insert(str_len - i, ',')
return ''.join(str_list)
--
http://mail.python.org/mailman/listinfo/python-list
On Aug 15, 4:28 am, Mag Gam wrote:
> I am writing an application which has many command line arguments.
> For example: foo.py -args "bar bee"
>
> I would like to create a test suit using unittest so when I add
> features to "foo.py" I don't want to break other things. I just heard
> about unittest
101 - 163 of 163 matches
Mail list logo