why greenlet, gevent or the stackless are needed?

2012-07-07 Thread self.python
(I'm very new to this coroutine part so It's not supposed to attack these modules, just I don't know the differences) atfer version 2.5, python officially support coroutine with yield. and then, why greenlet, gevent, Stackless python are still useful? it there somthing that "yield" can't do or ju

Re: What’s the differences between these two pieces of code ?

2012-07-07 Thread Steven D'Aprano
On Fri, 06 Jul 2012 21:56:35 -0700, iMath wrote: > What’s the differences between these two pieces of code ? Have you tried it? What do you see? Obviously the difference is that the second piece calls print() at the end, and the first does not. Since the for-loops are identical, we can ignor

Re: why greenlet, gevent or the stackless are needed?

2012-07-07 Thread Devin Jeanpierre
On Sat, Jul 7, 2012 at 3:09 AM, self.python wrote: > it there somthing that "yield" can't do > or just it is easier or powerful? couroutine-like generators can't give up control flow unless they are the top level function handled by the coroutine controller thing. For example, we can do this:

Re: why greenlet, gevent or the stackless are needed?

2012-07-07 Thread self.python
r 2012년 7월 7일 토요일 오후 4시 33분 26초 UTC+9, Devin Jeanpierre 님의 말: > On Sat, Jul 7, 2012 at 3:09 AM, self.python wrote: > > it there somthing that "yield" can't do > > or just it is easier or powerful? > > couroutine-like generators can't give up control flow unless they are > the top level function

Re: Which way is best to execute a Python script in Excel?

2012-07-07 Thread Maurizio Spadaccino
Thanks again Emile, I'll try out some examples. I found this one: http://showmedo.com/videotutorials/video?name=2190050&fromSeriesID=219 quite enlightning. One last doubt is: say the python code gets used by more Excel Users (different pc), can I include in some way a dinamic generation of the i

Re: Which way is best to execute a Python script in Excel?

2012-07-07 Thread Thomas Jollans
On 07/07/2012 11:05 AM, Maurizio Spadaccino wrote: > Thanks again Emile, I'll try out some examples. I found this one: > http://showmedo.com/videotutorials/video?name=2190050&fromSeriesID=219 > quite enlightning. > One last doubt is: say the python code gets used by more Excel Users > (different

Re: PyEval_SetProfile usage ?

2012-07-07 Thread Thomas Jollans
On 07/06/2012 11:40 PM, Salman Malik wrote: > Hi All, > > I have used the Python's C-API to call some Python code in my c code and > now I want to know how much time does my Python part of the program > takes. I came across the PyEval_SetProfile API and am not sure how to > use it. Do I need to wr

Deditor 0.4.0

2012-07-07 Thread Kruptein
Hey I released a new version of my python-focused text-editor. you can download it at http://launchpad.net/deditor What is it? Deditor is aimed to be a text-editor which can be used as a basic text-editor as gedit or with the right plugins become a full-feature ide. I focus on making it a python

Re: git_revision issues with scipy/numpy/matplotlib

2012-07-07 Thread Hans Mulder
On 7/07/12 07:47:56, Stephen Webb wrote: > I installed py27-numpy / scipy / matplotlib using macports, and it ran > without failing. > > When I run Python I get the following error: > > $>> which python > > /Library/Frameworks/Python.framework/Versions/2.7/bin/python That's a python from pytho

Re: IDLE won't wrap lines of text

2012-07-07 Thread kwame . asamoah . tekyi
i think i understand the question... see when u doing django and u have use the views.py to respond to request in html form,,, its hard to wrap the html codes in idle.. On Sunday, February 20, 2011 11:54:36 PM UTC, Terry Reedy wrote: > On 2/19/2011 6:56 PM, Richard D. Moores wrote: > > Vista >

select module missing/corrupt

2012-07-07 Thread John Pote
We are using a virtual web server running some version of Unix. It has Python versions 2.4,2.6 and 3.1 pre-installed. (BTW the intention is to use Python for a CGI script.) When my script imports subprocess I get the traceback File "/usr/lib/python2.6/subprocess.py", line 427, in import

Re: git_revision issues with scipy/numpy/matplotlib

2012-07-07 Thread Ousmane Wilane
> "H" == Hans Mulder writes: H> Or you can explicitly type the full path of the python you want. H> Or you can define aliases, for example: H> alias apple_python=/usr/bin/python alias H> macport_python=/opt/local/bin/python H> lfpv=/Library/Frameworks/Python.framework/V

Immediate Hiring a Python /Django in NJ. Main skills should be Python . knowledge of java / c++. More technologies are a plus.

2012-07-07 Thread pavan
Dear Candidate. Hope you are having a great day! We have an opportunity for you . We trust that your knowledge, skills and experience will be among our most valuable assets .Please let us know would you be interested for this job opening. If you are interested in pursuing this opportunity,

Socket code not executing properly in a thread (Windows)

2012-07-07 Thread Andrew D'Angelo
Hi, I've been writing an IRC chatbot that an relay messages it recieves as an SMS. As it stands, I can retrieve and parse SMSs from Google Voice perfectly, and print them to the console. The problem lies in actually posting the message to the IRC channel. Since the SMS checker runs in a thread apar

Re: Which way is best to execute a Python script in Excel?

2012-07-07 Thread Emile van Sebille
On 7/7/2012 2:05 AM Maurizio Spadaccino said... Thanks again Emile, I'll try out some examples. I found this one: http://showmedo.com/videotutorials/video?name=2190050&fromSeriesID=219 quite enlightning. One last doubt is: say the python code gets used by more Excel Users (different pc), can I

Re: git_revision issues with scipy/numpy/matplotlib

2012-07-07 Thread Hans Mulder
On 7/07/12 14:09:56, Ousmane Wilane wrote: >> "H" == Hans Mulder writes: > > H> Or you can explicitly type the full path of the python you want. > > H> Or you can define aliases, for example: > > H> alias apple_python=/usr/bin/python alias > H> macport_python=/opt/local/bin/

Re: select module missing/corrupt

2012-07-07 Thread Emile van Sebille
On 7/7/2012 5:03 AM John Pote said... We are using a virtual web server running some version of Unix. It has Python versions 2.4,2.6 and 3.1 pre-installed. (BTW the intention is to use Python for a CGI script.) When my script imports subprocess I get the traceback File "/usr/lib/python2.6/subpr

Re: why greenlet, gevent or the stackless are needed?

2012-07-07 Thread Damjan
On 07.07.2012 09:09, self.python wrote: (I'm very new to this coroutine part so It's not supposed to attack these modules, just I don't know the differences) atfer version 2.5, python officially support coroutine with yield. and then, why greenlet, gevent, Stackless python are still useful? it

Re: git_revision issues with scipy/numpy/matplotlib

2012-07-07 Thread Stephen Webb
I think the easiest thing to do would be to remove the python.org Python entirely, kill it from the path (which I've already done), and install directly a MacPorts version of Python. Any caveats or warnings about getting rid of the /Library/Frameworks/Python directory? On Jul 7, 2012, at J

Re: Socket code not executing properly in a thread (Windows)

2012-07-07 Thread Thomas Jollans
On 07/08/2012 12:55 PM, Andrew D'Angelo wrote: Please set your clock to the correct date and time. > (If it would help, the > full code can be seen here: http://lickitung.it.cx/exe/bot/bot.py): No, it can't. > def sendPrivateMessage(channel, message):#private message send function > > glob

Re: Socket code not executing properly in a thread (Windows)

2012-07-07 Thread Andrew D'Angelo
"Thomas Jollans" wrote in message news:mailman.1895.1341677582.4697.python-l...@python.org... > On 07/08/2012 12:55 PM, Andrew D'Angelo wrote: > > Please set your clock to the correct date and time. My BIOS battery has died and I haven't gotten a chance to replace it. Made a mistake when setti

something go wrongly

2012-07-07 Thread levi nie
my code: aList=[1,2,3,4,5,6,7,8,9,10] xList=[1,2,3] print "now aList is",aList.extend(xList) output: now aList is None what i want is [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 1, 2, 3] -- http://mail.python.org/mailman/listinfo/python-list

Re: something go wrongly

2012-07-07 Thread Chris Rebert
On Sat, Jul 7, 2012 at 10:23 AM, levi nie wrote: > my code: > > aList=[1,2,3,4,5,6,7,8,9,10] > xList=[1,2,3] > print "now aList is",aList.extend(xList) > > output: > now aList is None > > what i want is [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 1, 2, 3] See http://stackoverflow.com/a/1682601 list.extend(),

Re: something go wrongly

2012-07-07 Thread levi nie
Thanks, Such methods return None to emphasize that they do not create new lists. i got it. 2012/7/8 Chris Rebert > On Sat, Jul 7, 2012 at 10:23 AM, levi nie wrote: > > my code: > > > > aList=[1,2,3,4,5,6,7,8,9,10] > > xList=[1,2,3] > > print "now aList is",aList.extend(xList) > > > > output: > >

RE: PyEval_SetProfile usage ?

2012-07-07 Thread Salman Malik
Thanks Thomas! I will try the timer code that you provided. I have tried profiling with just wrapping the python code with cprofiler's runctx but the problem is that my python code is sort of a packet parser and is called for each packet, but when I see the profiled results it appears that the

Re: Socket code not executing properly in a thread (Windows)

2012-07-07 Thread John Nagle
On 7/8/2012 3:55 AM, Andrew D'Angelo wrote: Hi, I've been writing an IRC chatbot that an relay messages it receives as an SMS. We have no idea what IRC module you're using. As it stands, I can retrieve and parse SMSs from Google Voice perfectly The Google Voice code you have probably

ANN: Celery 3.0 (chiastic slide) released!

2012-07-07 Thread Ask Solem
=== Celery 3.0 (Chiastic Slide) Released! === Celery is a simple, flexible and reliable distributed system to process vast amounts of messages, while providing operations with the tools required to maintain such a sys

Re: ANN: Celery 3.0 (chiastic slide) released!

2012-07-07 Thread Rotwang
On 07/07/2012 19:26, Ask Solem wrote: === Celery 3.0 (Chiastic Slide) Released! === Does this have anything to do with the Autechre album? -- I have made a thing that superficially resembles music: http://soundc

Re: Discussion on some Code Issues

2012-07-07 Thread subhabangalore
On Thursday, July 5, 2012 4:51:46 AM UTC+5:30, (unknown) wrote: > Dear Group, > > I am Sri Subhabrata Banerjee trying to write from Gurgaon, India to discuss > some coding issues. If any one of this learned room can shower some light I > would be helpful enough. > > I got to code a bunch of do

how to compile pygtk in python2.7?

2012-07-07 Thread contro opinion
1.download pygtk 2.cd /home/tiger/pygtk-2.24.0 3.PYTHON=/usr/bin/python2.7 ./configure --prefix=/usr 4. make 5. make install *tiger@ocean:~$ python2.7 Python 2.7.3 (default, Jul 1 2012, 14:13:18) [GCC 4.4.5] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>>

Re: how to compile pygtk in python2.7?

2012-07-07 Thread Benjamin Kaplan
On Sat, Jul 7, 2012 at 9:47 PM, contro opinion wrote: > 1.download pygtk > > 2.cd /home/tiger/pygtk-2.24.0 > > 3.PYTHON=/usr/bin/python2.7 ./configure --prefix=/usr > 4. make > 5. make install > > tiger@ocean:~$ python2.7 > Python 2.7.3 (default, Jul 1 2012, 14:13:18) > [GCC 4.4.5] on linux2 >

Re: Discussion on some Code Issues

2012-07-07 Thread subhabangalore
On Sunday, July 8, 2012 2:21:14 AM UTC+5:30, Dennis Lee Bieber wrote: > On Sat, 7 Jul 2012 12:54:16 -0700 (PDT), subhabangal...@gmail.com > declaimed the following in gmane.comp.python.general: > > > But I am bit intrigued with another question, > > > > suppose I say: > > file_open=open("/pytho

Re: how to compile pygtk in python2.7?

2012-07-07 Thread Chris Angelico
On Sun, Jul 8, 2012 at 2:47 PM, contro opinion wrote: > 3.PYTHON=/usr/bin/python2.7 ./configure --prefix=/usr > 4. make > 5. make install What happened when you typed these commands? Were there failure messages? As Benjamine suggested, do you need to become root to install? ChrisA -- http://ma