#x27;HOUR', 'SECOND']
e non come mi aspettavo:
>>>> ['3 MINUTE', '22 HOUR', '28 SECOND']
Saluti e grazie mille...
Alessandro
--
http://mail.python.org/mailman/listinfo/python-list
Thanks for the reply it's ok!!!
The language? I selected the wrong newsgroup in my
newsreader!!!...sorry...
Thanks...
Alessandro...
--
http://mail.python.org/mailman/listinfo/python-list
way for closing a "forever
server" or if there is a lack in my design.
Thank you!
Alessandro
--
http://mail.python.org/mailman/listinfo/python-list
thanks
infact the server_forever() method is only a serve() method inside an
infinite loop.
many thanks again,
Alessandro
Matimus ha scritto:
> > I want to ask if someone knows a better way for closing a "forever
> > server" or if there is a lack in my design.
>
>
:
def shutdown():
sys.exit()
but it doesen't work because the server remain alive...maybe
SocketServer create immortal server...
I need only to close my application, there is a way to force the server
thread to close?
thanks!
Alessandro
Laszlo Nagy ha scritto:
> alessandro írta:
> &
On May 4, 2:38 pm, Alexzive wrote:
> Hello,
> I have this matrix [20*4 - but it could be n*4 , with n~100,000] in
> file "EL_list" like this:
>
> 1, 1, 2, 3
> 2, 4, 1, 5
> 3, 5, 1, 6
> 4, 7, 5, 6
> 5, 8,
On May 25, 8:38 am, Peter Otten <__pete...@web.de> wrote:
> Alexzive wrote:
> > I am a newby with python. I wrote the following code to extract a text
> > from a file and write it to another file:
>
> > linestring = open(path, 'r').read() #read all the inp file in
> > linestring
>
> > i=linestring.
On May 25, 10:58 am, John Machin wrote:
> On May 25, 6:30 pm, Alessandro wrote:
>
>
>
> > On May 25, 8:38 am, Peter Otten <__pete...@web.de> wrote:
>
> > > Alexzive wrote:
> > > > I am a newby with python. I wrote the following code to extract a
es, but I can't find the file loading function
and there is no examples about it.
I'm going to join the python-excel group
Alessandro
--
http://mail.python.org/mailman/listinfo/python-list
nction in it..
Could you possibly be viewing the source for xlwt (wt being an
abbreviation of WriTe)? xlwt is a fork of pyExcelerator.
I have written about pyExcelerator 'cause the code refers to it! :-)
I think I will try to use xlrd/xlwt.
I have joined the group, I will let you know
Thank
'/some/path_to/directory 1/and_to/directory 2'
notice that the real path can contain BOTH spaces and underscores.
How can I feed it to os.path.exists() ???
thanks
alessandro
--
http://mail.python.org/mailman/listinfo/python-list
people, you're great - best newsgroup I've ever been!
I think I'll go with the glob suggestion - works like a charm!!!
thank you...
alessandro
--
http://mail.python.org/mailman/listinfo/python-list
Il 15/03/2011 09:10, yqyq22 ha scritto:
I would like to put an alphanumeric string like this one
EE472A86441AF2E629DE360 in a list, then iterate inside the entire
string lenght and change each digit with a random digit.
Do u have some suggestion? thanks a lot
hi
I'm not an experienced python
gt; networking/networks that I should know for this
> project? Not the definitions, but just the words; I
> can look up the definitions on webopedia. It would be
> appreciated. Thanks!
> -John
Have a look at http://en.wikipedia.org (search "network" and "TPC/IP"
hon (a
module). Again, have a look at the Extending&Embedding section of the
Python manual.
BTW: are you aware of the existence of PyGTK and wxPython?
HTH
---
Alessandro Bottoni
--
http://mail.python.org/mailman/listinfo/python-list
net is the right place for it.
HTH
-------
Alessandro Bottoni
--
http://mail.python.org/mailman/listinfo/python-list
Hi to all.
Is there a way, maybe using 4suite, to read a wsdl file and find for
every method all the input/output params and their type?
--
http://mail.python.org/mailman/listinfo/python-list
perience,
and I like nature and mainly horses).
Thanks
Alessandro Brollo
___
Yahoo! Mail: gratis 1GB per i messaggi e allegati da 10MB
http://mail.yahoo.it
--
http://mail.python.org/mailman/listinfo/python-list
.
---
Alessandro Bottoni
--
http://mail.python.org/mailman/listinfo/python-list
ne or more file and/or one
or more URL attached to them in some way) to many diverse recipients (I
normally do not use ICQ and/or Jabber and I know them very little. Any
advise or suggestion about this task is greatly welcome).
Thanks in advance
---
Alessandro Botton
u to write down a new recipe for the ASPN Python
Cookbook based on these code snippets? This is exactly the kind of thing
the people is happy to find at ASPN.
CU
---
Alessandro Bottoni
--
http://mail.python.org/mailman/listinfo/python-list
utomatic converter at:
http://no.spam.ee/~andreie/software/py2pas/english-index.html
(Now offline)
CU
---
Alessandro Bottoni
--
http://mail.python.org/mailman/listinfo/python-list
would have to re-create a lot of
Python-wxWidgets integration that already exists. Use wxPython instead
(www.wxpython.org). There is a quite good GUI builder for wxPython that is
called wxGlade. It can generate XML files that are easier to maintain than
C o Python code.
CU
changes are
exhaustively described both in the official documentation and in the very
fine "what's new in..." articles written by Andrew Kuchlin for every new
release (see www.python.org).
CU
---
Alessandro Bottoni
--
http://mail.python.org/mailman/listinfo/python-list
G. Have a look at GNUPlot
documentation for this.
HTH
-------
Alessandro Bottoni
--
http://mail.python.org/mailman/listinfo/python-list
in the wrong way,
this tool (like the original Java Server Pages) can make a real mess of
your code (because of the inextricable tangle of Python and HTML code you
can create).
CU
---
Alessandro Bottoni
--
http://mail.python.org/mailman/listinfo/python-list
://jabberpy.sourceforge.net/
pyxmpp (looks like the "official" python library)
http://pyxmpp.jabberstudio.org/
xmpp.py (a russian alternative. Very well documented and apparently quite
complete)
http://xmpppy.sourceforge.net/
Anything else?
TIA
---
Alessandro Botton
ompile your stuff, have a look at the
www.python.org site and at the official documentation. You will find a
section devoted to the task of compiling python from source with a list of
the supported compilers (and have a experienced C programmer at hand, if
possible).
HTH
--
are of them:
http://mu.arete.cc/pcr/
http://www.vex.net/parnassus/
http://pythonical.sourceforge.net/
http://www.strout.net/python/intro.html
CU
-------
Alessandro Bottoni
--
http://mail.python.org/mailman/listinfo/python-list
Foundations of Python Network Programming
by John Goerzen
http://www.amazon.com/exec/obidos/tg/detail/-/1590593715/qid=1124694590/sr=2-1/ref=pd_bbs_b_2_1/103-4249885-5594254?v=glance&s=books
It is a fine book and a good investement.
CU
---
Alessandro Bottoni
--
er). That is, Windows has to be requested to executed
this command line:
c:/.../python_directory/python.exe MyProgram.pyw FirstParam SecondParam
Most likely, you are trying to execute this, instead:
c:/.../MyPrograDir/MyProgram.pyw FirstParam SecondParam
HTH
---
Alessandro Bottoni
--
http://mail.python.org/mailman/listinfo/python-list
ine. The second one can just be
better.
HTH
---
Alessandro Bottoni
--
http://mail.python.org/mailman/listinfo/python-list
e are a few articles on this topics on the web, as well. Search
"embedding python" with Google.
---
Alessandro Bottoni
--
http://mail.python.org/mailman/listinfo/python-list
.html
SIP
http://www.river-bank.demon.co.uk/docs/sip/sipref.html
HTH
---
Alessandro Bottoni
--
http://mail.python.org/mailman/listinfo/python-list
like that is available for Konqueror and others
Linux browsers, as well)
HTH
-------
Alessandro Bottoni
--
http://mail.python.org/mailman/listinfo/python-list
on.php (ADO)
http://www.vex.net/parnassus/ (Python Vaults of Parnassus)
Have a look at Kexi, as well (KDE based, no Python involved):
http://www.koffice.org/kexi/
http://www.kexi-project.org/
HTH
---
Alessandro Bottoni
--
http://mail.python.org/mailman/listinfo/
ou really need to play with the source code of this
program? Do you really have to tweak its code to fit your needs? Could not
be enough to write some plug-in, some wrapper or some other kind of
"external" program? This would be much easier.
HTH
---
Aless
find any mention of _encrypted attachments_ on the Net. Does
anybody know of a tutorial or a guide that explains how to encrypt (with
Thunderbird/Enigmail) and decrypt (with Python) the (ANSI text) files
attached to a email message?
TIA
-------
Alessandro Bottoni
--
http://ma
tp://www.vex.net/parnassus/
And at these generic software repositories:
http://freshmeat.net/
http://sourceforge.net/
(search or browse for scientific/chemistry)
HTH
-------
Alessandro Bottoni
--
http://mail.python.org/mailman/listinfo/python-list
I just discovered that Wikipedia has a very fine WikiBook about Python
Programming:
http://en.wikibooks.org/wiki/Programming:Python
I think that most of the newbies (like me ;-) will find it very interesting.
CU
---
Alessandro Bottoni
--
http://mail.python.org
t there is a more complete one
> (including decryption) in
> http://trac.t7a.org/isconf/file/trunk/lib/python/isconf/GPG.py
Thanks for this info. I'm studying it.
---
Alessandro Bottoni
--
http://mail.python.org/mailman/listinfo/python-list
a OODB?
TIA
---
Alessandro Bottoni
--
http://mail.python.org/mailman/listinfo/python-list
hat you can use for this task.
In both cases, you may have to use a loop (sleep(x)) to wait for the return
value (and check it) from within your code.
Have a look at the docu of the os.process module for details. (Maybe the
newer "subprocess" module is a better choice...)
HTH
-
;t help when the change
> happened to files somewhere deeper in the
> hierarchy of directories.
Right. It does not help.
Consider this: if are accessing a network file system, you can intercepts
the calls to the virtualization layer (NFS or NetBIOS). Most likely, Python
can support you
the closest Python equivalent?
Maybe this:
Python Cookbook
Alex Martelli, David Ascher
O'Reilly
HTH
---
Alessandro Bottoni
--
http://mail.python.org/mailman/listinfo/python-list
Apple Platform).
Beside this, wxPython (and wxWidgets) is often told to be more complete,
better documented and better supported than GTK/PyGTK.
HTH
---
Alessandro Bottoni
--
http://mail.python.org/mailman/listinfo/python-list
books
CU
---
Alessandro Bottoni
--
http://mail.python.org/mailman/listinfo/python-list
1254-004 The error code from the last command is 1.
Are you trying to install a posix-thread- (pthread) -enabled Python
interpreter on a not-pthread machine? It looks like the pthread module is
missing.
HTH
---
Alessandro Bottoni
--
http://mail.python.org/mailman/listinfo/python-list
th python ?
> does PyGTK/Glade work on win32 ?
Try wxPython (Based on wxWidgets). Really "free" (LGPL'ed = MIT license) on
all platforms, well-engineered, documented and supported, native look&feel
on all platform. Need anything else? ;-)
HTH
---
Alessandro Bottoni
--
http://mail.python.org/mailman/listinfo/python-list
th-stackless-python/
>
Very interesting!
BTW: I wonder if and when someone will use stackless python or pygame as a
basis for developing a _visual_ development environment for 2D
games/multimedia like Macromedia Director. It would be a killer app.
CU
-------
Aless
as do fancy stuff like rotating :)
>
> Diez
Very interesting, anyway, both in 2D and in 3D. It looks like I have to
study Blender a little bit... :-)
Thanks
---
Alessandro Bottoni
--
http://mail.python.org/mailman/listinfo/python-list
Hi all,
i need to use a regular expression to match javadoc style comments in a file,
something like
/**
* Constructs a new Call instance.
*
* @param object the object the Function shall be executed on
* @param func the Function that shall be executed
,
Alessandro
--
https://mail.python.org/mailman/listinfo/python-list
Hi, i am trying to forge a new cookie by own with cookielib. But i don't
still have success. This a simply code:
import cookielib, urllib, urllib2
login = 'Ia am a cookie!'
cookiejar = cookielib.CookieJar()
urlOpener = urllib2.build_opener(urllib2.HTTPCookieProcessor(cookiejar))
values = {'user':l
Matthew Franz wrote:
> I'm not sure what you mean be forge, but if you mean set an arbitrary
> cookie manually (vs. one that was provided by the server). just use
> add_header() in http://docs.python.org/lib/request-objects.html
Yes is exactly what i want to do... i don't known because i looked
John J. Lee wrote:
> Fine, but see my other post -- I think you misunderstand how cookies
> work.
Maybe you misunderstand me... While i wrote "cookie are simply http
header :)" i want to said that i've look at wrong thing, cookielib are not
needed... Anyway thank you for help, regards.
--
http:
I write this simply code that should give me the access to private page with
htaccess using a proxy, i don't known because it's wrong...
import urllib,urllib2
#input url
url="http://localhost/private/file";
#proxy set up
proxy_handler = urllib2.ProxyHandler({'http': 'http://myproxy:'})
#h
EL, N, Ntop (list?) and how
can I sort Ntop with the criterium based on coordinate_x (coordinate[0])
Many thanks, Alex
--
> Alessandro Zivelonghi
>
> http://www.tecnopolis.eu
>
> skype: alexzive
>
> "Energy and persistence conquer all things."
> Benjamin Franklin (1706 - 1790)
>
--
http://mail.python.org/mailman/listinfo/python-list
; x=9
>
> [idx for idx,row in enumerate(mat) if x in row]
>
> should do.
>
>>
>>
>> PS: this is just a simplified example, but I have actually to deal
>> with large matrices [~50 * 4]
>
> This is something I'd consider either reordering
this seems to work. Thanks!
Alex
x= 3
indices = [i for i, row in enumerate(mat) if x in row[1:]]
2009/3/20 Chris Rebert :
> On Fri, Mar 20, 2009 at 4:34 AM, Alessandro Zivelonghi
> wrote:
>> Many Thanks guys!
>>
>> and what if I need to look ONLY into the second and thi
I'm a beginner and I was trying to write a program to parse recursively all
file names in a directory specified as parameter. The problem is that I get
a "None" printed to stdout when a file is positively matched. While when the
file name doesn't match the regexp the output seems ok.
C:\>c:\python
I can suggest you the lxml library at http://codespeak.net/lxml/
I've already used it and I think it works very well, it's more pythonic
than the built-in xml library
For a simple use of xml functionalities you can read
http://codespeak.net/lxml/tutorial.html
Alessan
Hi,
I'd like to know what is the best way to subclass str
I need to add some new methods and that each method (both new and str
ones) return my new type
For instance I've seen I can do:
class mystr(str):
def between(self, start, end):
i = self.index(start) + len(start)
j = se
Il 07/11/2010 07:41, Chris Rebert wrote:
You could subclass UserString instead of str; all of UserString's
methods seem to ensure that instances of the subclass rather than just
plain strs or UserStrings are returned. See
http://docs.python.org/library/userdict.html#UserString.UserString
I'll
Il 09/11/2010 03:18, Lawrence D'Oliveiro ha scritto:
How exactly does
a.f(b, c)
save time over
f(a, b, c)
unfortunately in real world you have:
objId = objId.method(args)
vs.
objId = moduleName.method(objId, args)
I know you can use "from moduleName import *", but IMHO that pro
] for x in l[j]]),
max([x[2] for x in l[j]])
] for j in dict([
(div(x), []) for x,y,z in [
tuple([int(x) for x in x.split()]) for x in input
if x
]
]).keys()
]
i think it's a bit memory hungry, tho
Hello,
I'ld ask you all about deployment of python applications.
Sometimes (if not most times..) I would make deployment easy (easier)
for my customers (and for me too...)
What I mean, would be very useful to have a "jar-like" archive/single
file / multiple platform in order to deploy also compl
On Jun 15, 1:49 pm, superpollo wrote:
> goal (from e.c.m.): evaluate
> 1^2+2^2+3^2-4^2-5^2+6^2+7^2+8^2-9^2-10^2+...-2010^2, where each three
> consecutive + must be followed by two - (^ meaning ** in this context)
My functional approach :)
from operator import add
from functools import reduce
On Jun 15, 2:37 pm, Peter Otten <__pete...@web.de> wrote:
> >>> from itertools import cycle, izip
> >>> sum(sign*i*i for sign, i in izip(cycle([1]*3+[-1]*2), range(1, 2011)))
Wow!! :D
I didn't knew cycle, great! With that i can reduce my solution (which
isn't still elegant as your) to:
print redu
69 matches
Mail list logo