Leo 4.4a2 withdrawn

2005-11-06 Thread Edward K. Ream
Leo 4.4a2 has been withdrawn due to problems that can cause Leo to lose what you have recently typed. Leo 4.4a3 will be released in about a week. Edward Edward K. Ream email: [EMAIL PROTECTED] Leo:

ANN: Speedometer 2.1 - bandwidth and download monitor

2005-11-06 Thread Ian Ward
Announcing Speedometer 2.1 -- Speedometer home page: http://excess.org/speedometer/ Download: http://excess.org/speedometer/speedometer.py New in this release: - New simultaneous display of multiple graphs with options for stacking graphs

ANN: atomixlib 0.3.0

2005-11-06 Thread Sylvain Hellegouarch
atomixlib 0.3.0 Available at : http://www.defuze.org/oss/atomixlib/ What's new? * It breaks the compatibility with previous version. Mainly you do not need to pass the current atom element being constructed to the Atomix methods. Instead the

Dr. Dobb's Python-URL! - weekly Python news and links (Nov 6)

2005-11-06 Thread Cameron Laird
QOTW: - don't use SAX unless your document is huge - don't use DOM unless someone is putting a gun to your head - Istvan Albert I wouldn't fret too much about a sharp remark from Fredrik Lundh. They're pretty much all that way. ;) It looks like you already did the right thing - read past the

Instead of obsessing over the library *reference*, why not use other documentation?

2005-11-06 Thread Fredrik Lundh
Charlton Wilbur wrote: This is one of the places where Apple's Cocoa documentation shines: there are frequently snippets of code accompanying more complicated methods, which is nice, but there are a couple dozen small sample programs that demonstrate how to use particular aspects of the

Re: Class Variable Access and Assignment

2005-11-06 Thread Bengt Richter
On Sun, 06 Nov 2005 15:17:18 +1100, Steven D'Aprano [EMAIL PROTECTED] wrote: On Sat, 05 Nov 2005 18:14:03 -0800, Paul Rubin wrote: instance.attribute sometimes reading from the class attribute is a feature of inheritance; instance.attribute always writing to the instance is a feature of OOP;

Re: Python doc problem example: gzip module (reprise)

2005-11-06 Thread Bengt Richter
On 05 Nov 2005 19:19:29 -0800, Paul Rubin http://[EMAIL PROTECTED] wrote: Mike Meyer [EMAIL PROTECTED] writes: It's only -because- of those licenses that there's any reason not to bundle. Actually, there are other reasons, just as there are reasons besides licensing for not simply

Re: __new__

2005-11-06 Thread Peter Otten
James Stroud wrote: I'm running 2.3.4 I was reading the documentation for classes types http://www.python.org/2.2.3/descrintro.html And stumbled on this paragraph: __new__ must return an object. There's nothing that requires that it return a new object that is an instance of

Re: Can python 'read disk sectors' like/via linux:dd ?

2005-11-06 Thread Tauno Voipio
Pascal Bourguignon wrote: In unix, disks are files like any other file. So if your programming language allows you to read and write files, it allows you to read and write disks. Just write the equivalent of: int fd=open(/dev/hda,O_RDWR,0); if(0==fd){

Re: Using Which Version of Linux

2005-11-06 Thread Max
[EMAIL PROTECTED] wrote: ok, i m going to use Linux for my Python Programs, mainly because i need to see what will these fork() and exec() do. So, can anyone tell me which flavour of linux i should use, some say that Debian is more programmer friendly, or shold i use fedora, or Solaris.

Re: Class Variable Access and Assignment

2005-11-06 Thread Steven D'Aprano
On Sun, 06 Nov 2005 08:40:00 +, Bengt Richter wrote: Pre-conditions: class.a exists and is mutable; instance.a does not exist. Post-conditions: class.a modified; instance.a does not exist. Are you saying the above is what happens or what should happen or not happen? Er, it's what I thought

Re: Instead of obsessing over the library *reference*, why not use other documentation?

2005-11-06 Thread Steven D'Aprano
On Sun, 06 Nov 2005 09:31:54 +0100, Fredrik Lundh wrote: (this would also make it easier for less ignorant newbies to find the examples: when Xah first complained about gzip, googling for python gzip example brought up a full page of examples. If you do the same search today, you'll still

Re: Can python 'read disk sectors' like/via linux:dd ?

2005-11-06 Thread Pascal Bourguignon
Tauno Voipio [EMAIL PROTECTED] writes: Pascal Bourguignon wrote: In unix, disks are files like any other file. So if your programming language allows you to read and write files, it allows you to read and write disks. Just write the equivalent of: int fd=open(/dev/hda,O_RDWR,0);

Re: Instead of obsessing over the library *reference*, why not use other documentation?

2005-11-06 Thread Diez B. Roggisch
People are linking to Xah??? Or he is google-bombing? I guess /F meant the results on google that show this very NG/ML. Diez -- http://mail.python.org/mailman/listinfo/python-list

Pylab and pyserial plot in real time

2005-11-06 Thread googlinggoogler
Hiya, I've got a PIC microcontroller reading me humidity data via rs232, this is in ASCII format. I can view this data easily using hyperterminal or pyserial and convert it to its value (relative humidty with ord(input)) But what im trying to do is plot the data in real time, ideally with pylab

Re: Python doc problem example: gzip module (reprise)

2005-11-06 Thread jmdeschamps
Sorry but I take exception on this subject. I still think Fredrik's Intro to Tkinter is still more usable ... Grayson's book uses PMW extensively, and a lot is about specific widgets of that library. This actually brings us back to the jest of F. previous post, that documentation is question of

So, Which Version is Suitable for Beginners

2005-11-06 Thread [EMAIL PROTECTED]
I m actually a Novice in Python as well as Linux, When i look up things on the internet about Linux Flavours, They are written so complex that it is difficult for me to understand, i am asking if anyone here know of a Linux Distribution that is for beginners (I am a new user of linux,

Re: So, Which Version is Suitable for Beginners

2005-11-06 Thread Christoph Haas
On Sunday 06 November 2005 13:29, [EMAIL PROTECTED] wrote: I m actually a Novice in Python as well as Linux, When i look up things on the internet about Linux Flavours, They are written so complex that it is difficult for me to understand, i am asking if anyone here know of a Linux

Re: So, Which Version is Suitable for Beginners

2005-11-06 Thread Roel Schroeven
Christoph Haas wrote: On Sunday 06 November 2005 13:29, [EMAIL PROTECTED] wrote: B) I need it to work on VMware Workstation 5 Most do. I installed Ubuntu on VMware Workstation 5 just a few days ago. Works nicely. There's one small problem: when installing the VMware tools in Ubuntu, the

finding and accessing multiple documentation sources

2005-11-06 Thread Fredrik Lundh
[EMAIL PROTECTED] wrote: This actually brings us back to the jest of F. previous post, that documentation is question of multiple source reference, and yes that you have to work the field (Google search, newgroups, cookbooks, source-code, et al) a little bit to get some information. while I

Re: modifying source at runtime - jython case

2005-11-06 Thread Jan Gregor
In article [EMAIL PROTECTED], Kent Johnson wrote: Jan Gregor wrote: Hello folks I want to apply changes in my source code without stopping jython and JVM. Preferable are modifications directly to instances of classes. My application is a desktop app using swing library. Can you be

Re: Using Which Version of Linux

2005-11-06 Thread Terry Hancock
On Sun, 06 Nov 2005 11:53:03 +0200 Max [EMAIL PROTECTED] wrote: It uses DEB packages, which are apparently better, but software (I find) is much easier to find in RPM format. I find this a bit of a deceptive impression. It is easier to find *third party* RPMs. OTOH, the Debian distribution

Icon on wx.MDIParentFrame

2005-11-06 Thread LenS
I would like to put an Icon on the frame but cannot figure out how to do it any help. Running on XP machine. It appears that wxPython suffers from the same problem as most software packages. I find that the reference manual is only of any real help once you have a pretty good understanding of

Can't instantiate class

2005-11-06 Thread David Mitchell
Hello, Here is a very basic question, but it is frustrating me to no end nonetheless. I have one file called addLink.py. In a method in this file I am trying to instantiate a class and call a method from that class. Here is the code: def getCategories(): # instantiate the DataUtil

Re: Can't instantiate class

2005-11-06 Thread Michael P. Soulier
On 11/6/05, David Mitchell [EMAIL PROTECTED] wrote: import DataUtil File C:\Apache2\htdocs\Intranet\addLink.py, line 42, in getCategories db = DataUtil() TypeError: 'module' object is not callable You've imported module DataUtil, and by calling DataUtil(), you're trying to call the

Re: Can't instantiate class

2005-11-06 Thread Fredrik Lundh
David Mitchell wrote: Here is a very basic question, but it is frustrating me to no end nonetheless. I have one file called addLink.py. In a method in this file I am trying to instantiate a class and call a method from that class. Here is the code: def getCategories(): # instantiate the

Re: Icon on wx.MDIParentFrame

2005-11-06 Thread Andrea Gavana
Hello Len I would like to put an Icon on the frame but cannot figure out how to do it any help. What about: wx.MDIParentFrame.SetIcon(self, icon) ? I usually take a look also to the wxPython API docs at: http://www.wxpython.org/docs/api/ Or I use some google-fu to find answers, both for

Re: Can't instantiate class

2005-11-06 Thread David Mitchell
Thanks for your prompt reply. Ok, so If use your first suggestion (db = DataUtil.DataUtil() ), I get this error: AttributeError: 'module' object has no attribute 'DataUtil' If I try importing the class directly (from DataUtil import DataUtil), I get this error: ImportError: cannot import name

Re: I need Motivation

2005-11-06 Thread Markus
I can recommend you listening to the Python411 podcast. http://www.awaretek.com/python/index.html -Markus- [EMAIL PROTECTED] wrote: I m not a python Expert or anythin i need help, i m losin my motivation to continue with python can anyone inspire me again.??? --

Re: starting an X11 session from Python

2005-11-06 Thread Philippe C. Martin
Thanks I will look, I intend to use tkinter for the display as it is built-in though. Regards, Philippe Richard Townsend wrote: On Sat, 05 Nov 2005 19:51:40 +, Philippe C. Martin wrote: Hi, Have there been any attempt to do so, and is there any source out there that could help me

Re: Multiples of a number

2005-11-06 Thread Ivan Shevanski
On 11/5/05, Steven D'Aprano [EMAIL PROTECTED] wrote: On Sun, 06 Nov 2005 02:39:40 +0100, Carl Friedrich Bolz wrote: Hi! Ivan Shevanski wrote: I've searched on google for a bit but I can't seem to find a way to get multiples of a number. . .For instance what would I do if I wanted something to

Clearing output screen

2005-11-06 Thread Ivan Shevanski
I know there is a way to do this, but google doesn't seem to want to find it =) There is a command to clear the output screen right? Thanks in advance, -Ivan -- http://mail.python.org/mailman/listinfo/python-list

Re: Icon on wx.MDIParentFrame

2005-11-06 Thread LenS
Thanks I will keep an eye out for the book. I just downloaded wxGlade and created a small file and looked at how it does it. Again thanks for the response -- http://mail.python.org/mailman/listinfo/python-list

Re: __new__

2005-11-06 Thread Alex Martelli
Peter Otten [EMAIL PROTECTED] wrote: ... is as __new__ had left it). Thus, for a new-style class C, the statement x=C(23) is equivlent to the following code: x = C.__new__(C, 23) if isinstance(x, C): C.__init__(x, 23) ... the Nutshell example should be changed to x =

Re: Clearing output screen

2005-11-06 Thread Fredrik Lundh
Ivan Shevanski wrote I know there is a way to do this, but google doesn't seem to want to find it =) There is a command to clear the output screen right? no, because output screen isn't a well-defined concept on modern operating systems. the following works in many cases: import os

Newbie Alert: Help me store constants pythonically

2005-11-06 Thread Brendan
Hi all I'm new to Python (and programming in general), and I can't decide what is the most 'pythonic' way to approach a problem. Your advice would be appreciated. I have a bunch of 'scans', containing the data measured from one of several types of 'model'. Each 'model' has different values for

? MDI depreciated

2005-11-06 Thread LenS
Hate to ask this dum question (since I've been hiding under a rock). But if the MDI UI model is/was depreciated. What is the new UI model. Would love some links that explain in gerneral and specific terms. Len Sumnler -- http://mail.python.org/mailman/listinfo/python-list

Re: Python gui

2005-11-06 Thread Gian Mario Tagliaretti
Philippe C. Martin wrote: Is wxWidget now part of python ? or will it be ? No, and *I hope* that if another toolkit has to replace Tkinter (will never happen?) will be PyGTK... :) cheers -- Gian Mario Tagliaretti PyGTK GUI programming http://www.parafernalia.org/pygtk/ --

Re: I need Motivation

2005-11-06 Thread Gian Mario Tagliaretti
Alex Martelli wrote: Not without knowing more about your motivations for starting Python in the first place... Alex, maybe trolling in this list? :) Alex ciao -- Gian Mario Tagliaretti PyGTK GUI programming http://www.parafernalia.org/pygtk/ --

socket receive file does not match sent file

2005-11-06 Thread [EMAIL PROTECTED]
I wrote two simple socket program. one for sending a file and the other for receiving the file. but when I run it, a curious thing happened. The received file was samller that the sent file. $ cat receivefile.py #!/usr/local/bin/python # -*- coding: utf-8 -*- import socket import time import

Re: Learning multiple languages (question for general discussion)

2005-11-06 Thread Paul Rubin
[EMAIL PROTECTED] (Alex Martelli) writes: I can't imagine NOT getting enthusiastic and stimulated by reading Van Roy and Hariri's book -- it IS quite as good and readable as SICP. It's been on my want-to-read list for a long time. I have the downloaded draft edition (from before the print

Re: Class Variable Access and Assignment

2005-11-06 Thread Christopher Subich
Bengt Richter wrote: On Fri, 04 Nov 2005 10:28:52 -0500, Christopher Subich [EMAIL PROTECTED] wrote: is very much within the language specification. Indeed, the language specification dictates that an instance variable b.a is created if one didn't exist before; this is true no matter if

Re: Modify HTML data

2005-11-06 Thread Swarna
Peter Hansen wrote: Swarna wrote: I am using scp in python to copy a html file on remote server, to my local machine. Now, i need to update this html file in my local machine ( by adding a new Hyperlink to the existing table od hyperlinks ) and copy it back (overwriting the old copy ) to

Re: mod_python

2005-11-06 Thread Steve Holden
Little wrote: I have created the following database but the following errors occur when trying to execute the code. html source: html body Click here to display information from Chocolate menu: form action =form.py/display method=POST p Press to view the display input

Re: Newbie Alert: Help me store constants pythonically

2005-11-06 Thread Francesco Bochicchio
Il Sun, 06 Nov 2005 08:33:17 -0800, Brendan ha scritto: Hi all I'm new to Python (and programming in general), and I can't decide what is the most 'pythonic' way to approach a problem. Your advice would be appreciated. I have a bunch of 'scans', containing the data measured from one of

Re: mod_python

2005-11-06 Thread Steve Holden
Steve Holden wrote: [...] The second error message seems to imply that the database InventoryList table doesn't have a column called article. regards Steve ^article^artist^ -- Steve Holden +44 150 684 7255 +1 800 494 3119 Holden Web LLC www.holdenweb.com

Re: Learning multiple languages (question for general discussion)

2005-11-06 Thread Diez B. Roggisch
Do you have any opinion of Types and Programming Languages by Pierce? Autrijus Tang (the guy who started PUGS, the Perl 6 implementation in Haskell) raves about it in an interview, and another guy I know recommended it too, but I haven't actually looked at a copy yet (stores I've looked in

Re: Can't instantiate class

2005-11-06 Thread Fredrik Lundh
David Mitchell wrote: Ok, so If use your first suggestion (db = DataUtil.DataUtil() ), I get this error: AttributeError: 'module' object has no attribute 'DataUtil' If I try importing the class directly (from DataUtil import DataUtil), I get this error: ImportError: cannot import name

Re: modifying source at runtime - jython case

2005-11-06 Thread Kent Johnson
Jan Gregor wrote: my typical scenario is that my swing application is running, and i see some error or chance for improvement - modify sources of app, stop and run application again. so task is to reload class defitions (from source files) and modify also existing instances (their methods).

Re: Newbie Alert: Help me store constants pythonically

2005-11-06 Thread Brendan
Thanks for the vote FB. The reason I'm using that method for assigning instance attributes is that the argument list for __init__ is LOOONG. (There are many constants, I only gave two for the examples). I wanted to avoid typing them out twice. --

Re: GMPY: divm() memory leak revisited

2005-11-06 Thread [EMAIL PROTECTED]
Alex Martelli wrote: [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: ... Unfortunately, I don't have any means of testing this theory. Yep -- I reproduced the memory leak you mentioned, and easily fixed it (exactly as you suggest) in the current CVS version of gmpy (meant to be 1.01

Dr. Dobb's Python-URL! - weekly Python news and links (Nov 6)

2005-11-06 Thread Cameron Laird
QOTW: - don't use SAX unless your document is huge - don't use DOM unless someone is putting a gun to your head - Istvan Albert I wouldn't fret too much about a sharp remark from Fredrik Lundh. They're pretty much all that way. ;) It looks like you already did the right thing - read past the

Re: Python gui

2005-11-06 Thread Sybren Stuvel
Gian Mario Tagliaretti enlightened us with: No, and *I hope* that if another toolkit has to replace Tkinter (will never happen?) will be PyGTK... :) Why do you hope for PyGTK? I think one of the strengths of wxWidgets is that it uses the native platform's look. GTK looks very nice on my Gnome

Re: ? MDI depreciated

2005-11-06 Thread Brendan
This is probably a question better suited for a wxPython or MSDN newsgroup. What OS are you referring to? What GUI toolkit are you using? Microsoft's office on Windows has moved to a model where every document has its own toolbar, menubar, and taskbar entry. Windows developers tend to mimic MS

Re: Python gui

2005-11-06 Thread Andrea Gavana
No, and *I hope* that if another toolkit has to replace Tkinter (will never happen?) will be PyGTK... :) This will only mean that people that now prefer wxPython over Tkinter will in future prefer wxPython over PyGTK ;-) Andrea. -- Imagination Is The Only Weapon In The War Against Reality.

Re: modifying source at runtime - jython case

2005-11-06 Thread Alan Kennedy
[Jan Gregor] Following try showed me that instances aren't affected by modification in class definition. Is this more like what you mean? c:\jython Jython 2.1 on java1.4.2_09 (JIT: null) Type copyright, credits or license for more information. class a: ... def test(self): ...

Re: socket receive file does not match sent file

2005-11-06 Thread Jean-Paul Calderone
On 6 Nov 2005 09:13:03 -0800, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: I wrote two simple socket program. one for sending a file and the other for receiving the file. but when I run it, a curious thing happened. The received file was samller that the sent file. Your sender does not take care to

Re: ? MDI depreciated

2005-11-06 Thread Andrea Gavana
Hello Len, Hate to ask this dum question (since I've been hiding under a rock). But if the MDI UI model is/was depreciated. What is the new UI model. This much depends on which kind of application you have in mind. In my organization a lot of software that we use (basically for reservoir

Re: ? MDI depreciated

2005-11-06 Thread Tony Nelson
In article [EMAIL PROTECTED], LenS [EMAIL PROTECTED] wrote: Hate to ask this dum question (since I've been hiding under a rock). But if the MDI UI model is/was depreciated. What is the new UI model. Would love some links that explain in gerneral and specific terms. In article [EMAIL

Validate string as UTF-8?

2005-11-06 Thread Tony Nelson
I'd like to have a fast way to validate large amounts of string data as being UTF-8. I don't see a fast way to do it in Python, though: unicode(s,'utf-8').encode('utf-8) seems to notice at least some of the time (the unicode() part works but the encode() part bombs). I don't consider a

Re: ? MDI depreciated

2005-11-06 Thread SPE - Stani's Python Editor
Hi Len, The preference of most users is quite platform related: - Mac users are the most pronounced, they like SDI (single document interface), where there is one frame for every document - Most linux users like something between MDI and SDI: a tabbed interface, like firefox, where there is one

Re: Learning multiple languages (question for general discussion)

2005-11-06 Thread Paul Rubin
Diez B. Roggisch [EMAIL PROTECTED] writes: It's a great book - I cetainly owe it the better part of my thesis about multi level specification for functional languages. If you want to understand type-systems, its a great comprehensive read. So do I really want to understand type systems? I

Re: Can't instantiate class

2005-11-06 Thread Bengt Richter
On Sun, 06 Nov 2005 09:47:04 -0500, David Mitchell [EMAIL PROTECTED] wrote: Thanks for your prompt reply. Ok, so If use your first suggestion (db = DataUtil.DataUtil() ), I get this error: AttributeError: 'module' object has no attribute 'DataUtil' Have you looked to see what DataUtil you are

Re: Using Which Version of Linux

2005-11-06 Thread Mike Meyer
Terry Hancock [EMAIL PROTECTED] writes: Similarly, I see RPMs by ones and twos all over the place, and only a few places with DEBs. But the DEB repositories are HUGE. Try rpmfind.net. It's not clear where the rpms reside, but it's not really important - it's a huge collection of RPMs.

Re: Learning multiple languages (question for general discussion)

2005-11-06 Thread Diez B. Roggisch
Paul Rubin wrote: Diez B. Roggisch [EMAIL PROTECTED] writes: It's a great book - I cetainly owe it the better part of my thesis about multi level specification for functional languages. If you want to understand type-systems, its a great comprehensive read. So do I really want to

Re: Validate string as UTF-8?

2005-11-06 Thread david mugnai
On Sun, 06 Nov 2005 18:58:50 +, Tony Nelson wrote: [snip] Is there a general way to call GLib functions? ctypes? http://starship.python.net/crew/theller/ctypes/ -- http://mail.python.org/mailman/listinfo/python-list

Re: Validate string as UTF-8?

2005-11-06 Thread Fredrik Lundh
Tony Nelson wrote: I'd like to have a fast way to validate large amounts of string data as being UTF-8. define validate. I don't see a fast way to do it in Python, though: unicode(s,'utf-8').encode('utf-8) if validate means make sure the byte stream doesn't use invalid sequences, a

Re: Python gui

2005-11-06 Thread gsteff
PyGTK is just easier to code with. The api is much nicer. However, yeah, the windows/mac appearance probably does make it a non-starter, unfortunately. As near as I can tell, the solution that currently has the most momentum is to just integrate the cheeseshop more tightly into python, so that

Re: Pylab and pyserial plot in real time

2005-11-06 Thread Peter Hansen
[EMAIL PROTECTED] wrote: I've got a PIC microcontroller reading me humidity data via rs232, this is in ASCII format. What do you mean when you say it's in ASCII format? ASCII defines a convention for representing control and printable characters. Do you mean that the readings you get are

Re: Validate string as UTF-8?

2005-11-06 Thread Diez B. Roggisch
Tony Nelson wrote: I'd like to have a fast way to validate large amounts of string data as being UTF-8. I don't see a fast way to do it in Python, though: unicode(s,'utf-8').encode('utf-8) seems to notice at least some of the time (the unicode() part works but the encode() part

Re: Icon on wx.MDIParentFrame

2005-11-06 Thread Peter Hansen
LenS wrote: Thanks I will keep an eye out for the book. I just downloaded wxGlade and created a small file and looked at how it does it. That (copying someone else) is almost always the best approach anyway, even when one has decent documentation. Note that with wxPython you should have

Re: Modify HTML data

2005-11-06 Thread Peter Hansen
Swarna wrote: Peter Hansen wrote: Swarna wrote: I am using scp in python to copy a html file on remote server, to my local machine. Now, i need to update this html file in my local machine ( by adding a new Hyperlink to the existing table od hyperlinks ) and copy it back (overwriting the old copy

Re: Validate string as UTF-8?

2005-11-06 Thread Tony Nelson
In article [EMAIL PROTECTED], david mugnai [EMAIL PROTECTED] wrote: On Sun, 06 Nov 2005 18:58:50 +, Tony Nelson wrote: [snip] Is there a general way to call GLib functions? ctypes? http://starship.python.net/crew/theller/ctypes/ Umm. Might be easier to write an extension

Perl XML::Simple and Data::Dumper - exists in Python?

2005-11-06 Thread Miguel Manso
Hi there, I'm a Perl programmer trying to get into Python. I've been reading some documentation and I've choosed Python has being the next step to give. Can you point me out to Python solutions for: 1) Perl's Data::Dumper It dumps any perl variable to the stdout in a readable way. 2) Perl's

Windows service using the socket module

2005-11-06 Thread JDF
I am fairly new to python and seem to have gotten ahead of myself. I am trying to write a Windows service that will return the current number of Citrix sessions to a client. This service will run on my Citrix servers for usage tracking purposes. The service itself seems to function properly, it

zipfile.py, fp.seek(-22,2) error

2005-11-06 Thread Waitman Gobble
Hello, I am new to Python. I am having trouble with zipfile.py. On a Linux machine with python 2.4.2 I have trouble opening a zipfile. Python is complaining about the bit where it does a seek(-22,2). Looks to me like zipfile.py is trying to come back 22 bytes from the end of file. # python

Re: So, Which Version is Suitable for Beginners

2005-11-06 Thread Steve M
There is a new gratis VMWare player at http://www.vmware.com/download/player/ You can download an image http://www.vmware.com/vmtn/vm/browserapp.html that they call a Browser Appliance, but if I remember correctly it is Ubuntu. -- http://mail.python.org/mailman/listinfo/python-list

Re: Validate string as UTF-8?

2005-11-06 Thread Waitman Gobble
I have done this using a sytem call to the program recode. Recode a file UTF-8 and do a diff on the original and recoded files. Not an elegant solution but did seem to function properly. Take care, Waitman Gobble -- http://mail.python.org/mailman/listinfo/python-list

Re: Python gui

2005-11-06 Thread Peter Decker
On 6 Nov 2005 12:08:23 -0800, gsteff [EMAIL PROTECTED] wrote: PyGTK is just easier to code with. The api is much nicer. That's why I think that Dabo's UI module is the best of all worlds. It wraps wxPython, so the controls look great on any platform, but provides a cleaner and more consistent

how to think like a computer scientist

2005-11-06 Thread john boy
Ok...I'm new to Python..and of course am already having troubles. I have tried the following example from "how to think like a computer scientist" def newline(): print print "firstline" newline() print "secondline" problem iswhenever I type -print "firstline"- and then hit enter...well it

Re: Using Which Version of Linux

2005-11-06 Thread Steve M
Max wrote: (Mark Shuttleworth, ... really loves Python - he gave me quite a lot of money for using it). Please elaborate. -- http://mail.python.org/mailman/listinfo/python-list

UnicodeEncodeError: 'ascii' codec can't encode character u'\xe1' in position 99: ordinal not in range(128)

2005-11-06 Thread Francach
Hi, I don't know what I'm doing wrong here. I''m using Python 2.4 and py2exe. I get he following error: Traceback (most recent call last): File notegui.pyc, line 34, in OnClose File brain.pyc, line 61, in setNote File points.pyc, line 151, in setNote File point.pyc, line 100, in

Re: Validate string as UTF-8?

2005-11-06 Thread Tony Nelson
In article [EMAIL PROTECTED], Fredrik Lundh [EMAIL PROTECTED] wrote: Tony Nelson wrote: I'd like to have a fast way to validate large amounts of string data as being UTF-8. define validate. All data conforms to the UTF-8 encoding format. I can stand if someone has made data that

Re: Modify HTML data

2005-11-06 Thread Swarna
Peter Hansen wrote: Swarna wrote: Peter Hansen wrote: Swarna wrote: I am using scp in python to copy a html file on remote server, to my local machine. Now, i need to update this html file in my local machine ( by adding a new Hyperlink to the existing table od hyperlinks ) and copy it

Re: zipfile.py, fp.seek(-22,2) error

2005-11-06 Thread Waitman Gobble
ok, i figured it out. the file i was trying to read on the linux machine was 0b. lol. i guess the invalid argument error was throwing me off. -- http://mail.python.org/mailman/listinfo/python-list

how to think like a computer scientist

2005-11-06 Thread john boy
I am using the book "how to think like a computer scientist" and am finding the examples are not working with Python 2.4.2...I have typed them exactly as they appear in the textcan someone relate to this?...is this typical b/c 2.4.2 is a newer version? -xray- Yahoo! FareChase - Search

Re: UnicodeEncodeError: 'ascii' codec can't encode character u'\xe1' inposition 99: ordinal not in range(128)

2005-11-06 Thread Fredrik Lundh
Francach wrote: I don't know what I'm doing wrong here. I''m using Python 2.4 and py2exe. I get he following error: Traceback (most recent call last): File notegui.pyc, line 34, in OnClose File brain.pyc, line 61, in setNote File points.pyc, line 151, in setNote File point.pyc,

Re: UnicodeEncodeError: 'ascii' codec can't encode character u'\xe1' in position 99: ordinal not in range(128)

2005-11-06 Thread Diez B. Roggisch
I would've thought that the 'b' option meant I can write any binary code I like to the file, but that's not so? You can. But if you write a unicode-object (wich is an abstract data type with no byte representation), it has to be converted to a string - which you have to do either explicit.

Re: Class Variable Access and Assignment

2005-11-06 Thread Bengt Richter
On Sun, 06 Nov 2005 12:23:02 -0500, Christopher Subich [EMAIL PROTECTED] wrote: Bengt Richter wrote: On Fri, 04 Nov 2005 10:28:52 -0500, Christopher Subich [EMAIL PROTECTED] wrote: is very much within the language specification. Indeed, the language specification dictates that an instance

Re: how to think like a computer scientist

2005-11-06 Thread Fredrik Lundh
john boy wrote: I am using the book how to think like a computer scientist and am finding the examples are not working with Python 2.4.2...I have typed them exactly as they appear in the textcan someone relate to this?...is this typical b/c 2.4.2 is a newer version? no. did you read

Re: Learning multiple languages (question for general discussion)

2005-11-06 Thread Alex Martelli
Paul Rubin http://[EMAIL PROTECTED] wrote: [EMAIL PROTECTED] (Alex Martelli) writes: I can't imagine NOT getting enthusiastic and stimulated by reading Van Roy and Hariri's book -- it IS quite as good and readable as SICP. It's been on my want-to-read list for a long time. I have the

Re: Perl XML::Simple and Data::Dumper - exists in Python?

2005-11-06 Thread Fredrik Lundh
Miguel Manso wrote: Can you point me out to Python solutions for: 1) Perl's Data::Dumper It dumps any perl variable to the stdout in a readable way. import pprint help(pprint) 2) Perl's XML::Simple It maps a XML file into a Perl data structure. some alternatives:

Re: Pylab and pyserial plot in real time

2005-11-06 Thread googlinggoogler
Yea I know the data is correct, all I do is sample my data with an ADC and then send it to the serial port. using hyper terminal or indeed pyserial presents the data as a ASCII charecters, the value of these Charecters is the converted to there equivalent decimal value using the ord() command.

Re: Perl XML::Simple and Data::Dumper - exists in Python?

2005-11-06 Thread George Sakkis
Fredrik Lundh [EMAIL PROTECTED] wrote: Miguel Manso wrote: Can you point me out to Python solutions for: 1) Perl's Data::Dumper It dumps any perl variable to the stdout in a readable way. import pprint help(pprint) 2) Perl's XML::Simple It maps a XML file into a Perl data

Re: Python doc problem example: gzip module (reprise)

2005-11-06 Thread Steven D'Aprano
On Sun, 06 Nov 2005 04:28:35 -0800, jmdeschamps wrote: This actually brings us back to the jest of F. previous post, I didn't think it was very funny... Unless you meant the *gist* of Fredrik's post. -- Steven. -- http://mail.python.org/mailman/listinfo/python-list

Re: Pylab and pyserial plot in real time

2005-11-06 Thread Kent Johnson
[EMAIL PROTECTED] wrote: Hiya, I've got a PIC microcontroller reading me humidity data via rs232, this is in ASCII format. I can view this data easily using hyperterminal or pyserial and convert it to its value (relative humidty with ord(input)) But what im trying to do is plot the data

Re: Using Which Version of Linux

2005-11-06 Thread Norman Silverstone
On Sun, 06 Nov 2005 12:39:54 -0800, Steve M wrote: Max wrote: (Mark Shuttleworth, ... really loves Python - he gave me quite a lot of money for using it). Please elaborate. Mark Shuttleworth is a very wealthy man who is supporting the development of Ubuntu. His wealth came from Linux

Installing ATLAS and LAPACK

2005-11-06 Thread Darren L. Weber
The following is a first attempt to almost create a shell script for installation of ATLAS and LAPACK. It does not work right now and it is specific to a particular platform. It is posted here to archive it and throw into the public domain, maybe others will find it useful. It is at least a

Installing ATLAS and LAPACK

2005-11-06 Thread Darren L. Weber
The following is a first attempt to almost create a shell script for installation of ATLAS and LAPACK. It does not work right now and it is specific to a particular platform. It is posted here to archive it and throw into the public domain, maybe others will find it useful. It is at least a

Re: mod_python

2005-11-06 Thread Jim Segrave
In article [EMAIL PROTECTED], Little [EMAIL PROTECTED] wrote: I have created the following database but the following errors occur when trying to execute the code. html source: html body Click here to display information from Chocolate menu: form action =form.py/display method=POST p

  1   2   >