On Mar 5, 5:49 pm, Fab86 wrote:
> On Mar 5, 5:23 pm, Marco Mariani wrote:
>
>
>
> > Fab86 wrote:
> > > Is it possible to get the program to catch the exception, wait 10
> > > seconds, then carry of from where it was rather than starting again?
>
> > something like this? probably works in PASCAL a
Graham Dumpleton wrote:
>
> I don't understand the problem, you can say where it installs the
> framework, it doesn't have to be under /Library, so can be in your
> special SDK folder. For example:
>
> ./configure --prefix=/usr/local/python-2.5.4 \
> --enable-framework=/usr/local/python-2.5.4/fra
> Aaron explained it better than I did. Basically the C/C++ module uses
> C/C++ version of Facet class directly without consulting python
> interpreter, this is what I meant by static linking.
Thanks so much for the explanation Lie, I understood it fully now.
Thanks again,
-jelle
--
http:
Hi everyone,
I wrote a logging server that receives messages from
logging.handlers.SocketHandler objects in client Python programs. This
works well so long as the client programs are start/stop affairs.
However, if the client is also a long running daemon a problem shows
up. If the logging server
On Thu, 05 Mar 2009 18:07:29 +0100, Peter Otten <__pete...@web.de> wrote:
[snip]
>
> Just for fun here's an alternative version of your function
>
> def generate_crossover(pop, prob):
> for a, b in zip(*[iter(pop)]*2):
. . .
Good grief! That's devilishly obscure.
--
To email me, substitute
Fab86 writes:
> On Mar 5, 5:23 pm, Marco Mariani wrote:
>> Fab86 wrote:
>> > Is it possible to get the program to catch the exception, wait 10
>> > seconds, then carry of from where it was rather than starting again?
>>
>> something like this? probably works in PASCAL as well :)
>>
>> > i=0
>> >
Il Thu, 05 Mar 2009 15:48:01 +, mattia ha scritto:
> Il Wed, 04 Mar 2009 21:30:54 +0100, Peter Otten ha scritto:
>
>> mattia wrote:
>>
>>> Hi everyone, I'm new to python and I want to create some simple code
>>> in order to code the classical genetic algorithm example: given a
>>> population
Paul Hildebrandt yahoo.com> writes:
>
> I really like the look of Sphinx BUT I want autogenerated
> documentation like Epydoc/doxygen. Does anyone know of a frontend for
> Sphix that will make it work like Epydoc?
There's a Sphinx extension called autodoc which should help you.
--
http://m
Benjamin Peterson wrote:
> Paul Hildebrandt yahoo.com> writes:
>> I really like the look of Sphinx BUT I want autogenerated
>> documentation like Epydoc/doxygen. Does anyone know of a frontend for
>> Sphix that will make it work like Epydoc?
>
> There's a Sphinx extension called autodoc which sho
Hey list,
I was given a task, to reproduce functionality of command specified
below by writing proper python functions to reuse in some monitoring
script:
rivendell# snmpwalk -Os -mALL -v1 -cgabilgathol 10.0.6.66
.1.3.6.1.4.1.2636.5.1.1.2
jnxBgpM2PeerIdentifier.0.ipv4."".unknown."".0.1.38.101.87.
> for a, b in zip(*[iter(pop)]*2):
In the python documentation there is a similar example, well, the obscure
thing here is the usage of *[iter(pop)]! Then I believe that I can safely
say that you iterate over the values 0 and 1, 2 and 3 etc. because the
zip automatically updates the index, i
On Mar 5, 9:01 am, Tino Wildenhain wrote:
> Piet van Oostrum wrote:
> >> Andre Engels (AE) wrote:
>
> >> AE> On Wed, Mar 4, 2009 at 11:02 AM, lone_eagle wrote:
> Can someone suggest a easy method to do the inverse of dict(zip(x,y))
> to get two lists x and y?
>
> So, if x and
Il Thu, 05 Mar 2009 18:07:29 +0100, Peter Otten ha scritto:
> mattia wrote:
>
>> The last question: how can I improve readability in this piece of code?
>>
>> def crossover(pop, prob=0.6):
>> """
>> With a crossover probability cross over the parents to form new
>> offspring. If no c
On Mar 5, 12:32 pm, SpamMePlease PleasePlease
wrote:
> Hey list,
>
> I was given a task, to reproduce functionality of command specified
> below by writing proper python functions to reuse in some monitoring
> script:
>
> rivendell# snmpwalk -Os -mALL -v1 -cgabilgathol 10.0.6.66
> .1.3.6.1.4.1.263
On Mar 5, 1:05 pm, birdsong wrote:
> On Mar 5, 12:32 pm, SpamMePlease PleasePlease
>
>
>
> wrote:
> > Hey list,
>
> > I was given a task, to reproduce functionality of command specified
> > below by writing proper python functions to reuse in some monitoring
> > script:
>
> > rivendell# snmpwalk
2009/3/5 andrew cooke :
> Benjamin Peterson wrote:
>> Paul Hildebrandt yahoo.com> writes:
>>> I really like the look of Sphinx BUT I want autogenerated
>>> documentation like Epydoc/doxygen. Does anyone know of a frontend for
>>> Sphix that will make it work like Epydoc?
>>
>> There's a Sphinx ex
On Mar 6, 1:28 am, MRAB wrote:
> Aahz wrote:
> > In article ,
> > Terry Reedy wrote:
> >> for line in open('char.txt'):
> >> if line.find('sweet') != -1 or line.find('blue') != -1:
> >> print(line)
>
> > For any recent Python, this should be:
>
> > if 'sweet' in line or 'blue' in line:
On Thu, Mar 5, 2009 at 10:12 PM, birdsong wrote:
> On Mar 5, 1:05 pm, birdsong wrote:
>> On Mar 5, 12:32 pm, SpamMePlease PleasePlease
>>
>>
>>
>> wrote:
>> > Hey list,
>>
>> > I was given a task, to reproduce functionality of command specified
>> > below by writing proper python functions to re
Hi Folks,
I know PHP can do shopping cart, such as Zen Cart. I wonder can Python
do such a thing? Thanks!
Muddy Coder
--
http://mail.python.org/mailman/listinfo/python-list
On Mar 6, 6:24 am, Uberman wrote:
> Graham Dumpleton wrote:
>
> > I don't understand the problem, you can say where it installs the
> > framework, it doesn't have to be under /Library, so can be in your
> > special SDK folder. For example:
>
> > ./configure --prefix=/usr/local/python-2.5.4 \
> >
On Thu, Mar 5, 2009 at 11:30 PM, Muddy Coder wrote:
> Hi Folks,
>
> I know PHP can do shopping cart, such as Zen Cart. I wonder can Python
> do such a thing? Thanks!
>
>
>
> Muddy Coder
> --
> http://mail.python.org/mailman/listinfo/python-list
>
Python can do that and a lot more! For this purpos
On Mar 6, 4:13 am, Johannes Permoser wrote:
> Hi,
>
> I wanted to learn Python from scratch and start off with Version 3.
> Since I already know PHP very well, I thought it would be nice to start
> off with a small web-project.
>
> But what's the way to bring python3 to the Web?
> mod_python isn't
On Thu, Mar 5, 2009 at 5:40 PM, SpamMePlease PleasePlease
wrote:
> Python can do that and a lot more! For this purpose I would go to
> http://djangoproject.com/
Django is neat, but there are more choices for you:
http://wiki.python.org/moin/WebFrameworks
--
http://mail.python.org/mailman/listinfo
hi john...
update...
further investigation has revealed that apparently, for some urls/sites, the
server serves up pages that take awhile to be fetched... this appears to be
a potential problem, in that it appears that the parsescript never gets
anything from the python mech/urllib read function
En Thu, 05 Mar 2009 15:26:18 -0200, Darren Dale
escribió:
On Mar 5, 12:02 pm, s...@pobox.com wrote:
What happens if you simply call
my_thread.setDaemon(True)
(or in Python 2.6):
my_thread.daemon = True
? That is the documented way to exit worker threads when you want the
applica
Edzard Pasma wrote:
> Hello,
>
> It looks that the issue with fetch across rollback still can occur in the new
> version. It turned up when I applied the Pysqlite transaction test suite to
> some dbapi2 version of my own. Below is a minimal script to reproduce it. It
> has puzzled me what goes
thought people might find this article on drummer's "click tracks"
interesting -
http://musicmachinery.com/2009/03/02/in-search-of-the-click-track/
here's the python lib used - http://developer.echonest.com/docs/method/remix/
andrew
--
http://mail.python.org/mailman/listinfo/python-list
En Thu, 05 Mar 2009 14:43:12 -0200, Vincent Davis
escribió:
If I have a list and I what to make changes to it.a = [1,2,3,4,5,6,7,8,9]
and maybe I want to drop the odd and double the even numbers and I will
need to do this repeatedly.
How is this best done? That is as a function or class. All
On Mar 5, 2:30 pm, SpamMePlease PleasePlease
wrote:
> On Thu, Mar 5, 2009 at 10:12 PM, birdsong wrote:
> > On Mar 5, 1:05 pm, birdsong wrote:
> >> On Mar 5, 12:32 pm, SpamMePlease PleasePlease
>
> >> wrote:
> >> > Hey list,
>
> >> > I was given a task, to reproduce functionality of command spec
On Mar 5, 2:30 pm, Muddy Coder wrote:
> Hi Folks,
>
> I know PHP can do shopping cart, such as Zen Cart. I wonder can Python
> do such a thing? Thanks!
>
> Muddy Coder
http://www.satchmoproject.com/
--
http://mail.python.org/mailman/listinfo/python-list
En Thu, 05 Mar 2009 14:10:38 -0200, TP
escribió:
Hi everybody,
I have programmed a python package, and I would like to use distutils
with
it. My package has the following structure after doing sdist and build:
$ python setup.py sdist
[...]
$ python setup.py build
[...]
$ tree
.
|-- MANIF
Mike Driscoll wrote:
> On Mar 5, 6:15 am, Steve Holden wrote:
>> Hendrik van Rooyen wrote:
>>> "Steve Holden" wrote:
My well-known-search-engine-foo must be at an all-time low today. *Is*
there an index and I can't see for looking?
>>> typing in python weekly at google gives me:
>>> Py
I guess I am thinking of it as an operation that I am preforming on a list
and not making a new list. Also looking to learn better methods. This is
difficult when you are working alone. It is difficult to know where to
improve.
The actual functions I am making are more complicated than this example
On Mar 5, 1:22 pm, Benjamin Peterson wrote:
> 2009/3/5 andrew cooke :
>
> > Benjamin Peterson wrote:
> >> Paul Hildebrandt yahoo.com> writes:
> >>> I really like the look of Sphinx BUT I want autogenerated
> >>> documentation like Epydoc/doxygen. Does anyone know of a frontend for
> >>> Sphix th
Vincent Davis wrote:
> I guess I am thinking of it as an operation that I am preforming on a list
> and not making a new list. Also looking to learn better methods. This is
> difficult when you are working alone. It is difficult to know where to
> improve.
python occupies a strange place. in some
Problem solved
Yinon's messages prompted me to take another look at my own code
(below). I realized that in the batch file I am looking for pydoc.py
in different locations for Python25 and Python26, but I am executing
python.exe without changing the path. Which means that I am executing
the same
In article ,
Hendrik van Rooyen wrote:
>"Ben Finney" wrote:
>>a...@pythoncraft.com (Aahz) writes:
>>> In article ,
>>> Hendrik van Rooyen wrote:
Occam was the language that should have won the marketing prize,
but didn't.
>>>
>>> It wasn't simple enough.
>>
>>*bdom-tsssh* http://en
On 2009-03-05 19:23, Paul Hildebrandt wrote:
Thanks, I've been playing with that but I believe it assumes a reST
structure you build, then use autodoc to bring in your code's
docstrings. I would rather not hand generate the main reST
structure. I am hoping to use Sphinx like Epydoc and just ru
Please don't top-post.
On Fri, 06 Mar 2009 01:09:48 -, Vincent Davis
wrote:
I guess I am thinking of it as an operation that I am preforming on a
list
and not making a new list. Also looking to learn better methods. This is
difficult when you are working alone. It is difficult to know
This is an interesting post, it shows me that fitness plateau where
design of Python syntax lives is really small, you can't design
something just similar:
http://unlimitednovelty.com/2009/03/indentation-sensitivity-post-mortem.html
Living on a small fitness plateau isn't good, even if it's very
I'm not sure if this problem I face affects many other people, but I'll just
describe it and see what kind of feedback I get.
I have a suggestion for a new piece of Python syntax when defining methods.
I have seen the following done, and have done it myself
class FanstasticClass:
def __init
bearophileh...@lycos.com wrote:
> This is an interesting post, it shows me that fitness plateau where
> design of Python syntax lives is really small, you can't design
> something just similar:
>
>
http://unlimitednovelty.com/2009/03/indentation-sensitivity-post-mortem.html
>
> Living on a small
bearophileh...@lycos.com wrote:
Living on a small fitness plateau isn't good, even if it's very high,
because it's evolutionary unstable :-(
Actually I think, in biological sense speaking [citation needed], if one
path has an advantage over the other path, even if the other path is in
majori
On Mar 5, 5:38 pm, Robert Kern wrote:
> On 2009-03-05 19:23, Paul Hildebrandt wrote:
>
> > Thanks, I've been playing with that but I believe it assumes a reST
> > structure you build, then use autodoc to bring in your code's
> > docstrings. I would rather not hand generate the main reST
> > struc
bearophileh...@lycos.com writes:
> Indentation-wise Haskell syntax seems one of the very few local maxima
> that is close enough to the little fitness plateau where Python is.
It is odd, the article claims indentation-aware syntax only works
in languages that separate statement and expressions, bu
Python can do.
On 5 mar, 19:30, Muddy Coder wrote:
> Hi Folks,
>
> I know PHP can do shopping cart, such as Zen Cart. I wonder can Python
> do such a thing? Thanks!
>
> Muddy Coder
--
http://mail.python.org/mailman/listinfo/python-list
Hello All,
I am trying to create a singleton window in pygtk and for the life of me
can't seem to figure out a better way to go about doing this. The way I'm
doing it now is to recreate the window and show it. Example code is below. I
would much appreciate any assistance in this matter. I've googl
On Thu, Mar 5, 2009 at 6:17 PM, Tennessee Leeuwenburg
wrote:
> I'm not sure if this problem I face affects many other people, but I'll just
> describe it and see what kind of feedback I get.
>
> I have a suggestion for a new piece of Python syntax when defining methods.
> I have seen the following
Correction, it's not True singleton.
-Alex Goretoy
http://www.goretoy.com
On Thu, Mar 5, 2009 at 10:38 PM, alex goretoy
wrote:
> Hello All,
>
> I am trying to create a singleton window in pygtk and for the life of me
> can't seem to figure out a better way to go about doing this. The way I
On Fri, Mar 6, 2009 at 3:39 PM, Chris Rebert wrote:
> On Thu, Mar 5, 2009 at 6:17 PM, Tennessee Leeuwenburg
> wrote:
> > I'm not sure if this problem I face affects many other people, but I'll
> just
> > describe it and see what kind of feedback I get.
> >
> > I have a suggestion for a new piece
Tennessee Leeuwenburg wrote:
I'm not sure if this problem I face affects many other people, but I'll
just describe it and see what kind of feedback I get.
I have a suggestion for a new piece of Python syntax when defining
methods. I have seen the following done, and have done it myself
clas
Jean-Paul Calderone wrote:
On Thu, 05 Mar 2009 18:13:05 +0100, Johannes Permoser
wrote:
Hi,
I wanted to learn Python from scratch and start off with Version 3.
Since I already know PHP very well, I thought it would be nice to start
off with a small web-project.
But what's the way to bring pyt
-Original Message-
From: Bruno Desthuilliers [mailto:bruno.42.desthuilli...@websiteburo.invalid]
Sent: Thursday, March 05, 2009 10:45 PM
To: python-list@python.org
Subject: Re: Help required to read and print lines based on the type of first
character
abhinayaraj.r...@emulex.com a écrit
On 05 Mar 2009 20:43:41 GMT, mattia wrote:
>> for a, b in zip(*[iter(pop)]*2):
> In the python documentation there is a similar example, well, the obscure
> thing here is the usage of *[iter(pop)]! Then I believe that I can safely
> say that you iterate over the values 0 and 1, 2 and 3 etc.
I wish to catch an exception, modify the error message, and re-raise it.
There are two ways I know of to do this, with subtly different effects:
>>> def raise_example1():
... try:
... None()
... except TypeError, e:
... e.args = ('modified error message',) + e.args[
You need to parse the MIB file to get the human-readable names
corresponding to the OIDs. The pysnmp library already provides this
functionality. I haven't used this feature myself (I mainly use pysnmp
to automate SNMP walk requests, like the one in your code), but the
documentation at found the be
Hi All,
I want to read the Special Administration Console (SAC) output spew
using python. Is it possible for me? If yes, please help me how to do
that?
Thanks,
Kishore
--
http://mail.python.org/mailman/listinfo/python-list
Hi Folks,
If I have a python file foo.py in the current directory, I can simply
import it in the way below:
import foo
when a project keeps grow, more and more Python files are created, and
they are also needed to put into different directories. Then, a
problem comes: how to import the Python fi
On Thu, Mar 5, 2009 at 10:29 PM, Steven D'Aprano wrote:
> I wish to catch an exception, modify the error message, and re-raise it.
> There are two ways I know of to do this, with subtly different effects:
>
def raise_example1():
> ... try:
> ... None()
> ... except TypeErr
On Mar 4, 1:34 am, "Diez B. Roggisch" wrote:
> DLitgo schrieb:
>
> > Hello everyone,
>
> > I'm curious about creating .app files for the mac using bundlebuilder
> > (or py2app or even py2exe). I'm just about done creating a GUI for a
> > little set of scripts which basically perform batch image ed
Muddy Coder writes:
> If I have a python file foo.py in the current directory, I can
> simply import it in the way below:
>
> import foo
Because the current directory, '.', is in the import search path.
> when a project keeps grow, more and more Python files are created,
> and they are also ne
Muddy Coder schrieb:
> Hi Folks,
>
> If I have a python file foo.py in the current directory, I can simply
> import it in the way below:
>
> import foo
>
> when a project keeps grow, more and more Python files are created, and
> they are also needed to put into different directories. Then, a
> p
"Aahz" wrote:
> In article ,
> Hendrik van Rooyen wrote:
> >If Aahz was trolling, then he got me. I know about William of Occam,
> >after whom the language was named, and his razor, but did not make the
> >association, and answered seriously.
>
> Not trolling, but making a joke. Not always eas
En Fri, 06 Mar 2009 04:29:16 -0200, Steven D'Aprano
escribió:
I wish to catch an exception, modify the error message, and re-raise it.
There are two ways I know of to do this, with subtly different effects:
def raise_example1():
... try:
... None()
... except TypeError,
On Fri, Mar 6, 2009 at 6:56 AM, Shantanu Joshi wrote:
> You need to parse the MIB file to get the human-readable names
> corresponding to the OIDs. The pysnmp library already provides this
> functionality. I haven't used this feature myself (I mainly use pysnmp
> to automate SNMP walk requests, li
On Fri, Mar 6, 2009 at 1:10 AM, birdsong wrote:
> On Mar 5, 2:30 pm, SpamMePlease PleasePlease
> wrote:
>> On Thu, Mar 5, 2009 at 10:12 PM, birdsong wrote:
>> > On Mar 5, 1:05 pm, birdsong wrote:
>> >> On Mar 5, 12:32 pm, SpamMePlease PleasePlease
>>
>> >> wrote:
>> >> > Hey list,
>>
>> >> > I
Steven D'Aprano wrote:
> I wish to catch an exception, modify the error message, and re-raise it.
> There are two ways I know of to do this, with subtly different effects:
>
def raise_example1():
> ... try:
> ... None()
> ... except TypeError, e:
> ... e.args =
101 - 167 of 167 matches
Mail list logo