Re: pythonic use of properties?

2005-04-14 Thread Gerald Klix
The python rationale is "We are all consenting adults.". You shoukd change "tens" to "_tens" and "ones" to "_ones", in order to syntacticly mark these attributes as internal. If someone not consenting, wants to mess with your internal representation, it's his fault. HTH, Gerald Marcus Goldfish sch

Re: Compute pi to base 12 using Python?

2005-04-14 Thread M.E.Farmer
Dick Moores wrote: > Paul Rubin wrote at 18:20 4/13/2005: > >Dick Moores <[EMAIL PROTECTED]> writes: > > > I need to figure out how to compute pi to base 12, to as many digits > > > as possible. I found this reference, > > > , but I really don't > > > underst

Re: Formated String in optparse

2005-04-14 Thread Peter Otten
Norbert Thek wrote: > Thank You for your help, its working! > > Now I have an additional question. ...which would warrant a separate thread... > The problem is the encoding of the Text > I'm using German, Can you tell me how to encode > the textstring that the Windows commandline shows the spec

Re: Rookie Question: Passing a nested list into a function?

2005-04-14 Thread Sean
Brett, Hard to tell exactly what you're trying to do here, but it looks like you'd be better served using one of the built in python data structures. For example: If you're trying to compare some elements of these textfiles that are broken into titles, and contents for each file, try something li

ANN: matplotlib-0.80

2005-04-14 Thread John Hunter
matplotlib is a 2D graphics package that produces plots from python scripts, the python shell, or embeds them in your favorite python GUI -- wx, gtk, tk, fltk and qt. Unlike many python plotting alternatives it is written in python, so it is easy to extend. matplotlib is used in the finance indu

Re: question about functions

2005-04-14 Thread Donn Cave
Quoth "chris patton" <[EMAIL PROTECTED]>: | Hi everyone. | | I have a question about passing arguments to python functions. Is there | any way to make this job act like Perl? | | sub my_funk { | | print "the first argument: $_[0]\n"; | print "the second argument: $_[1]\n"; } | | In other words, ca

RE Engine error with sub()

2005-04-14 Thread Maurice LING
Hi, I have the following codes: from __future__ import nested_scopes import re from UserDict import UserDict class Replacer(UserDict): """ An all-in-one multiple string substitution class. This class was contributed by Xavier Defrang to the ASPN Python Cookbook (http://aspn.activestat

Re: question about functions

2005-04-14 Thread Heiko Wundram
Am Freitag, 15. April 2005 06:44 schrieb chris patton: > In other words, can I call the arguments from a list? Yes. >>> def testfunc(*args): ... print args[0] ... print args[1] ... >>> testfunc("this is","a test") this is a test Read up on positional and keyword arguments (the latter are som

Re: question about functions

2005-04-14 Thread James Stroud
Oops, I messed up the indices on the previous post. Also, maybe you are thinking a bit more perlish: # start of ascript def my_funk(*alist): print "the first argument: %s" % alist[0] print "the second argument: %s" % alist[1] my_funk('wuzzup,','g?') # end of ascript On Thursday 14 April 20

Re: question about functions

2005-04-14 Thread James Stroud
Just pass a list. E.g.: # start of ascript def my_funk(alist): print "the first argument: %s" % alist[1] print "the second argument: %s" % alist[2] mylist = ['wuzzup,','g?'] my_funk(mylist) # end of ascript Here is the output you expect: the first argument: wuzzup, the second argument:

question about functions

2005-04-14 Thread chris patton
Hi everyone. I have a question about passing arguments to python functions. Is there any way to make this job act like Perl? sub my_funk { print "the first argument: $_[0]\n"; print "the second argument: $_[1]\n"; } In other words, can I call the arguments from a list? -- http://mail.python.

Re: pythonic use of properties?

2005-04-14 Thread Michele Simionato
I don't use properties that much, but when I use them I put them *outside* the class, in a property factory. Here is an example I have prepared for my course at PyUK, using a property to crypt a password attribute: class User(object): def __init__(self, username, password): self.use

Re: pythonic use of properties?

2005-04-14 Thread Michael Spencer
Marcus Goldfish wrote: I'd like advice/opinions on when it is appropriate to do Just an opinion... attribute/property validation in python. I'm coming from a C#/Java background, where of course tons of "wasted" code is devoted to property validation. Here is a toy example illustrating my question

Re: New-style classes, iter and PySequence_Check

2005-04-14 Thread Raymond Hettinger
[Bengt Richter] > I'm not sure, but I think it may be expedient optimization practicality beating purity. It is more a matter of coping with the limitations of the legacy API where want to wrap a sequence iterator around __getitem__ in sequences but not in mappings. > > I haven't walked the r

Re: Rookie Question: Passing a nested list into a function?

2005-04-14 Thread Brett
I think so. I later reference it as textfilelist[0][0]. My intent is to be able to use: titlelist1[x][1] as part of my "if" statement in my function. -Brett "James Stroud" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > > Do you really want quotation marks around "titlelist1[x

pythonic use of properties?

2005-04-14 Thread Marcus Goldfish
I'd like advice/opinions on when it is appropriate to do attribute/property validation in python. I'm coming from a C#/Java background, where of course tons of "wasted" code is devoted to property validation. Here is a toy example illustrating my question: # Example: mixing instance attributes

Is Python appropriate for web applications?

2005-04-14 Thread Unknown User
I am a Python programmer and I'm thinking about learning PHP, which is similar to C++ (quite different from Python). I want to start writing web applications. Do you think if I learn PHP I'll develop faster? Does PHP have more features? How about the speed of execution? What are the pros and

Re: Rookie Question: Passing a nested list into a function?

2005-04-14 Thread James Stroud
Do you really want quotation marks around "titlelist1[x][1]" ? e.g. >>> textfilelist = [["titlelist1[x][1]"]] >>> textfilelist[0][1] Traceback (most recent call last): File "", line 1, in ? IndexError: list index out of range On Thursday 14 April 2005 06:51 pm, Brett wrote: > I am trying to

Re: Compute pi to base 12 using Python?

2005-04-14 Thread Dick Moores
Dick Moores wrote at 18:40 4/14/2005: Sorry about that. I just listened to Kojima's "NEW Chorus Pi (Japanese) / 2:28 Chorus: MacinTalk Voices. The music was created from the constant PI." on that page. The vocal is singing the digits of base-10 pi. ten is . or decimal

Rookie Question: Passing a nested list into a function?

2005-04-14 Thread Brett
I am trying to pass the value of a nested list into a function (to my "if" statement) as follows: textfilelist = [["titlelist1[x][1]"]] def idfer(listlength, comparelistlength, list): while x < (listlength - 1): while y < comparelistlength:

Re: new to mac OS10

2005-04-14 Thread Maurice LING
I was actually trying to update to the newest python version, and I had read something saying it would conflict with the old version, so I went through and deleted all the folders that had "python" in the name =]. clever of me, huh? now I can't make either the new or the old work. Once again,

Re: Compute pi to base 12 using Python?

2005-04-14 Thread Dick Moores
Steve Holden wrote at 22:29 4/13/2005: Dick Moores wrote: Steve Holden wrote at 19:12 4/13/2005: Dick Moores wrote: Dan wrote at 18:02 4/13/2005: On Wed, 13 Apr 2005 03:27:06 -0700, Dick Moores <[EMAIL PROTECTED]> wrote: > I'm just trying to help an artist acquaintance who needs (I just >learned) t

Re: New-style classes, iter and PySequence_Check

2005-04-14 Thread Bengt Richter
On Thu, 14 Apr 2005 15:18:20 -0600, Steven Bethard <[EMAIL PROTECTED]> wrote: >Tuure Laurinolli wrote: >> Someone pasted the original version of the following code snippet on >> #python today. I started investigating why the new-style class didn't >> work as expected, and found that at least som

Re: Supercomputer and encryption and compression @ rate of 96%

2005-04-14 Thread Peter Hansen
R. C. James Harlow wrote: On Thursday 14 April 2005 22:21, R. C. James Harlow wrote: You have to do that before Fredrick's script works... Damn - 'Fredrik's' - I accidentally decompressed his name. It actually *is* "Fredrick", but the c is both silent, and hidden... -seemed-silly-enough-for-this-t

Re: Dr. Dobb's Python-URL! - weekly Python news and links (Apr 11)

2005-04-14 Thread John Hazen
* Dave Brueck <[EMAIL PROTECTED]> [2005-04-14 07:49]: [Roel Schroeven] > >Not that it really matters, but does anybody know why the weekly Python > >news always arrives twice? Does it only happen to me, or does it happen > >to others too? > > > >It's not that it irritates me or anything, I'm just b

Re: Web Application Client Module

2005-04-14 Thread Chung Leong
"Henk Verhoeven" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Chung Leong wrote: > > > > It's easy. Just create an application that hosts the MSHTML ActiveX control > > (IE itself minus the interface). With tools like Delphi or Visual Basic, > > it's literally a matter of dragging

Re: Socket Error

2005-04-14 Thread Matt
[EMAIL PROTECTED] wrote: > Thanks everybody, it works now. I thought I needed to do something like > that but it didn't show it in the tutorial so I decided to ask here. Where was the tutorial? If it's in the Python docs, perhaps you could submit a patch to fix it ... ;-) M@ -- http://mail.py

Re: new to mac OS10

2005-04-14 Thread Thomas Nelson
Maurice LING wrote: I'm using OSX 10.3.8 as well. Just wondering, how did you "destroy" it? What I am thinking is, it may not be as destroyed as you think it might have... cheers maurice I was actually trying to update to the newest python version, and I had read something saying it would confl

Announcement: AsyncSocket module

2005-04-14 Thread Josh Close
I wrote an asynchronous socket module because asyncore and asynchat didn't quite fit my needs. AsyncSocket has support for connection and read/write timeouts. It is currently only supported in linux. It's been stable for me in all my uses so far. I'd like people to give it a try and let me know wh

Re: new to mac OS10

2005-04-14 Thread Maurice LING
Thomas Nelson wrote: I'm on a mac OS X (10.3.8), and I seem to have accidentally destroyed the default python installation. How should I put it on? Do I need to use the unix version? any help would be greatly appreciated. THN Hi Thomas, I'm using OSX 10.3.8 as well. Just wondering, how did yo

new to mac OS10

2005-04-14 Thread Thomas Nelson
I'm on a mac OS X (10.3.8), and I seem to have accidentally destroyed the default python installation. How should I put it on? Do I need to use the unix version? any help would be greatly appreciated. THN -- http://mail.python.org/mailman/listinfo/python-list

Re: Text & Unicode processing references on the web.

2005-04-14 Thread MrJean1
Check David Mertz' book and web site to start. There is more in some of the list here . /Jean Brouwers anthony hornby wrote: > Hi, > I am starting my honours degree project and part of it is going to be > manipulating AS

Function to log exceptions and keep on truckin

2005-04-14 Thread Steve M
import sys, traceback def e2str(id): """Return a string with information about the current exception. id is arbitrary string included in output.""" exc = sys.exc_info() file, line, func, stmt = traceback.extract_tb(exc[2])[-1] return("%s: %s line %s (%s): %s" % (id, func, line, rep

wxPython OGL: How make LineShape text b/g transparent?

2005-04-14 Thread John Perks and Sarah Mount
(Having problems receiving wxPython mailing list entries, so I'll ask here.) I'm using wxPython 2.5.4, windows ansi version, on Python 2.4, the OS in Win98SE. My application manipulates a graph, with CircleShapes for nodes and LineShapes for arcs. The user needs to be able to get and set text on a

Re: Using python from a browser/security hole

2005-04-14 Thread Philippe C. Martin
Since I need to access a local/client device from the page and that I wish to be cross-platform; does that mean Java is my only way out ? Regards, Philippe Neil Hodgson wrote: > Philippe: > >> I read that IE had the capability to embedd Python scripts, but what >> about the others ? > >

Re: SimpleXMLRPCServer - disable output

2005-04-14 Thread codecraig
Jeremy, Thanks for clearing that up. I am so used to java (i.e. foo.setLogRequests(0))...that I forgot I could just do, foo.logRequests = 0. Learning one day at a time :) Thanks. -- http://mail.python.org/mailman/listinfo/python-list

[ANN] IPython 0.6.13 is out.

2005-04-14 Thread Fernando Perez
Hi all, I'm glad to announce the release of IPython 0.6.13. IPython's homepage is at: http://ipython.scipy.org and downloads are at: http://ipython.scipy.org/dist I've provided RPMs (for Python 2.3 and 2.4, built under Fedora Core 3), plus source downloads (.tar.gz). Fedora users should note

Re: database in python ?

2005-04-14 Thread Andy Dustman
Mage wrote: > Andy Dustman wrote: > > > > >Transactions available since 3.23.17 (June 2000) > > > > > Transactions only supported on slow database types like innodb. > > If you ever tried it you cannot say that mysql supports transactions. No. > Last time when I tried mysql 4.x did explicit commit

Re: SimpleXMLRPCServer - disable output

2005-04-14 Thread Jeremy Jones
codecraig wrote: Jeremy Jones wrote: codecraig wrote: Hi, I thought I posted this, but its been about 10min and hasnt shown up on the group. Basically I created a SimpleXMLRPCServer and when one of its methods

Re: SimpleXMLRPCServer - disable output

2005-04-14 Thread codecraig
Jeremy Jones wrote: > codecraig wrote: > > >Hi, > > I thought I posted this, but its been about 10min and hasnt shown up > >on the group. > > Basically I created a SimpleXMLRPCServer and when one of its methods > >gets called and it returns a response to the client, the server prints > >some inf

Re: Get the entire file in a variable - error

2005-04-14 Thread John Machin
On 14 Apr 2005 07:37:11 -0700, [EMAIL PROTECTED] wrote: >H! > >I'm using a database and now I want to compress a file and put it into >the database. > >So I'm using gzip because php can open the gzip file's. >The only problem is saving the file into the database. > >The function below does this: >

Re: Supercomputer and encryption and compression @ rate of 96%

2005-04-14 Thread Lonnie Princehouse
That's pretty good, but I have an algorithm that compresses data into zero bits. def compress(data): pass To decompress, you simply generate a random string of random length using a random number generator based on quantum states, with the expectation that you happen to be in one of the possibl

Re: Using python from a browser

2005-04-14 Thread Neil Hodgson
Philippe: > I read that IE had the capability to embedd Python scripts, but what > about the others ? While Python can be set up as a scripting language for IE, this is normally disabled as it could be a security hole. The open call is available from Python scripts so a web site could read

Re: database in python ?

2005-04-14 Thread Andy Dustman
Steve Holden wrote: > I don't know about the whole picture, but I know form evidence on this > group that there are PostgreSQL driver modules (the name "psycopg" comes > to mind, but this may be false memory) that appear to take diabolical > liberties with DBAPI-2.0, whereas my experience with My

Re: Using python from a browser

2005-04-14 Thread Do Re Mi chel La Si Do
Hi ! I confirm for IE. Others, I don't know. @-salutations Michel Claveau -- http://mail.python.org/mailman/listinfo/python-list

Re: Supercomputer and encryption and compression @ rate of 96%

2005-04-14 Thread Michael Spencer
Fredrik Lundh wrote: Tiziano Bettio wrote: could someone please tell me that this thread wasn't a aprilsfoll day joke and it is for real... i'm pretty much able to go down to a single bit but what would be the reverse algorithm as stated by martin... magic? I suggest running my script on a couple

Re: New-style classes, iter and PySequence_Check

2005-04-14 Thread Raymond Hettinger
[Tuure Laurinolli] > Someone pasted the original version of the following code snippet on > #python today. I started investigating why the new-style class didn't > work as expected > classes apparently don't return true for PyInstance_Check, which causes > a problem in PySequence_Check, since it wi

Re: Using python from a browser

2005-04-14 Thread Philippe C. Martin
Hi, >> What do you mean ? Is that a client-side or server-side script ? Client side >>Where ? Programming Python - O'Reilly - 2nd edition - by Mark Lutz - Paragraph "Teaching IE about Python" - Pages 922-925 Regards, Philippe -- http://mail.python.org/mailman/listinfo/python-list

Re: Supercomputer and encryption and compression @ rate of 96%

2005-04-14 Thread R. C. James Harlow
On Thursday 14 April 2005 22:21, R. C. James Harlow wrote: > You have to do that before Fredrick's script works... Damn - 'Fredrik's' - I accidentally decompressed his name. pgpbUXNRRyNvA.pgp Description: PGP signature -- http://mail.python.org/mailman/listinfo/python-list

Re: Supercomputer and encryption and compression @ rate of 96%

2005-04-14 Thread Fredrik Lundh
Tiziano Bettio wrote: > Actually your script doesn't work on my python distribution... > > (using 2.3.2) since then, 2.3.3, 2.3.4, 2.3.5, 2.4, and 2.4.1 has been released. since the code uses generator expressions, you need at least 2.4. (or you can add [] around the generator expressions, to t

Re: How to debug SOAP using TCpMon and Python?

2005-04-14 Thread Diez B. Roggisch
Jim wrote: > Hello, > > I am trying to debug a Python SOAP > application using tcpmon. I am wondering what > listen port, target port number and host > address should I use. > > What about optional parameters: Http Proxy > support, host and port? Did you try setting the usual environment variab

Re: Supercomputer and encryption and compression @ rate of 96%

2005-04-14 Thread Fred Pacquier
Christos "TZOTZIOY" Georgiou <[EMAIL PROTECTED]> said : > Well, I take advantage of this "folding" idea for years now. Do you > remember DoubleSpace? I was getting to the limits [1] of my 100 MiB > hard disk, so I was considering upgrading my hardware. A female > friend of mine, knowing a littl

Re: changing colors in python

2005-04-14 Thread jay graves
AFAIK, the cmd.exe program on Win2K/XP doesn't support ANSI escape sequences. There are various other options on windows but they probably won't work on Linux. http://newcenturycomputers.net/projects/wconio.html http://effbot.org/zone/console-handbook.htm -- http://mail.python.org/mailman/listi

Re: changing colors in python

2005-04-14 Thread Kane
To convert ansi escape sequences into text colors you need a terminal that understands what you are doing. Linux does this by default; dos and windows do not. You need to have an extra program in memory. The conventional approach is the "ANSI.SYS" driver which probably still ships with Windows (

Re: Supercomputer and encryption and compression @ rate of 96%

2005-04-14 Thread Tiziano Bettio
R. C. James Harlow wrote: On Thursday 14 April 2005 22:18, Tiziano Bettio wrote: Actually your script doesn't work on my python distribution... Works fine here - did you decompress the first bit of the python executable? You have to do that before Fredrick's script works... well i tried

Re: Supercomputer and encryption and compression @ rate of 96%

2005-04-14 Thread R. C. James Harlow
On Thursday 14 April 2005 22:18, Tiziano Bettio wrote: > Actually your script doesn't work on my python distribution... Works fine here - did you decompress the first bit of the python executable? You have to do that before Fredrick's script works... pgpYFHzjRTUoB.pgp Description: PGP signatur

Re: New-style classes, iter and PySequence_Check

2005-04-14 Thread Steven Bethard
Tuure Laurinolli wrote: Someone pasted the original version of the following code snippet on #python today. I started investigating why the new-style class didn't work as expected, and found that at least some instances of new-style classes apparently don't return true for PyInstance_Check, whic

Re: Supercomputer and encryption and compression @ rate of 96%

2005-04-14 Thread Tiziano Bettio
Fredrik Lundh wrote: Tiziano Bettio wrote: could someone please tell me that this thread wasn't a aprilsfoll day joke and it is for real... i'm pretty much able to go down to a single bit but what would be the reverse algorithm as stated by martin... magic? I suggest running my script on a

Re: Supercomputer and encryption and compression @ rate of 96%

2005-04-14 Thread Fredrik Lundh
Tiziano Bettio wrote: > could someone please tell me that this thread wasn't a aprilsfoll day > joke and it is for real... > > i'm pretty much able to go down to a single bit but what would be the > reverse algorithm as stated by martin... magic? I suggest running my script on a couple of small

changing colors in python

2005-04-14 Thread GujuBoy
i have a ansi.py file that i use in LINUX to change the text color to STDOUT when i use the "print" function...but when i move this ansi.py file over the windows...it does not work is there a version of ansi.py i can use for windows/linux please help -- http://mail.python.org/mailman/listin

Re: SimpleXMLRPCServer - disable output

2005-04-14 Thread Jeremy Jones
codecraig wrote: >Hi, > I thought I posted this, but its been about 10min and hasnt shown up >on the group. > Basically I created a SimpleXMLRPCServer and when one of its methods >gets called and it returns a response to the client, the server prints >some info out to the console, such as, > >lo

Re: SimpleXMLRPCServer - disable output

2005-04-14 Thread Skip Montanaro
codecraig> I thought I posted this, but its been about 10min and hasnt codecraig> shown up on the group. Patience... codecraig> localhost - - [14/Apr/2005 16:06:28] "POST /RPC2 HTTP/1.0" 200 - codecraig> Anyhow, is there a way I can surpress that so its not printed codecraig

Re: distribute python script

2005-04-14 Thread Thomas Heller
"codecraig" <[EMAIL PROTECTED]> writes: > Thanks so much Thomas!!! I added encodings to my setup's...here it is > > setup(console=[{"script": 'monkey_shell.py'}], options={"py2exe": > {"packages": ["encodings"]}}) > > and i did the same for the other python script. > > Thanks!! Cool. The next p

Re: Supercomputer and encryption and compression @ rate of 96%

2005-04-14 Thread Jeremy Bowers
On Thu, 14 Apr 2005 17:44:56 +0200, Fredrik Lundh wrote: > Will McGugan wrote: > >> Muchas gracias. Although there may be a bug. I compressed my Evanescence >> albumn, but after decompression it became the complete works of Charles > > strange. the algorithm should be reversible. sounds like a

Re: Socket Error

2005-04-14 Thread kingofearth . com
Thanks everybody, it works now. I thought I needed to do something like that but it didn't show it in the tutorial so I decided to ask here. -- http://mail.python.org/mailman/listinfo/python-list

SimpleXMLRPCServer - disable output

2005-04-14 Thread codecraig
Hi, I thought I posted this, but its been about 10min and hasnt shown up on the group. Basically I created a SimpleXMLRPCServer and when one of its methods gets called and it returns a response to the client, the server prints some info out to the console, such as, localhost - - [14/Apr/2005 1

SimpleXMLRPCServer - turn of output

2005-04-14 Thread codecraig
Hi, I have a simple script which starts a SimpleXMLRPCServer. A client connects to the server and executes one of the servers methods. When the server processes the request and returns it, the server prints some info out to the console, something like this.. localhost - - [14/Apr/2005 15:47:12

Re: Using python from a browser

2005-04-14 Thread Bruno Desthuilliers
Philippe C. Martin a écrit : Hi, I have a python script I wish to call from various browsers (IE; Mozilla, Firefox ..) on Windows & Linux. What do you mean ? Is that a client-side or server-side script ? I read that IE had the capability to embedd Python scripts, Where ? -- http://mail.python.o

Re: Looking for a very specific type of embedded GUI kit

2005-04-14 Thread Sizer
Thanks for your suggestions - after digging into SDL it looks pretty darn easy to add your own primitive devices at the low level (in src/video/), so that seems like the way to go. Once SDL is working, plenty of kits run on top of it. -- http://mail.python.org/mailman/listinfo/python-list

Re: Converting a perl module to a python module would it be worthit?

2005-04-14 Thread Bruno Desthuilliers
Mothra a écrit : (snip) I checked out the above link (thanks!!) I need to look deeper at the docs for creating a "module" Well, start with wrting the code - you'll take care of how-to-distribute-it later. Thanks all for the responses!! You're welcome. -- http://mail.python.org/mailman/listinfo/p

Re: How to debug SOAP using TCpMon and Python?

2005-04-14 Thread Bruno Desthuilliers
Jim a écrit : Hello, I am trying to debug a Python SOAP What about unit tests ? -- http://mail.python.org/mailman/listinfo/python-list

Re: distribute python script

2005-04-14 Thread codecraig
Thanks so much Thomas!!! I added encodings to my setup's...here it is setup(console=[{"script": 'monkey_shell.py'}], options={"py2exe": {"packages": ["encodings"]}}) and i did the same for the other python script. Thanks!! -- http://mail.python.org/mailman/listinfo/python-list

Re: distribute python script

2005-04-14 Thread Thomas Heller
"codecraig" <[EMAIL PROTECTED]> writes: > surei posted another thread eariler, which explains much more > related to py2exe..check that out and let me know if that helps. > > http://groups-beta.google.com/group/comp.lang.python/browse_thread/thread/4071921987be308d I'm monitoring this group,

Using python from a browser

2005-04-14 Thread Philippe C. Martin
Hi, I have a python script I wish to call from various browsers (IE; Mozilla, Firefox ..) on Windows & Linux. I read that IE had the capability to embedd Python scripts, but what about the others ? Regards, Philippe -- * Philippe C. Martin SnakeCard, L

Re: py2exe + XML-RPC problem

2005-04-14 Thread codecraig
sorry, I am actually still getting the 500 internal error I reported earlier. thanks for ur input. -- http://mail.python.org/mailman/listinfo/python-list

Re: py2exe + XML-RPC problem

2005-04-14 Thread codecraig
update to this. I generated an exe for the client and server. They both run fine, except, when i send a command from the client to server, the cleint spits out this.. xmlrpclib.ProtocolError: When I run the .py's by themselves I do not get this. This only occurs with the generated .exe's. th

Re: distribute python script

2005-04-14 Thread codecraig
surei posted another thread eariler, which explains much more related to py2exe..check that out and let me know if that helps. http://groups-beta.google.com/group/comp.lang.python/browse_thread/thread/4071921987be308d -- http://mail.python.org/mailman/listinfo/python-list

Re: distribute python script

2005-04-14 Thread Larry Bates
py2exe works just fine, but you didn't give enough information for us to help you. Thomas Heller (maintainer of py2exe) monitors this list. So post some more information of what "...caused a problem in my script..." means and we will all try to help. Larry Bates codecraig wrote: > i want to dist

Re: Get the entire file in a variable - error

2005-04-14 Thread Larry Bates
In the future it REALLY helps if you post the code that you used to open and read the file. Otherwise we have to "guess" what you may of done. That said, I'll try to guess: 1) Your code shows that you instantiate GzipFile class with mode "w". I don't know what your data looks like but normally

Re: Socket Error

2005-04-14 Thread Achim Domma (Procoders)
[EMAIL PROTECTED] wrote: NameError: name 'socket' is not defined You forgot to import the socket module: import socket regards, Achim -- http://mail.python.org/mailman/listinfo/python-list

Re: Socket Error

2005-04-14 Thread [EMAIL PROTECTED]
You missed the import socket statement. Also the socket.PF_INET should be socket.AF_INET -- http://mail.python.org/mailman/listinfo/python-list

Re: Socket Error

2005-04-14 Thread Tiziano Bettio
[EMAIL PROTECTED] wrote: When I try to open a socket with python i get the following error: Traceback (most recent call last): File "./mailer", line 3, in ? sock = socket.socket(socket.PF_INET, socket.SOCK_STREAM) NameError: name 'socket' is not defined the code is: #!/usr/bin/python sock = soc

Weekly Python Patch/Bug Summary

2005-04-14 Thread Kurt B. Kaiser
Patch / Bug Summary ___ Patches : 314 open ( +6) / 2824 closed ( +5) / 3138 total (+11) Bugs: 898 open (+16) / 4921 closed ( +8) / 5819 total (+24) RFE : 177 open ( +1) / 151 closed ( +0) / 328 total ( +1) New / Reopened Patches __ typos in

Re: Supercomputer and encryption and compression @ rate of 96%

2005-04-14 Thread Tiziano Bettio
[EMAIL PROTECTED] wrote: And how do you get the data back ? 1+0=0 == 0+0=0 0+1=1 == 1+1=1 let's say you have the end key : 0 then you want to decompress it , but in what ? 0 0 or 1 0 ;) hi there could someone please tell me that this thread wasn't a aprilsfoll day joke and it is for real... i'm

Socket Error

2005-04-14 Thread kingofearth . com
When I try to open a socket with python i get the following error: Traceback (most recent call last): File "./mailer", line 3, in ? sock = socket.socket(socket.PF_INET, socket.SOCK_STREAM) NameError: name 'socket' is not defined the code is: #!/usr/bin/python sock = socket.socket(socket.P

RE: Generating RTF with Python

2005-04-14 Thread Sells, Fred
Apache fop does a good job of combining xslt+xml to generate pdf; the spec says it does RTF, but I have not tried it. Although fop is java, you can run it as a (java) executable, so you could run it as a command from python. It is almost as good as reportlab's stuff. -Original Message- Fr

Re: Python 2.3.5 make: *** [Parser/pgen] Error 1 Parser/grammar.o: I n function `translabel': undefined reference to `__ctype_b'

2005-04-14 Thread Diez B. Roggisch
Karalius, Joseph wrote: > Can anyone explain what is happening here? I haven't found any useful > info on Google yet. What have you been googling? I found this: http://lists.debian.org/debian-glibc/2002/10/msg00093.html Basically it seems that it's a problem with libc in general, not with pyth

distribute python script

2005-04-14 Thread codecraig
i want to distribute my python script as an executable. I have tried py2exe but it caused a problem in my script when I ran it. I know about Gordon McMillans Installer (which is no longer hosted)..but i tried that and when i run the .exe it generated, it just crashes (i.e. Windows wants to send a

Re: Simple Python + Tk text editor

2005-04-14 Thread Jonathan Fine
Eric Brunel wrote: Do you know the (apparently dead) project named e:doc? You can find it here: http://members.nextra.at/hfbuch/edoc/ It's a kind of word processor that can produce final documents to various formats using backends, and one of the backends is for LaTeX. It's written in Perl, but

PyAr - Python Argentina 8th Meeting, today

2005-04-14 Thread Batista, Facundo
Title: PyAr - Python Argentina 8th Meeting, today The Argentine Python User Group, PyAr, will have its eighth meeting today at 7:00pm. Agenda -- Despite our agenda tends to be rather open, this time we would like to cover these topics: - Conclusions of PyAr in PyCon 2005. - See what

Python 2.3.5 make: *** [Parser/pgen] Error 1 Parser/grammar.o: I n function `translabel': undefined reference to `__ctype_b'

2005-04-14 Thread Karalius, Joseph
Can anyone explain what is happening here? I haven't found any useful info on Google yet. Thanks in advance. mmagnet:/home/jkaralius/src/zopeplone/Python-2.3.5 # make gcc -pthread -c -fno-strict-aliasing -DNDEBUG -g -O3 -Wall -Wstrict-prototypes -I. -I./Include -DPy_BUILD_CORE -o Modules/python.

Re: smtplib does not send to all recipients

2005-04-14 Thread Peter Hansen
Peter Hansen wrote: [EMAIL PROTECTED] wrote: OK, I've discovered the lost messages, but I'm still slightly confused as to why they ended up there. The messages were being delivered to the local machine, box1.domain.com, even though I was addressing them to @domain.com. The address is irrelevant wi

Re: smtplib does not send to all recipients

2005-04-14 Thread Peter Hansen
[EMAIL PROTECTED] wrote: OK, I've discovered the lost messages, but I'm still slightly confused as to why they ended up there. The messages were being delivered to the local machine, box1.domain.com, even though I was addressing them to @domain.com. The address is irrelevant with SMTP. What matte

Re: Get the entire file in a variable - error

2005-04-14 Thread Pokerface
What kind of DB? Maybe the field type you're hunting for is a BLOB? Or perhaps you need to be formatting the string differently than it's entered (like php's addslashes() or something)? -- Pokerface:: Posted from Tactical Gamer - http://www.TacticalGamer.com :: -- http://mail.python.org/mai

Re: Converting a perl module to a python module would it be worthit?

2005-04-14 Thread Mothra
"Ivan Van Laningham" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Hi All-- > > bruno modulix wrote: > > > > Mothra wrote: > > > Hi All, > > > > > > I am the current author of the Astro-Sunrise perl module > > > http://search.cpan.org/~rkhill/Astro-Sunrise-0.91/Sunrise.pm > > > and

Re: String manipulation

2005-04-14 Thread Terry Reedy
"vincent wehren" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > "Nicholas Graham" > | Any suggestions? > Take a look at the built-in functions ord() and chr() > -- Chapter 2.1 of the manual. And more generally, read all of Chap.2 of the Library Reference on builtin functions an

Re: curses for different terminals

2005-04-14 Thread harold fellermann
On 14.04.2005, at 19:17, Christos TZOTZIOY Georgiou wrote: On Thu, 14 Apr 2005 18:39:14 +0200, rumours say that harold fellermann <[EMAIL PROTECTED]> might have written: Hi all, I want to use curses in a server application that provides a GUI for telnet clients. Therefore, I need the functionality

Re: curses for different terminals

2005-04-14 Thread TZOTZIOY
On Thu, 14 Apr 2005 18:39:14 +0200, rumours say that harold fellermann <[EMAIL PROTECTED]> might have written: >Hi all, >I want to use curses in a server application that provides a GUI for >telnet clients. Therefore, I need the functionality to open and handle >several >screens. Just to make

Re: Web Application Client Module

2005-04-14 Thread Henk Verhoeven
Chung Leong wrote: It's easy. Just create an application that hosts the MSHTML ActiveX control (IE itself minus the interface). With tools like Delphi or Visual Basic, it's literally a matter of dragging and dropping the control into the form. Even in Visual C++ it's not that hard. Hi Chung , Of co

Re: Python-list Digest, Vol 19, Issue 209

2005-04-14 Thread Scott Leerssen
On Apr 13, 2005, at 12:41 PM, [EMAIL PROTECTED] wrote: From: Scott Leerssen <[EMAIL PROTECTED]> Date: April 13, 2005 12:29:35 PM EDT To: [email protected] Subject: unstatisfied symbols building Python 2.4.1 on HP-UX 10.20 I'm trying to build Python 2.4.1 on HP-UX 10.20 and get the followin

  1   2   >