Re: HOST - dreamhost.com / Liberality (Hosting, Basic Requirement)

2006-06-08 Thread J�rgen Exner
Ilias Lazaridis wrote: > crossposted to 5 groups, which are affected by this case. > [some random ramblings about a troll being silenced for the moment] And your article has exactly what relationship to Perl? *PLONK* jue -- http://mail.python.org/mailman/listinfo/python-list

Re: Extended zip() for lists

2006-06-08 Thread Florian Reiser
Hello Gene, a big THANKS for this tip. This is exactly what I was looking for. Regards Florian Reiser "gene tani" <[EMAIL PROTECTED]> schrieb im Newsbeitrag news:[EMAIL PROTECTED] > > Florian Reiser wrote: >> Hello, >> >> I have 4 lists: a, b, c and d >> Out of this 4 lists I want to build a t

Re: Writing to a certain line?

2006-06-08 Thread John Savage
"Tommy B" <[EMAIL PROTECTED]> writes: >I was wondering if there was a way to take a txt file and, while >keeping most of it, replace only one line. See, I'd have a file like: .. >Is there any easy way to do this? An easy way? If you know how many bytes in from the start of the file your desired

Re: Allowing zero-dimensional subscripts

2006-06-08 Thread spam . noam
Hello, Terry Reedy wrote: > So I do not see any point or usefulness in saying that a tuple subcript is > not what it is. I know that a tuple is *constructed*. The question is, is this, conceptually, the feature that allows you to ommit the parentheses of a tuple in some cases. If we see this as t

Re: XML, JSON, or what?

2006-06-08 Thread Frank Millman
Frank Millman wrote: > Hi all > > I am writing a multi-user accounting/business application, which uses > sockets to communicate between server and client. The server contains > all the business logic. It has no direct knowledge of the client. I > have devised a simple message format to exchange i

Re: How to extract 2 integers from a string in python?

2006-06-08 Thread Klaus Alexander Seistrup
[EMAIL PROTECTED] skrev: > how can I extract 2 integers from a string in python? > > for example, my source string is this: > Total size: 173233 (371587) > > I want to extract the integer 173233 and 371587 from that > soource string, how can I do that? E.g.: #v+ >>> import re >>> re.findall(r'

Re: How to extract 2 integers from a string in python?

2006-06-08 Thread Stephen Prinster
[EMAIL PROTECTED] wrote: > Hi, > > how can I extract 2 integers from a string in python? > > for example, my source string is this: > Total size: 173233 (371587) > > I want to extract the integer 173233 and 371587 from that soource > string, how can I do that? > Use split() to split the string

What is Expressiveness in a Computer Language

2006-06-08 Thread Xah Lee
in March, i posted a essay “What is Expressiveness in a Computer Language”, archived at: http://xahlee.org/perl-python/what_is_expresiveness.html I was informed then that there is a academic paper written on this subject. On the Expressive Power of Programming Languages, by Matthias Felleisen, 19

Re: The Nature of the “Unix Philosophy”

2006-06-08 Thread William Ahern
On Thu, 08 Jun 2006 13:41:13 +, Richard Bos wrote: > Frank Silvermann <[EMAIL PROTECTED]> wrote: > >> Nils O. Selåsdal wrote: >> > Xah Lee wrote: >> >> The Nature of the “Unix Philosophy” >> >> > Perhaps you should take a peek at the ideas in Plan 9 from Bell Labs, >> > which is a cont

How to extract 2 integers from a string in python?

2006-06-08 Thread yinglcs
Hi, how can I extract 2 integers from a string in python? for example, my source string is this: Total size: 173233 (371587) I want to extract the integer 173233 and 371587 from that soource string, how can I do that? -- http://mail.python.org/mailman/listinfo/python-list

Re: what does %u mean?

2006-06-08 Thread scruffy . mogwai
Someone beat me to the reply -- and their explanation sounds a lot better than mine! i guess you learn something new everyday... [EMAIL PROTECTED] wrote: > I'm not sure, but I think it has something to do with unicode. > print "%i" % 1 // Prints the integer 1 as a string. > print "%u" % (-5) //

Re: what does %u mean?

2006-06-08 Thread scruffy . mogwai
I'm not sure, but I think it has something to do with unicode. print "%i" % 1 // Prints the integer 1 as a string. print "%u" % (-5) // Prints -5 as a unicode string??? yaru22 wrote: > Hi. I just started learning python. > > In the exercise in my book, it asks me to try print "%u" % (-5) > > I'm

Re: what does %u mean?

2006-06-08 Thread K.S.Sreeram
yaru22 wrote: > In the exercise in my book, it asks me to try print "%u" % (-5) > I'm wondering what this %u mean? Looks like there is *no* difference between '%u' and '%d' in Python. Python 2.4.3 source code: from stringobject.c, formatint function if (x < 0 && type == 'u') {

Re: what does %u mean?

2006-06-08 Thread K.S.Sreeram
See: http://docs.python.org/lib/typesseq-strings.html u -> Unsigned decimal signature.asc Description: OpenPGP digital signature -- http://mail.python.org/mailman/listinfo/python-list

what does %u mean?

2006-06-08 Thread yaru22
Hi. I just started learning python. In the exercise in my book, it asks me to try print "%u" % (-5) I'm wondering what this %u mean? Thank you. Regards, Brian. -- http://mail.python.org/mailman/listinfo/python-list

Re: capture video from camera

2006-06-08 Thread K.S.Sreeram
dan wrote: > I hope you won't be deterred from posting further questions to the > group by Fredrik's somewhat terse and unfriendly reply. > > comp.lang.python is a forum generally noted for its pleasing admixture > of erudition and encouragement. Fredrik is uncommonly distinguished in > the scope

Re: dynamic inheritance

2006-06-08 Thread Dan Sommers
On Thu, 08 Jun 2006 21:14:48 -0400, alf <[EMAIL PROTECTED]> wrote: > is there any way to tell the class the base class during runtime? >>> class A(object): >>> pass >>> class B(object): >>> pass >>> o = A() >>> o.__class__ >>> o.__class__ = B >>> o.__c

Re: Exeucte a system command in python script

2006-06-08 Thread ken . carlino
I am using python 2.4, so I don' t need to insteall that module separately. [EMAIL PROTECTED] wrote: > Thanks I get this error 'NameError: global name 'call' is not defined" > > I already import 'subprocess'. > > Can you pleaes tell me what am I missing? > > Robert Kern wrote: > > [EMAIL PROTECTED

Re: Exeucte a system command in python script

2006-06-08 Thread Robert Kern
[EMAIL PROTECTED] wrote: > Thanks I get this error 'NameError: global name 'call' is not defined" > > I already import 'subprocess'. > > Can you pleaes tell me what am I missing? Almost certainly you are doing something like this: import subprocess call(['something', 'or', 'other']) You ne

Re: Exeucte a system command in python script

2006-06-08 Thread ken . carlino
Thanks I get this error 'NameError: global name 'call' is not defined" I already import 'subprocess'. Can you pleaes tell me what am I missing? Robert Kern wrote: > [EMAIL PROTECTED] wrote: > > Hi, > > > > I would like to execute a shell command like this in python: > > cmd = 'ant release -Dbuil

Re: Allowing zero-dimensional subscripts

2006-06-08 Thread Terry Reedy
<[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Terry Reedy wrote: >> > In a few more words: Currently, an object can be subscripted by a few >> > elements, separated by commas. It is evaluated as if the object was >> > subscripted by a tuple containing those elements. >> >> It is n

dynamic inheritance

2006-06-08 Thread alf
is there any way to tell the class the base class during runtime? a. -- http://mail.python.org/mailman/listinfo/python-list

UltraEdit and Python

2006-06-08 Thread gregory diaczok
How do I sent up Ultra Edit to work w/ Python? How do I get Ultra Edit to run a Python script currently in the edit window and supply results? I can't figure out how to get Ultra Edit to invoke the Python debugger to allow stepping through a Python script and view each line reults? How do I se

Tktable question?

2006-06-08 Thread jerry . levan
Hi, I am using a Tktable in my python database browser program to hold the results of a query. I have declared an ArrayVar like (IntVar) to hold the table contents. In Tcl/Tk programs I have observed that the associated table variable does *not* get "smaller" as various results are displayed in t

Re: Exeucte a system command in python script

2006-06-08 Thread Robert Kern
[EMAIL PROTECTED] wrote: > Hi, > > I would like to execute a shell command like this in python: > cmd = 'ant release -Dbuild=build_proxyonly -Drev=5.1.130f > -Dprops=\"-MIDP20_LARGE;PUSH_FEATURE=false;MIDlet-Version=5.0;version=5.0;MIDlet-Icon=midicon15x15.png;-FOUR_WAY_NAV_FEATURE\" > -DThree_Bra

Exeucte a system command in python script

2006-06-08 Thread ken . carlino
Hi, I would like to execute a shell command like this in python: cmd = 'ant release -Dbuild=build_proxyonly -Drev=5.1.130f -Dprops=\"-MIDP20_LARGE;PUSH_FEATURE=false;MIDlet-Version=5.0;version=5.0;MIDlet-Icon=midicon15x15.png;-FOUR_WAY_NAV_FEATURE\" -DThree_Branding=true' Which of the execl comma

Re: Win XP: Problem with shell scripting in Python

2006-06-08 Thread John Machin
On 9/06/2006 10:47 AM, John Machin wrote: > Now it's *your* turn to do something for the cause. It appears to me > that popen4 has exactly the same documentation as popen3, as recently as > 2.5a2. I see no fourth gizmoid here. > > Whoooaaah! "4" is not a gizmoid count: > > |>>> handles = os.po

Re: How to generate k+1 length strings from a list of k lengthstrings?

2006-06-08 Thread Girish Sahani
Yes it is the former of course.Common elements could be in any order in both strings. Thanks Marc :)...though we need to add an if for checking the length of the string (k+1). > > Jon Clements wrote: >> Are you asking the question, "Which pairs of strings have one character >> different in each?",

Re: Win XP: Problem with shell scripting in Python

2006-06-08 Thread John Machin
On 9/06/2006 8:58 AM, A.M wrote: > Hi, > I am having difficulty with shell scripting in Python. > I use the following command to run a DOS command and put the return value in > a Python variable: > print os.popen('DIR').read() > It works very fine with DIR command, but for commands like "MD :" it

Re: Importing again and again

2006-06-08 Thread Schüle Daniel
it's import-ed only once # magic.py file #!/usr/bin/python print "here" import magic# try to import itself then try # bad_magic.py #!/usr/bin/python print "here" import bad_magic reload(bad_magic) hth, Daniel -- http://mail.python.org/mailman/listinfo/python-list

Python Class for Apache log analysis

2006-06-08 Thread And80
Hi all, I am looking for a python package that I could employ to analyze Apache's log files in real time. Of course I already have found some scripts, but most of them are outdated (python1.5), while others are simply impossible to use for a custom application. I was looking for something reliable,

Re: what are you using python language for?

2006-06-08 Thread baalbek
To score with the chicks! A Python script roams the nightclubs for beautiful women, finds an appropriate woman based on my preferances, charms her with its sleek Pythonic manners, calls for a cab and brings the lady to my recidency. Works like a charm! Baalbek -- http://mail.python.org/mailma

Re: ValueError: too many values to unpack

2006-06-08 Thread k . retheesh
Thank you, that solved my problem. Thanks Retheesh alisonken1 wrote: > [EMAIL PROTECTED] wrote: > > > 56 records were different > > Type, FileType, > >Item, > > Hash, > > > > Path, Size, CullCd, Ext, DtCr,

better Python IDE? Mimics Maya's script editor?

2006-06-08 Thread warpcat
I've been scripting in Maya, via mel for years now. Recently learning to Python, love it. Thing that's driving me nuts it the IDE. I'm using PythonWin right now and trying to find something better, mainly with this functionality: In Maya's mel script editor window, it's split into two sections.

Win XP: Problem with shell scripting in Python

2006-06-08 Thread A.M
Hi, I am having difficulty with shell scripting in Python. I use the following command to run a DOS command and put the return value in a Python variable: print os.popen('DIR').read() It works very fine with DIR command, but for commands like "MD :" it doesn't return the error message

Re: ValueError: too many values to unpack

2006-06-08 Thread alisonken1
[EMAIL PROTECTED] wrote: > 56 records were different > Type, FileType, >Item, > Hash, > > Path, Size, CullCd, Ext, DtCr, > DtLMd, DtLAc > Traceback (most recent call last

Re: Allowing zero-dimensional subscripts

2006-06-08 Thread spam . noam
Hello, Terry Reedy wrote: > > In a few more words: Currently, an object can be subscripted by a few > > elements, separated by commas. It is evaluated as if the object was > > subscripted by a tuple containing those elements. > > It is not 'as if'. 'a,b' *is* a tuple and the object *is* subcript

Re: Importing again and again

2006-06-08 Thread John Bokma
"Terry Reedy" <[EMAIL PROTECTED]> wrote: > > "John Bokma" <[EMAIL PROTECTED]> wrote in message > news:[EMAIL PROTECTED] >>> def foo(): >>> import bar >>> bar.printStuff() >> I am new to Python so this might be a weird question, but it there a >> reason why you import bar inside foo? > >

Re: Allowing zero-dimensional subscripts

2006-06-08 Thread Terry Reedy
<[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Hello, > > I discovered that I needed a small change to the Python grammar. I > would like to hear what you think about it. > > In two lines: > Currently, the expression "x[]" is a syntax error. > I suggest that it will be evaluated li

TKinter

2006-06-08 Thread V Sivakumar
Dear Group!, I am new to Python. I have Eclipse with Python support , is there better IDE for free and with good support for GUI development. I need to develop a nice looking desktop application. Like we could do in VB, C# and Java Swing. Is there a drag drop support GUI toolkit for Python

TKinter

2006-06-08 Thread V Sivakumar
Dear Group!, I am new to Python. I have Eclipse with Python support , is there better IDE for free and with good support for GUI development. I need to develop a nice looking desktop application. Like we could do in VB, C# and Java Swing. Is there a drag drop support GUI toolkit for Python

Re: Large Dictionaries

2006-06-08 Thread Tim Peters
[Tim Peters] >> ... >> O(N log N) sorting algorithms helped by pre-existing order are >> uncommon, unless they do extra work to detect and exploit >> pre-existing order. [Lawrence D'Oliveiro] > Shellsort works well with nearly-sorted data. It's basically a smarter > version of bubblesort with much

Re: Large Dictionaries

2006-06-08 Thread Lawrence D'Oliveiro
In article <[EMAIL PROTECTED]>, "Iain King" <[EMAIL PROTECTED]> wrote: >Lawrence D'Oliveiro wrote: >> In article <[EMAIL PROTECTED]>, >> Scott David Daniels <[EMAIL PROTECTED]> wrote: >> >> >For example, time timsort (Python's internal sort) on pre-sorted >> >data; you'll find it is handled fast

Re: Large Dictionaries

2006-06-08 Thread Lawrence D'Oliveiro
In article <[EMAIL PROTECTED]>, "Tim Peters" <[EMAIL PROTECTED]> wrote: >For example, the O(N log N) heapsort is unreasonable compared to the >O(N**2) bubblesort by that reasoning (pre-sorted is actually a bad >case for heapsort, but a good case for bubblesort)? O(N log N) >sorting algorithms he

Re: capture video from camera

2006-06-08 Thread dan
aljosa wrote: > i had no intention to say that videocapture is bad but it's not what > i'm looking for. > concerning docs, everybody has their own view on how docs should look > like. > > that said, i should have written more clearly what i'm looking for. Hi aljosa, I hope you won't be deterred f

ValueError: too many values to unpack

2006-06-08 Thread k . retheesh
Hi, I am very new to pyton, during my adventures journey I got the following error message which am not able to solve, can somebody help me. I was trying to format my output in a readable way, Compare results in tblItem _

Re: what is often before a pattern ?

2006-06-08 Thread James Stroud
[EMAIL PROTECTED] wrote: > Hello, > > i'm looking for a way to detect sequence objects which are often before > a pattern. > > say for example some list like: > > a = "a0 a1 a2 a3 a4 myPatternMatchHere".split() > b = "a5 a2 a4 myPatternMatchHere".split() > c = "a6 a7 a2 a3 a8 a4 myPatternMatchHe

Re: Importing again and again

2006-06-08 Thread Terry Reedy
"John Bokma" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] >> def foo(): >> import bar >> bar.printStuff() > I am new to Python so this might be a weird question, but it there a > reason why you import bar inside foo? Two possible reasons: 1) delay import until actually nee

what is often before a pattern ?

2006-06-08 Thread joh12005
Hello, i'm looking for a way to detect sequence objects which are often before a pattern. say for example some list like: a = "a0 a1 a2 a3 a4 myPatternMatchHere".split() b = "a5 a2 a4 myPatternMatchHere".split() c = "a6 a7 a2 a3 a8 a4 myPatternMatchHere".split() d = "a9 a10 a2 myPatternMatchHere

Re: Importing again and again

2006-06-08 Thread John Bokma
"abcd" <[EMAIL PROTECTED]> wrote: > If I have code which imports a module over and over again...say each > time a function is called, does that cause Python to actually re-import > it...or will it skip it once the module has been imported?? > > for example: > > def foo(): > import bar >

Allowing zero-dimensional subscripts

2006-06-08 Thread spam . noam
Hello, I discovered that I needed a small change to the Python grammar. I would like to hear what you think about it. In two lines: Currently, the expression "x[]" is a syntax error. I suggest that it will be evaluated like "x[()]", just as "x[a, b]" is evaluated like "x[(a, b)]" right now. In a

Re: How to generate k+1 length strings from a list of k length strings?

2006-06-08 Thread bearophileHUGS
Boris Borcic: > I challenge you to write simpler code to do the equivalent. I don't do challenges. I too have written the code to solve that problem, it wasn't much different from your one (it uses a generator function xpairs, to yeild a scan of the different pairs, about half the square, it uses

Re: Importing again and again

2006-06-08 Thread Laszlo Nagy
abcd írta: > If I have code which imports a module over and over again...say each > time a function is called, does that cause Python to actually re-import > it...or will it skip it once the module has been imported?? > > for example: > > def foo(): > import bar > bar.printStuff() > > foo()

Re: Importing again and again

2006-06-08 Thread John Salerno
abcd wrote: > def foo(): > import bar > bar.printStuff() > > foo() > foo() > foo() > foo() > > ...will that re-import bar 4 times...or just import it once? is this a > big performance hit? > > thanks > Given a file called bar.py with the following contents: print "I'm being imported

Re: Importing again and again

2006-06-08 Thread Dustan
abcd wrote: > If I have code which imports a module over and over again...say each > time a function is called, does that cause Python to actually re-import > it...or will it skip it once the module has been imported?? > > for example: > > def foo(): > import bar > bar.printStuff() > > foo

Importing again and again

2006-06-08 Thread abcd
If I have code which imports a module over and over again...say each time a function is called, does that cause Python to actually re-import it...or will it skip it once the module has been imported?? for example: def foo(): import bar bar.printStuff() foo() foo() foo() foo() ...will th

Re: Win XP Error: There is not enough space on the disk

2006-06-08 Thread Fredrik Lundh
A.M wrote: > Is there any way that I can fix this problem? unlikely, unless you work for the OS development team at Microsoft: http://python.org/sf/1463104 (see the comments for more details, including workarounds) -- http://mail.python.org/mailman/listinfo/python-list

Re: follow-up to FieldStorage

2006-06-08 Thread Fredrik Lundh
bruno at modulix wrote: > FWIW, reading the source is not even needed to know this: import cgi dir(cgi.FieldStorage) not to mention: >>> help(cgi.FieldStorage) Help on class FieldStorage in module cgi: class FieldStorage | Store a sequence of fields, reading multipart/form-data.

Re: follow-up to FieldStorage

2006-06-08 Thread John Salerno
Gerard Flanagan wrote: > John Salerno wrote: >> Bruno Desthuilliers wrote: >>> John Salerno a écrit : If I want to get all the values that are entered into an HTML form and write them to a file, is there some way to handle them all at the same time, or must FieldStorage be indexed by

Re: wxpython: can't even create a Panel

2006-06-08 Thread John Salerno
Tim Chase wrote: > It looks like a subtle difference between > > panel = wx.Panel(self) > > and > > panel = wx.Panel(self) Ack! Thanks guys! What's funny is that at first I even had it beneath the __init__ method, but then I unindented because it looked wrong for some reason! :P

Win XP Error: There is not enough space on the disk

2006-06-08 Thread A.M
Hi, I am using ActivePython 2.4.on windows XP I created test.py that contains the following simple script: import os os.system("dir *.py") When I run the script, it works fine. But, when I run the following command on windows XP: Test.py > file.txt I receive this error: "The

Re: wxpython: can't even create a Panel

2006-06-08 Thread Tim Chase
> def __init__(self, parent, title): > wx.Frame.__init__(self, parent, -1, title) > > panel = wx.Panel(self) It looks like a subtle difference between panel = wx.Panel(self) and panel = wx.Panel(self) As the error message states, there is no "self"

Re: follow-up to FieldStorage

2006-06-08 Thread Gerard Flanagan
John Salerno wrote: > Bruno Desthuilliers wrote: > > John Salerno a écrit : > >> If I want to get all the values that are entered into an HTML form and > >> write them to a file, is there some way to handle them all at the same > >> time, or must FieldStorage be indexed by each specific field name?

Re: wxpython: can't even create a Panel

2006-06-08 Thread Fredrik Lundh
John Salerno wrote: > I'm using the sample code of the file 'simple.py' and trying to make a > single window with a panel in it, but I keep getting an error. Here's my > code: (I know I might need something else, like a Show() method for the > panel, but the error stops on the first panel line

wxpython: can't even create a Panel

2006-06-08 Thread John Salerno
I'm using the sample code of the file 'simple.py' and trying to make a single window with a panel in it, but I keep getting an error. Here's my code: (I know I might need something else, like a Show() method for the panel, but the error stops on the first panel line anyway. I've tried a Layout(

Re: CONSTRUCT - Python's way of Ruby's "alias_method"

2006-06-08 Thread Slawomir Nowaczyk
On Thu, 08 Jun 2006 15:28:39 +0300 Ilias Lazaridis <[EMAIL PROTECTED]> wrote: #> *IMPORT* #> #> I would like to know, if this construct is valid, or if it can #> result in problems (that I do not see as a newcomer): The intricacies of import are far beyond me, but FWIW I do not see anything wron

Re: CONSTRUCT - Python's way of Ruby's "alias_method"

2006-06-08 Thread Slawomir Nowaczyk
On Thu, 08 Jun 2006 06:05:35 -0700 "Tim N. van der Leeuw" <[EMAIL PROTECTED]> wrote: #> Since your question is so much about Django, you might want to ask #> on Django groups. Now *that*, and the rest of your post, was uncalled for. This thread is perfectly on topic for this list and the questio

Re: Select hangs after some reads

2006-06-08 Thread Donn Cave
In article <[EMAIL PROTECTED]>, Steve Holden <[EMAIL PROTECTED]> wrote: > The PSH flag indicates that the data stream must be flushed right > through to the other end. This is essential for interactive protocols > such as FTP: without it the server has no way to know that the client > has sent

Re: Select hangs after some reads

2006-06-08 Thread Jon Ribbens
In article <[EMAIL PROTECTED]>, Steve Holden wrote: >> I don't think that's right. You are confusing the PSH flag (which is >> basically unused in Unix networking I think) and the URG flag (which >> is extremely rarely used, but is indeed used by FTP to get abort >> requests to 'jump the queue' as

Re: Newbie question about updating multiple objects ...

2006-06-08 Thread Scott David Daniels
[EMAIL PROTECTED] wrote: > > Any ideas? I've run out of options. Any help would be very *gratefully* > appreciatedd!! Your time-step is too small. Simply try: dt = .5, and you should see (slow) motion. Note, I'd update the position, then wrap it, rather than wrapping and then updating. -- --Sc

Re: Request new feature suggestions for my PDF conversion toolkit - xtopdf

2006-06-08 Thread David Isaac
"vasudevram" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > http://sourceforge.net/projects/xtopdf Serendipity: I was just looking for this functionality. Thanks! So here is an idea for a great enhancement: rst -> PDF The good news: the project is all Python, so you will only have

Re: Instead of saving text files i need as html

2006-06-08 Thread Tim Chase
> Is this what you mean? > > -begin- > import urllib > urlfile = open(r'c:\temp\url.txt', 'r') > for lines in urlfile: > try: > outfilename = lines.replace('/', '-') > urllib.urlretrieve(lines.strip('/n'), 'c:\\temp\\' \ > + outfilename.strip('\n')[7:] + '.html'

Re: wxpython: where is the demo?

2006-06-08 Thread John Salerno
vasudevram wrote: > Its a separate download. Thanks guys, I completely forgot it was separate! :) -- http://mail.python.org/mailman/listinfo/python-list

Re: Select hangs after some reads

2006-06-08 Thread Steve Holden
Jon Ribbens wrote: > In article <[EMAIL PROTECTED]>, Steve Holden wrote: > >>Of course, if the client forces the TCP PSH flag true then the receiver >>is guaranteed to debuffer the stream up to that point - this is how FTP >>clients work, for example. > > > I don't think that's right. You are

Re: wxpython: where is the demo?

2006-06-08 Thread vasudevram
John Salerno wrote: > I just realized that after installing wxPython, it did not add the usual > menu item to my Start menu (Windows), where I can access the docs and > demo. I searched through the wxPython folder in the site-packages > directory, but I can't seem to find it. > > Anyone know how I

Re: tracking dependencies

2006-06-08 Thread Dennis Benzinger
Michele Simionato wrote: > I have a big framework (not written by me) with lots of internal > dependencies and I am > looking for a tool to see the dependency tree. I.e. given a module x, > it should show me all the modules imported by x, and the modules > imported > by them recursively. Standard l

Re: CONSTRUCT - Python's way of Ruby's "alias_method"

2006-06-08 Thread Ilias Lazaridis
Duncan Booth wrote: > Ilias Lazaridis wrote: > >> I would like to know, if this construct is valid, or if it can result in >> problems (that I do not see as a newcomer): >> >> 1082try: >> 1083from django.rework.evolve import evolvedb >> 1084except ImportError: >>

Re: How to generate k+1 length strings from a list of k length strings?

2006-06-08 Thread Boris Borcic
[EMAIL PROTECTED] wrote: > Boris Borcic: >> I'd favor the following, that I find most readable >> sets = map(set,list_of_strings) >> res = set(''.join(sorted(s1|s2)) for s1 in sets for s2 in sets if >> len(s1^s2)==2) > > I think there can be written more readable code. readability, of course, is

Re: CONSTRUCT - Python's way of Ruby's "alias_method"

2006-06-08 Thread Ilias Lazaridis
Maric Michaud wrote: > Le Jeudi 08 Juin 2006 15:15, Duncan Booth a écrit : >> but the more usual way is just to call the original method directly in the >> base class. >> >> class SqliteAdapter(BaseClass): >> def create_table(self, *args) >> self.table_evolve(*args) >> result =

Re: CONSTRUCT - Python's way of Ruby's "alias_method"

2006-06-08 Thread Ilias Lazaridis
Tim N. van der Leeuw wrote: [...] http://case.lazaridis.com/wiki/Please . -- http://lazaridis.com -- http://mail.python.org/mailman/listinfo/python-list

Request new feature suggestions for my PDF conversion toolkit - xtopdf

2006-06-08 Thread vasudevram
Hi all, I had created this open source project - xtopdf - http://sourceforge.net/projects/xtopdf - some time ago. It's a toolkit to help with conversion of other file formats to PDF. The current tools in xtopdf are available as both end-user command-line tools, and as a library (in both proce

Re: follow-up to FieldStorage

2006-06-08 Thread bruno at modulix
Tim Roberts wrote: > John Salerno <[EMAIL PROTECTED]> wrote: > > >>Bruno Desthuilliers wrote: >> >>>John Salerno a écrit : >>> If I want to get all the values that are entered into an HTML form and write them to a file, is there some way to handle them all at the same time, or must

Re: wxpython: where is the demo?

2006-06-08 Thread Morpheus
That's a separate download. Morpheus "John Salerno" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > I just realized that after installing wxPython, it did not add the usual > menu item to my Start menu (Windows), where I can access the docs and > demo. I searched through the wxPyth

Re: Instead of saving text files i need as html

2006-06-08 Thread bruno at modulix
Shani wrote: > I have the following code which takes a list of urls > "http://google.com";, without the quotes ofcourse, and then saves there > source code as a text file. I wan to alter the code so that for the > list of URLs an html file is saved. What you write in a text file is up to you - an

Re: Instead of saving text files i need as html

2006-06-08 Thread 3c273
"3c273" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Or is this what you mean? > -begin- > import urllib > urlfile = open('c:\\temp\\url.txt', 'r') > newurlfile = open('c:\\temp\\newurls.html', 'w') > newurlfile.write(' \n\n') > for lines in urlfile: > try: > if

Re: How to generate k+1 length strings from a list of k length strings?

2006-06-08 Thread bearophileHUGS
> I think there can be written more readable code. For my programs I > usually prefer simpler code, that (if possible) even a children can > understand. So I can debug, modify and improve it better & faster. Debugged: I think it can be written more readable code. In this newsgroup sometimes I have

Re: what are you using python language for?

2006-06-08 Thread gregarican
Wow that's serious Old School. Reminds me of way-back-when in Data Processing class we used VisiCalc on the old Trash-80's for spreadsheet work. Cut a notch in those 5 1/4" floppies and voila, you doubled your storage capacity :-) Dennis Lee Bieber wrote: > On Thu, 08 Jun 2006 13:52:38 GMT, John S

Re: Instead of saving text files i need as html

2006-06-08 Thread 3c273
"Shani" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > I have the following code which takes a list of urls > "http://google.com";, without the quotes ofcourse, and then saves there > source code as a text file. I wan to alter the code so that for the > list of URLs an html file is s

wxpython: where is the demo?

2006-06-08 Thread John Salerno
I just realized that after installing wxPython, it did not add the usual menu item to my Start menu (Windows), where I can access the docs and demo. I searched through the wxPython folder in the site-packages directory, but I can't seem to find it. Anyone know how I can get this back? Thanks.

Re: Newbie question about updating multiple objects ...

2006-06-08 Thread donkeyboy
Awesome Diez -- I'll give this a go tomorrow, and hopefully it will all work!! Diez B. Roggisch wrote: > [EMAIL PROTECTED] wrote: > > I've copied in the code I'm using below, as it's not very long -- can > > anyone help me? > > I'll have some remarks: > > > > <--START--> > > > > from visual import

Re: How to generate k+1 length strings from a list of k length strings?

2006-06-08 Thread bearophileHUGS
Boris Borcic: > I'd favor the following, that I find most readable > sets = map(set,list_of_strings) > res = set(''.join(sorted(s1|s2)) for s1 in sets for s2 in sets if > len(s1^s2)==2) I think there can be written more readable code. For my programs I usually prefer simpler code, that (if possib

Re: Select hangs after some reads

2006-06-08 Thread Jon Ribbens
In article <[EMAIL PROTECTED]>, Steve Holden wrote: > Of course, if the client forces the TCP PSH flag true then the receiver > is guaranteed to debuffer the stream up to that point - this is how FTP > clients work, for example. I don't think that's right. You are confusing the PSH flag (which i

Re: 10GB XML Blows out Memory, Suggestions?

2006-06-08 Thread fuzzylollipop
Fredrik Lundh wrote: > fuzzylollipop wrote: > > > SAX style or a pull-parser has to be used when the data is "large" or > > when you don't really need to process every element and attribute. > > > > This problem looks like it is just a data export / import problem. In > > that case you will either

Re: GUI Program Error

2006-06-08 Thread Scott David Daniels
John Salerno wrote: > >> >>> It may be a platform-specific issue: On Unix/Linux, a window *does* >>> appear when you instantiate Tk, at least with tcl/tk 8.3 and 8.4 >>> (which is the latest stable version AFAIK). Here you should have chimed in with your OS and Python versions. >> same on

Re: The Nature of the Unix Philosophy

2006-06-08 Thread Al Balmer
On 7 Jun 2006 18:35:52 -0700, "Xah Lee" <[EMAIL PROTECTED]> wrote: >The Nature of the “Unix Philosophy” Good grief. Him again. -- Al Balmer Sun City, AZ -- http://mail.python.org/mailman/listinfo/python-list

Re: Instead of saving text files i need as html

2006-06-08 Thread 3c273
"Shani" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > I have the following code which takes a list of urls > "http://google.com";, without the quotes ofcourse, and then saves there > source code as a text file. I wan to alter the code so that for the > list of URLs an html file is s

Re: XML, JSON, or what?

2006-06-08 Thread Ant
> Yes, evaling JSON, or any other text coming from the web, is definitely > a bad idea. > > But there's no need for eval: there are safe JSON codecs for python, Fair enough. And I should imagine that the codecs are still much faster and easier to use than XML for the same purpose. For my purpose

Re: cos: "Integer Required"?!?!?!?

2006-06-08 Thread moonman
I'm using ActiveState PythonV2.4.1 I'm certainly not affecting 'math'. I wonder if the XPlane SDK Python binding is touching anything. I'll download the latest ActiveState Python and keep on plugging. Thanks! Mikael Olofsson wrote: > moonman wrote: > > print self.ACphi, type(self.ACphi) yields

Re: simplexmlrpcserver and allow_none

2006-06-08 Thread Laszlo Nagy
Thomas Bellman írta: > Laszlo Nagy <[EMAIL PROTECTED]> wrote: > > >> I ran in the same problem again. Many others have the same problem. Just >> Google for this: "SimpleXMLRPCServer allow_none site:python.org". >> Looks like the 'allow_none' patch was commited to trunk on 2005 Dec ( >> http://

Re: cos: "Integer Required"?!?!?!?

2006-06-08 Thread Mikael Olofsson
moonman wrote: > print self.ACphi, type(self.ACphi) yields: > 19412557 > > value = XPLMGetDataf(self.ACphi); print value type(value ) yields: > -0.674469709396 > > print math.radians(XPLMGetDataf(self.ACphi)), > type(math.radians(XPLMGetDataf(self.ACphi))) yields: > > TypeError > : > an integ

  1   2   >