Forest wrote:
> The socket.makefile() docs say, "the socket must be in blocking mode." I
> don't see any explanation of why blocking mode is required, and I'm not sure
> whether that means timeout mode is forbidden as well. Can someone clarify
> this?
Looking at the code for the existing _fileob
En Fri, 28 Mar 2008 23:23:01 -0300, <[EMAIL PROTECTED]> escribió:
> On Mar 28, 1:57 pm, "Gabriel Genellina" <[EMAIL PROTECTED]>
> wrote:
>> En Fri, 28 Mar 2008 16:14:07 -0300, <[EMAIL PROTECTED]> escribió:
>>
>> > I am trying to install the twitter python wrapper...I got that
>> > installed just f
Steven D'Aprano wrote:
> On Fri, 28 Mar 2008 22:31:07 -0400, Brad wrote:
>
>> When reading a file into a list that contains windows file paths like
>> this:
>>
>> c:\documents and settings\brad\desktop\added_software\asus\a.txt
>>
>> I get a list that contains paths that look like this:
>>
>> c:\\
On Mar 29, 1:31 pm, Brad <[EMAIL PROTECTED]> wrote:
> When reading a file into a list that contains windows file paths like this:
>
> c:\documents and settings\brad\desktop\added_software\asus\a.txt
Do you mean "reading a file into a list that AS A RESULT
contains ..."? If not, what do you mean?
On Fri, 28 Mar 2008 22:31:07 -0400, Brad wrote:
> When reading a file into a list that contains windows file paths like
> this:
>
> c:\documents and settings\brad\desktop\added_software\asus\a.txt
>
> I get a list that contains paths that look like this:
>
> c:\\documents and settings\\brad\\de
On Mar 29, 12:47 pm, "aeneng" <[EMAIL PROTECTED]> wrote:
> Hello everyone,
>
> I am just starting to use python in numerical cacluation.
> I need you to help me to see what's wrong with the following piece of
> codes, which computes the cross product of two vectors and returns
> the result. u and v
When reading a file into a list that contains windows file paths like this:
c:\documents and settings\brad\desktop\added_software\asus\a.txt
I get a list that contains paths that look like this:
c:\\documents and settings\\brad\\desktop\\added_software\\asus\\a.txt
So, my list contains those fu
On Mar 16, 5:48 pm, Jeff Schwab <[EMAIL PROTECTED]> wrote:
> Unlike Perl or Tcl, Python is not just a
> scripting language with a set of ad-hoc extensions. There are still
> issues, and Python probably will never be a general-purpose replacement
> for system-native language compilers, but it does
On Mar 28, 1:57 pm, "Gabriel Genellina" <[EMAIL PROTECTED]>
wrote:
> En Fri, 28 Mar 2008 16:14:07 -0300, <[EMAIL PROTECTED]> escribió:
>
> > I am trying to install the twitter python wrapper...I got that
> > installed just fine, but am having serious troubles getting the
> > simplejson package to i
Oh, I forgot to mention...
On Sat, 29 Mar 2008 01:47:21 +, aeneng wrote:
> if __name__=="__main__":
...
> print "file name is %s" %__name__
This doesn't do what you expect it to do. You've already established that
__name__ is equal to "__main__", so you might as well change that line
"aeneng" <[EMAIL PROTECTED]> writes:
> I am just starting to use python in numerical cacluation.
Welcome, and congratulations on learning Python.
> I need you to help me to see what's wrong with the following piece
> of codes [...]
Your code is rather difficult to read, since your expressions
Diez B. Roggisch wrote:
> Ron Eggler schrieb:
>> Hi,
>>
>> I would like to get the time of the most recent human activity like a
>> cursor movement or a key hit.
>> Does anyone know how I can get this back to start some action after there
>> has been no activity for X minutes/seconds?
>
> Try ho
On Sat, 29 Mar 2008 01:47:21 +, aeneng wrote:
> Hello everyone,
>
> I am just starting to use python in numerical cacluation. I need you to
> help me to see what's wrong with the following piece of codes, which
> computes the cross product of two vectors and returns the result. u and
> v are
Dear community members,
I just start to use python in numerical calculation. and I encountered some
difficulties when I define my own function.
Here is a piece of codes to compute the cross product of two 3x1 vector.
can any one help me to find what is wrong with it? please see the codes
below.
On Fri, 28 Mar 2008 17:19:04 -0700, Paul Rubin wrote:
> Richard Jones <[EMAIL PROTECTED]> writes:
>> Check out tinypy:
>> http://www.philhassey.com/blog/category/tinypy/
>
> I don't really understand the point of it.
http://www.philhassey.com/blog/tinypy-ideas/
[quote]
Sandbox tinypy
Objectiv
No problem...
your def needs a colon..
def function(params):
yours lacks it =) thats all
On Fri, Mar 28, 2008 at 8:47 PM, aeneng <[EMAIL PROTECTED]> wrote:
> Hello everyone,
>
> I am just starting to use python in numerical cacluation.
> I need you to help me to see what's wrong with the follo
Hello everyone,
I am just starting to use python in numerical cacluation.
I need you to help me to see what's wrong with the following piece of
codes, which computes the cross product of two vectors and returns
the result. u and v are two 3x1 matrix.
when I import the function, error message s
On Mar 28, 10:12 am, "Gabriel Genellina" <[EMAIL PROTECTED]>
wrote:
> En Fri, 28 Mar 2008 12:38:45 -0300, 7stud <[EMAIL PROTECTED]>
> escribió:
>
> > After I start the server script, load the html page in my browser, and
> > click on the link, I get the desired output in my browser, but the
> > s
On Fri, 28 Mar 2008 16:59:59 +0100, Robert Bossy wrote:
> Gabriel Genellina wrote:
>> That's what I said in another paragraph. "sum of coordinates" is using
>> a different distance definition; it's the way you measure distance in a
>> city with square blocks. I don't know if the distance itself ha
I'm pretty new to Python and libraries. I'm actually trying to modify some
code someone else wrote. There are two ways images are saved. One is for the
user to select a "Save as GIF" menu item, or save as tiff, or others. The
other way is that the user wants a collected image from a camera saved
Richard Jones <[EMAIL PROTECTED]> writes:
> Check out tinypy:
> http://www.philhassey.com/blog/category/tinypy/
I don't really understand the point of it.
See also: http://hedgehog.oliotalo.fi/
--
http://mail.python.org/mailman/listinfo/python-list
[EMAIL PROTECTED] wrote:
> I'm making a game where you'll be able to make your own mods and I
> want to be able to write these mods in python.
Check out tinypy:
http://www.philhassey.com/blog/category/tinypy/
Richard
--
http://mail.python.org/mailman/listinfo/python-list
Scott David Daniels wrote:
> class Foo(object): # _Never_ use old-style without a reason
> def __getitem__(self, index):
> print index
> if index < 3:
> return index * 5 # just to see
> raise IndexError('Zapped') # The secret -- run
The socket.makefile() docs say, "the socket must be in blocking mode." I
don't see any explanation of why blocking mode is required, and I'm not sure
whether that means timeout mode is forbidden as well. Can someone clarify
this?
I wanted to use file-like objects with socket timeouts, so I ended
On Mar 28, 12:55 pm, Marc 'BlackJack' Rintsch <[EMAIL PROTECTED]> wrote:
> What about this:
>
> def lstrip2(string, chars, ignore_case=True):
> if ignore_case:
> chars = chars.lower() + chars.upper()
> return string.lstrip(chars)
>
> Ciao,
> Marc 'BlackJack' Rintsch
Thanks
thanks for the responses.
I put the files in an ftp site and all is
well.
jim-on-linux
--
http://mail.python.org/mailman/listinfo/python-list
En Fri, 28 Mar 2008 18:15:04 -0300, harryos <[EMAIL PROTECTED]>
escribió:
> if i were to calculate the euclidean distance in the above example how
> should i go about it..?
> should i replace
> distance = abs(input_wk - weights[image, :])
> with something else?
For a single 2D vector, math.hypo
En Fri, 28 Mar 2008 18:05:29 -0300, afandi <[EMAIL PROTECTED]>
escribió:
> Generally, it involves SQL statement such as
> follow
>
> INSERT INTO (field1,field2,...fieldn) VALUES
> ('abc','def'...)
>
> If I have data taken from Apache Server Log,let say 100 lines which
> is printe
On Fri, 28 Mar 2008 15:48:09 -0700, Kelie wrote:
> Is there such a function included in the standard Python distribution?
AFAIK not.
> This is what I came up with. How to improve it? Thanks.
>
> def lstrip2(s, chars, ingoreCase = True):
> if ingoreCase:
> s2 = s.upper().lstrip(chars
Hello,
Is there such a function included in the standard Python distribution?
This is what I came up with. How to improve it? Thanks.
def lstrip2(s, chars, ingoreCase = True):
if ingoreCase:
s2 = s.upper().lstrip(chars.upper())
return s[len(s)-len(s2):]
else:
retur
En Fri, 28 Mar 2008 17:13:00 -0300, Hans Martin <[EMAIL PROTECTED]>
escribió:
> this is probably a trivial problem, but a google search for "python"
> and "unicode" and" format string" gives too many hits: If I specify
> e.g. "%20s" in a format string and the string value contains UTF-8
> stuff
www.shoeshive.net Wholesale R3 Wholesale R4 Wholesale NZ Wholesale R5
Wholesale Monser Wholesale OZ Wholesale Nike Trainers Wholesale Air
Rift Shoes Air Max 87 Air Max 90 Air Max Ltd Air Max 95 Air Max 97 Air
Max 2003 Air Max 360 at www.shoeshive.net Air Max Tn Nike Air Max 180
Nike Dunk SB Nike Me
En Fri, 28 Mar 2008 16:47:51 -0300, SPJ <[EMAIL PROTECTED]> escribió:
> I am facing a strange problem when I am trying to retrieve multipart
> mail from POP server with attachments.
> The task is to write a script which will retrieve mail with specific
> 'from' field. Get the subject, body and
On 2008-03-28, Paul Rubin wrote:
> [EMAIL PROTECTED] writes:
>> Did everyone take the course on computer architecture?
>
> Yow! Does your SPEED QUEEN have CABLE?
Ya know, I was thinking about trying to find an updated file of
Zippy quotes for use in my .sig, but I decided that having all
of the
En Fri, 28 Mar 2008 16:40:01 -0300, <[EMAIL PROTECTED]> escribió:
> I would like to write a script that would enumerate all running
> processes and return the full path to the EXE of each running
> process. However, I can't seem to find any good info on how to do
> this..any help is greatly appre
[EMAIL PROTECTED] writes:
> Did everyone take the course on computer architecture?
Yow! Does your SPEED QUEEN have CABLE?
--
http://mail.python.org/mailman/listinfo/python-list
[EMAIL PROTECTED] wrote:
> Hello,
>
> I would like to write a script that would enumerate all running
> processes and return the full path to the EXE of each running
> process. However, I can't seem to find any good info on how to do
> this..any help is greatly appreciated. Thanks.
I have this
Sorry,
although the code example was correct,
the question was wrong.
Stef Mientki
Stef Mientki wrote:
> hello,
>
> Passing all kinds of data between objects,
> I'm looking for an elegant (and simple) way to pack the data.
> Now it looks to me that both the class and the inherited list,
> perform
On 2008-03-28, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
> Did everyone take the course on computer architecture?
No.
I personally know dozens of people who didn't.
And I know others who took a course on computer architecture
but not the course on computer architecture.
--
Grant Edwards
llothar wrote:
> Why does Python2.5 do not include the amalgamation source code of
> sqlite3? [...]
First, at the time Python grew the sqlite3 module, there was no
amalgamation yet.
My reasoning:
So that Python doesn't need to release a security release, should a
security bug in SQLite be found.
> the norm from which it is derived is called norm-1, or L1; the usual >
> euclidean distance is derived from norm-2.
> If you only want to see if two things are "close enough", this provides a
> faster measure than the euclidean distance.
thanks Gabriel for the detailed explanation..
if i w
Hi,
Generally, it involves SQL statement such as
follow
INSERT INTO (field1,field2,...fieldn) VALUES
('abc','def'...)
If I have data taken from Apache Server Log,let say 100 lines which
is printed output of 8 fields such
as:
data 1
IP: 61.5.65.101
Date: 26/Sep/2007
Time: 20:43:
I want to regression a signal. It's NN, not necessarily, sine wave.
What kind of numbers of harmonic simultaneous sounds are we looking
at? How close to an A 440 can a human make?
I want recognition to alert me. As a sine wave is coming in:
>>> for t in [ ( 200* sin( x*2 ), 200* cos( x*2 ) ) f
En Fri, 28 Mar 2008 16:14:07 -0300, <[EMAIL PROTECTED]> escribió:
> I am trying to install the twitter python wrapper...I got that
> installed just fine, but am having serious troubles getting the
> simplejson package to install. I need help diagnosing where this is
> failing. I am trying to use
On Fri, 28 Mar 2008 21:13:00 +0100, Hans Martin wrote:
> this is probably a trivial problem, but a google search for "python"
> and "unicode" and" format string" gives too many hits: If I specify
> e.g. "%20s" in a format string and the string value contains UTF-8
> stuff (differing number of byte
W. Watson wrote:
> In what library would I find gif.save(path), where path is the name and path
> of a file, and the method would produce a file in a gif format?
>
> Is there a fits.save(path) somewhere? fits is commonly used in astronomical
> work.
>
You may want to install PIL (the Python
Why does Python2.5 do not include the amalgamation source code of
sqlite3?
At the moment it is not possible to build the system out of the box
with the Visual Studio project.
I don't think this is good. The amalgamation version is exactly for
this purpose.
Is there a 2.5.3 release on the way?
--
Hi,
this is probably a trivial problem, but a google search for "python"
and "unicode" and" format string" gives too many hits: If I specify
e.g. "%20s" in a format string and the string value contains UTF-8
stuff (differing number of bytes per character), the length of the
resulting string (in ch
I am facing a strange problem when I am trying to retrieve multipart mail from
POP server with attachments.
The task is to write a script which will retrieve mail with specific 'from'
field. Get the subject, body and attachments if any and reuse this info to send
mail with different format to ti
Hello,
I would like to write a script that would enumerate all running
processes and return the full path to the EXE of each running
process. However, I can't seem to find any good info on how to do
this..any help is greatly appreciated. Thanks.
T
--
http://mail.python.org/mailman/listinfo/pyt
On Mar 28, 10:15 am, harryos <[EMAIL PROTECTED]> wrote:
> > The code is pretty legible as it is now. Anyway, using min() and a
> > generator:
>
> hi
> is this calculated distance really Euclidean distance? When i checked
> wikipediahttp://en.wikipedia.org/wiki/Euclidean_distance
> it shows a calcul
Gabriel Genellina wrote:
> En Thu, 27 Mar 2008 20:28:27 -0300, Praveena B
> <[EMAIL PROTECTED]> escribió:
>
>> Can anyone help me out??
>
> Still lacking details... PIL has a ImageGrab module, Windows only.
>
For Windows, Alt Prtscn usually copies
the image to a clipboard.
Colin W.
--
http:/
On Mar 17, 1:49 am, "Diez B. Roggisch" <[EMAIL PROTECTED]> wrote:
>
> I doubt that. AFAIK both arrays and lists are continuous memory-areas,
> that double (at least to a certain threshold or so) when reaching the
> capacity limit.
For what it's worth, lists over-allocate by ~1/8, and arrays by ~1/
I am trying to install the twitter python wrapper...I got that
installed just fine, but am having serious troubles getting the
simplejson package to install. I need help diagnosing where this is
failing. I am trying to use:
http://pypi.python.org/pypi/simplejson
and I run "python setup.py build
On Mar 28, 8:41 am, "Gabriel Genellina" <[EMAIL PROTECTED]>
wrote:
> En Fri, 28 Mar 2008 07:14:17 -0300, Simon Brunning
> <[EMAIL PROTECTED]> escribió:
>
> > On Thu, Mar 27, 2008 at 4:13 PM, <[EMAIL PROTECTED]> wrote:
> >> My dynamic code failed at this site http:///, need
> >> some help th
In article <[EMAIL PROTECTED]>,
"Diez B. Roggisch" <[EMAIL PROTECTED]> wrote:
> > systems. (In theory, file input/output should also be available as
> > asynchronous code, but async IO is low-level and not available in
> > Python.) While threads shouldn't be considered a replacement for
>
> I
In what library would I find gif.save(path), where path is the name and path
of a file, and the method would produce a file in a gif format?
Is there a fits.save(path) somewhere? fits is commonly used in astronomical
work.
--
Wayne Watson (Nevada City, CA)
Paul Rubin wrote:
> Andrew McLean <[EMAIL PROTECTED]> writes:
>> I would like to write a web (http) proxy which I can instrument to
>> automatically extract information from certain web sites as I browse
>> them. Specifically, I would want to process URLs that match a
>> particular regexp. For thos
On 27 Mar, 15:19, "Diez B. Roggisch" <[EMAIL PROTECTED]> wrote:
>
[Psyco maintenance and further development]
> Nope, but I heard through the grapevine that while it won't be supported for
> all times to come, a new version is in the making.
>
> But ultimately, the author says that the approach i
>>>
>>> class super_list(list):
>>> pass
>>>
>>> def kwadraat ( value ) :
>>> return value * value
>>>
>>> x={}
>>> x['frequency']=33
>>> x['functie']=kwadraat
>>> print x['functie'](2)
>>>
>>> y = super_list()
>>> y.frequency = 33
>>> y.functie = kwadraat
>>> print y.functie(3)
>>>
>
On 28 Mar, 15:52, [EMAIL PROTECTED] wrote:
> I'm having trouble explaining the benefits and tradeoffs of threads to my
> coworkers and countering their misconceptions about Python's threading model
> and facilities.
Python's threading module is modelled on Java's thread model. There
are some mi
> systems. (In theory, file input/output should also be available as
> asynchronous code, but async IO is low-level and not available in
> Python.) While threads shouldn't be considered a replacement for
I suggest you tell that the twisted-guys. And the ones from the built-in
asyncore-module.
On Mar 28, 1:56 pm, "Gabriel Genellina" <[EMAIL PROTECTED]>
wrote:
> En Fri, 28 Mar 2008 13:22:06 -0300, Clodoaldo <[EMAIL PROTECTED]>
> escribió:
>
>
>
> > On Mar 28, 12:09 pm, "Gabriel Genellina" <[EMAIL PROTECTED]> wrote:
> >> En Fri, 28 Mar 2008 10:54:49 -0300, Clodoaldo
> >> <[EMAIL PROTECTED]
On Mar 28, 10:01 am, Jason Kristoff wrote:
> I'm trying to make something that once it is disconnected will
> automatically try to reconnect. I'll add some more features in later so
> it doesn't hammer the server but right now I just want to keep it simple
> and get that part working. The proble
On 3月27日, 下午7时22分, Tim Golden <[EMAIL PROTECTED]> wrote:
> lialie wrote:
>
> [... snip slightly confused indication that reading back a
> binary item using GetChunk appears to double its length ...]
>
> Well I don't know why this should be happening, but I do at
> least have a few suggestions:
>
>
En Fri, 28 Mar 2008 13:22:06 -0300, Clodoaldo <[EMAIL PROTECTED]>
escribió:
> On Mar 28, 12:09 pm, "Gabriel Genellina" <[EMAIL PROTECTED]> wrote:
>> En Fri, 28 Mar 2008 10:54:49 -0300, Clodoaldo
>> <[EMAIL PROTECTED]> escribió:
>>
>> > What i need to know is where can an equal char appear in a
On 2008-03-28, Laszlo Nagy <[EMAIL PROTECTED]> wrote:
>
>> Yes, that is exactly what it means.
>>
>> >From the recv() man page:
>>
>> RETURN VALUE
>>These calls return the number of bytes received, or -1 if an
>> error
>>occurred. The return value will be 0 when the peer has
[EMAIL PROTECTED] writes:
> I'm having trouble explaining the benefits and tradeoffs of threads
> to my coworkers and countering their misconceptions about Python's
> threading model and facilities. They all come from C++ and are used
> to thinking of multithreading as a way to harness multiple C
En Fri, 28 Mar 2008 13:17:44 -0300, Diez B. Roggisch <[EMAIL PROTECTED]>
escribió:
> [EMAIL PROTECTED] schrieb:
>> I have an extension module that gets initialized multiple
>> times because I am using threads.
>>
>> How can this module access global state (not per-thread state) ?
>> It needs to
> Yes, that is exactly what it means.
>
> >From the recv() man page:
>
> RETURN VALUE
>These calls return the number of bytes received, or -1 if an error
>occurred. The return value will be 0 when the peer has performed an
>orderly shutdown.
>
>
Mea cupla. :-)
W
On 27 Mar 2008 23:49:46 -0700, Paul Rubin
<"http://phr.cx"@nospam.invalid> wrote:
> "Michaâ Janeczek" <[EMAIL PROTECTED]> writes:
> > However, the type of embedding that I imagined would be mostly
> > pure functions, since Python can deal with IO rather well. It'd also
> > be applicable in situa
On Mar 28, 12:09 pm, "Gabriel Genellina" <[EMAIL PROTECTED]>
wrote:
> En Fri, 28 Mar 2008 10:54:49 -0300, Clodoaldo <[EMAIL PROTECTED]>
> escribió:
>
>
>
> > I'm using a md5 hash encoded with base64.urlsafe_b64encode as a
> > parameter of a URL used to confirm a registration in a site. It has
> > b
[EMAIL PROTECTED] schrieb:
> I have an extension module that gets initialized multiple
> times because I am using threads.
>
> How can this module access global state (not per-thread state) ?
> It needs to create a singleton.
The question is very unclear.
If you are after *not* initializing your
On 2008-03-28, Laszlo Nagy <[EMAIL PROTECTED]> wrote:
>> while (1):
>> buffer = sock.recv(1024)
>> if not buffer:
>> dodiscon()
>>
>
> sock.recv(1024) can return zero bytes of data indicating that no data
> arrived yet.
No, it can't.
> It does not mean that you have been d
thanks Gabriel,
Gabriel Genellina wrote:
> En Fri, 28 Mar 2008 12:15:45 -0300, Stef Mientki <[EMAIL PROTECTED]>
> escribió:
>
>
>> Passing all kinds of data between objects,
>> I'm looking for an elegant (and simple) way to pack the data.
>> Now it looks to me that both the class and the inhe
En Fri, 28 Mar 2008 12:38:45 -0300, 7stud <[EMAIL PROTECTED]>
escribió:
> After I start the server script, load the html page in my browser, and
> click on the link, I get the desired output in my browser, but the
> server script outputs the following in my terminal:
>
> localhost - - [28/Mar/20
En Fri, 28 Mar 2008 12:25:55 -0300, <[EMAIL PROTECTED]> escribió:
> On Mar 28, 11:14 am, "Gabriel Genellina" <[EMAIL PROTECTED]>
> wrote:
>> En Fri, 28 Mar 2008 11:51:10 -0300, <[EMAIL PROTECTED]> escribió:
>>
>> > How can this module access global state (not per-thread state) ?
>> > It needs to c
Gabriel Genellina wrote:
> That's what I said in another paragraph. "sum of coordinates" is using a
> different distance definition; it's the way you measure distance in a city
> with square blocks. I don't know if the distance itself has a name, but
I think it is called Manhattan distance in
En Fri, 28 Mar 2008 12:15:48 -0300, harryos <[EMAIL PROTECTED]>
escribió:
>> The code is pretty legible as it is now. Anyway, using min() and a
>> generator:
>>
>>
>
> hi
> is this calculated distance really Euclidean distance? When i checked
> wikipedia http://en.wikipedia.org/wiki/Euclidean_di
On Friday 28 March 2008, Constantly Distracted wrote:
> I've just started PyQt programming and I've run into this little
> problem. When I set the text of one cell in my table, all the other
> cells fill with that value.
...because you have only created a single QTableWidgetItem instance, rather
In article <[EMAIL PROTECTED]>,
<[EMAIL PROTECTED]> wrote:
>
>I'm having trouble explaining the benefits and tradeoffs of threads to my
>coworkers and countering their misconceptions about Python's threading model
>and facilities. They all come from C++ and are used to thinking of
>multithreading
On Mar 28, 11:14 am, "Gabriel Genellina" <[EMAIL PROTECTED]>
wrote:
> C global variables are global, not per-thread.
aha, a static pointer gets initialized to NULL, so I
can check if it's not NULL in the module initializer.
Thanks for jogging my brain,
Simon.
>
> --
> Gabriel Genellina
--
ht
1) I have this simple cgi server:
import CGIHTTPServer
import BaseHTTPServer
class MyRequestHandler(CGIHTTPServer.CGIHTTPRequestHandler):
cgi_directories = ['/my_cgi_scripts']
server = BaseHTTPServer.HTTPServer(
('', 8111),
MyRequestHandler
)
server.serve_forever()
2) I
Is there a Python module comparable in functionality to the PEAR
Cache_Lite package for PHP?
I've been doing some Googling to little avail. I'm experimenting with
Python CGI to learn various techniques at a low level and I'm adapting a
model that uses PHP.
Any info about application-level cac
En Fri, 28 Mar 2008 12:15:45 -0300, Stef Mientki <[EMAIL PROTECTED]>
escribió:
> Passing all kinds of data between objects,
> I'm looking for an elegant (and simple) way to pack the data.
> Now it looks to me that both the class and the inherited list,
> performs equally well.
> Till now, the mo
On Mar 28, 11:14 am, "Gabriel Genellina" <[EMAIL PROTECTED]>
wrote:
> En Fri, 28 Mar 2008 11:51:10 -0300, <[EMAIL PROTECTED]> escribió:
>
> > I have an extension module that gets initialized multiple
> > times because I am using threads.
>
> And do you want thread local variables?
no
>
> > How ca
En Fri, 28 Mar 2008 12:01:01 -0300, Constantly Distracted
<[EMAIL PROTECTED]> escribió:
> I've just started PyQt programming and I've run into this little
> problem. When I set the text of one cell in my table, all the other
> cells fill with that value.
> def filltable(self):
> ite
> The code is pretty legible as it is now. Anyway, using min() and a
> generator:
>
>
hi
is this calculated distance really Euclidean distance? When i checked
wikipedia http://en.wikipedia.org/wiki/Euclidean_distance
it shows a calculation involving sum of squares of the differences of
elements.He
I am trying separate a script that users pexpect into
various functions within the same expect session. The
problem is that the function does not return control
back Main. Any insight into this issue would be
greatly appreciated. Below is sample code of the
problem.
Thanks,
Paul
impor
En Fri, 28 Mar 2008 11:51:10 -0300, <[EMAIL PROTECTED]> escribió:
> I have an extension module that gets initialized multiple
> times because I am using threads.
And do you want thread local variables?
> How can this module access global state (not per-thread state) ?
> It needs to create a sing
hello,
Passing all kinds of data between objects,
I'm looking for an elegant (and simple) way to pack the data.
Now it looks to me that both the class and the inherited list,
performs equally well.
Till now, the most elegant way (in my view) is the list inheritance,
mainly because you don't need b
Leo 4.4.8 beta 3 is available at:
http://sourceforge.net/project/showfiles.php?group_id=3458&package_id=29106
This version features a new ipython plugin that provides a two-way bridge
between Leo and IPython. See
http://webpages.charter.net/edreamleo/IPythonBridge.html
Leo is a text editor, dat
En Fri, 28 Mar 2008 10:54:49 -0300, Clodoaldo <[EMAIL PROTECTED]>
escribió:
> I'm using a md5 hash encoded with base64.urlsafe_b64encode as a
> parameter of a URL used to confirm a registration in a site. It has
> been working great.
>
> The url is like this:
>
> http://example.com/ce?i=878&h=kT
I've just started PyQt programming and I've run into this little
problem. When I set the text of one cell in my table, all the other
cells fill with that value.
All I wanted to do was run a loop, printing in each cell the row and
column number.
Here's the code.
--
fro
> This is what I've got right now:
>
> #! /usr/bin/env python
> import socket, string
> sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
> def doconn():
> sock.connect(("localhost", 1234))
> def dodiscon():
> sock.close()
> doconn()
>
> doconn()
>
> while (1):
> buffer
> "Peter" == Peter Otten <[EMAIL PROTECTED]> writes:
Peter> [EMAIL PROTECTED] wrote:
[snip]
>> ...can someone explain why invoking a.py prints 0?
>> I would have thought that the global variable 'g' of module 'a' would
>> be set to 1...
Peter> When you run a.py as a script it is put into the s
Did you try just creating a new socket every time you do a connect ?
On Mar 28, 10:01 am, Jason Kristoff wrote:
> I'm trying to make something that once it is disconnected will
> automatically try to reconnect. I'll add some more features in later so
> it doesn't hammer the server but right now
I have an extension module that gets initialized multiple
times because I am using threads.
How can this module access global state (not per-thread state) ?
It needs to create a singleton.
Simon.
--
http://mail.python.org/mailman/listinfo/python-list
That clears it up. Thanks.
--
http://mail.python.org/mailman/listinfo/python-list
I'm having trouble explaining the benefits and tradeoffs of threads to my
coworkers and countering their misconceptions about Python's threading model
and facilities. They all come from C++ and are used to thinking of
multithreading as a way to harness multiple CPU cores for compute-bound
processi
1 - 100 of 132 matches
Mail list logo