ANN: Writing Arinoid using pyGame (4 ShowMeDo videos)

2007-01-09 Thread Ian Ozsvald
Summary: Chuck Arellano created 4 pyGame videos during 2006 which show the viewer how to build an Arinoid (Arkanoid-like) game clone. Full src and graphics are provided: http://showmedo.com/videos/series?name=pythonArellanoPyGameSeries Detail: Chuck produced the videos and is considering

ANN: Einführung in die Programmierung m it Python (1 German ShowMeDo video, 3 m inutes)

2007-01-09 Thread Ian Ozsvald
Summary: Lucas Holland and Marius Meinert have created the first video in a forthcoming series introducing Python Programming. The video is in German (speech and text), it would be hard for a non-German speaker to follow. This is the first in a planned series of 6 videos:

ANN: PyInstaller: Installation und Anwendung (1 German ShowMeDo video, 5 minutes)

2007-01-09 Thread Ian Ozsvald
Summary: Lucas Holland has created a German video showing you how to use the pyInstaller tool. The video is quite watchable for English-only speakers: http://showmedo.com/videos/video?name=pythonHollandPyInstaller_germanfromSeriesID=43 About pyInstaller: PyInstaller is a program that converts

Come join me at PyCon 2007!

2007-01-09 Thread Guido van Rossum
The next Python Conference, PyCon 2007, will be in Dallas, Texas, February 23-25 (Friday through Sunday). PyCon is a community-oriented conference targeting developers of Python applications and the Python interpreter itself. The organizers aim to make the conference affordable and accessible to

PythonTidy 1.9

2007-01-09 Thread Chuck Rhode
PythonTidy cleans up, regularizes, and reformats the text of Python scripts. It is released under the GNU General Public License. This is the first public release. Python scripts are usually so good looking that no beautification is required. However, from time to time, it may be necessary to

Re: Colons, indentation and reformatting. (2)

2007-01-09 Thread Diez B. Roggisch
Won't the following rules work when pasting complete Python statements and complete lines, after other lines in an editor: lets call the line after which the block is to be pasted the paste line, and the original indent of the first line of the copied block to be pasted the copy indent.

Re: Colons, indentation and reformatting. (2)

2007-01-09 Thread Paddy
OK, whilst colons are not sufficient to re-format a completely mis-indented file. I'm thinking that they are sufficient for reformatting most pasted code blocks when refactoring say? - Paddy. -- http://mail.python.org/mailman/listinfo/python-list

Re: help: code formatter?

2007-01-09 Thread siggi
Chuck wrote: http://lacusveris.com/PythonTidy/PythonTidy.python Wow, what a giant of a program! Trying to find out how this works. Thank you, siggi Chuck Rhode [EMAIL PROTECTED] schrieb im Newsbeitrag news:[EMAIL PROTECTED] siggi wrote this on Mon, Jan 08, 2007 at 03:33:21PM +0100. My

Re: help: code formatter?

2007-01-09 Thread siggi
Thomas wrote: Tools\scripts\reindent.py in your Python distribution. Thank you Thomas! What a bucket full of toolsin \tools! I didn't know that. siggi Thomas Heller [EMAIL PROTECTED] schrieb im Newsbeitrag news:[EMAIL PROTECTED] siggi schrieb: Hi all, as a newbie I have problems with

line duplication using logging to file

2007-01-09 Thread seb
Hi, I am writing to a file some basic information using the logging module. It is working but in the log file some line are printed several time. I had put some print debugging messages in the logging function (so they appear on the consile) and they are called once only. Obviously there is some

Re: private variables

2007-01-09 Thread Bruno Desthuilliers
belinda thom a écrit : Hello, In what version of python were private variables added? Which private variables ? -- http://mail.python.org/mailman/listinfo/python-list

Re: private variables

2007-01-09 Thread belinda thom
On Jan 9, 2007, at 12:20 AM, Bruno Desthuilliers wrote: belinda thom a écrit : Hello, In what version of python were private variables added? Which private variables ? Haha. The ones that are provided for convenience (via name mangling) that aren't really private if you wish to violate

Re: Module to read svg

2007-01-09 Thread Tim Roberts
Robert Kern [EMAIL PROTECTED] wrote: Martin v. Löwis wrote: [EMAIL PROTECTED] schrieb: Does anyone know if there's an actual free implementation of this? For the dom module in it, xml.dom.minidom should work. Depending on your processing needs, that might be sufficient. I don't think it

Re: Execute binary code

2007-01-09 Thread Hendrik van Rooyen
Chris Mellon [EMAIL PROTECTED] wrote: sigh Repost. Is there any chance at all that ML could set the reply-to to the list instead of the sender? +1 - I regularly hit reply all, delete the OP, and then I get : Message has a suspicious header - Hendrik --

Re: recursive function

2007-01-09 Thread Hendrik van Rooyen
cesco [EMAIL PROTECTED] wrote: Neil Cerutti wrote: On 2007-01-08, cesco [EMAIL PROTECTED] wrote: Hi, I have a dictionary of lists of tuples like in the following example: dict = {1: [(3, 4), (5, 8)], 2: [(5, 4), (21, 3), (19, 2)], 3: [(16, 1), (0, 2), (1,

Re: Bitwise expression

2007-01-09 Thread Hendrik van Rooyen
Gigs_ [EMAIL PROTECTED] wrote: Can someone explain me bitwise expression? few examples for every expression will be nice x y Left shift x y Right shift x y Bitwise AND x | y Bitwise OR x ^ y Bitwise XOR (exclusive OR) ~x Bitwise negation The short, and possibly weird, but true,

Re: code formatter?

2007-01-09 Thread Hendrik van Rooyen
siggi [EMAIL PROTECTED] wrote: Is there a simple code formatter that first removes all indentations and then refomats correctly? tabnanny ? - Hendrik -- http://mail.python.org/mailman/listinfo/python-list

Re: Why less emphasis on private data?

2007-01-09 Thread Hendrik van Rooyen
Steven D'Aprano [EMAIL PROTECTED] wrote: On Mon, 08 Jan 2007 13:11:14 +0200, Hendrik van Rooyen wrote: When you hear a programmer use the word probability - then its time to fire him, as in programming even the lowest probability is a certainty when you are doing millions of things a

Re: Module to read svg

2007-01-09 Thread Robert Kern
Tim Roberts wrote: Robert Kern [EMAIL PROTECTED] wrote: Martin v. Löwis wrote: [EMAIL PROTECTED] schrieb: Does anyone know if there's an actual free implementation of this? For the dom module in it, xml.dom.minidom should work. Depending on your processing needs, that might be sufficient.

Re: recursive function

2007-01-09 Thread cesco
Hendrik van Rooyen wrote: cesco [EMAIL PROTECTED] wrote: Neil Cerutti wrote: On 2007-01-08, cesco [EMAIL PROTECTED] wrote: Hi, I have a dictionary of lists of tuples like in the following example: dict = {1: [(3, 4), (5, 8)], 2: [(5, 4), (21, 3), (19, 2)],

Re: Colons, indentation and reformatting.

2007-01-09 Thread Leif K-Brooks
Paddy wrote: Thinking about it a little, it seems that a colon followed by non-indented code that has just been pasted in could also be used by a Python-aware editor as a flag to re-indent the pasted code. How would it reindent this code? if foo: print Foo! if bar: print Bar! Like this? if

Re: How to write temporary data to file?

2007-01-09 Thread Marc 'BlackJack' Rintsch
In [EMAIL PROTECTED], Thomas Ploch wrote: d = { 'url1': { 'emails': ['a', 'b', 'c',...], 'matches': ['d', 'e', 'f',...] }, 'url2': {... } This dictionary will get _very_ big, so I want to write it somehow to a file after it has grown to a

formattazione cifra con decimali

2007-01-09 Thread Nuke
Ho cercato un poco sulla documentazione di python senza trovare una risposta soddisfacente al mio problema, quindi spero di trovare un aiuto qui. Ho creato un programmino che mi fa alcuni calcoli e riepiloghi personali e vorrei visualizzare i totali numerici in euro con la formattazione

Re: How to write temporary data to file?

2007-01-09 Thread Laszlo Nagy
Thomas Ploch írta: Hi folks, I have a data structure that looks like this: d = { 'url1': { 'emails': ['a', 'b', 'c',...], 'matches': ['d', 'e', 'f',...] }, 'url2': {... } This dictionary will get _very_ big, so I want to write it somehow

Re: formattazione cifra con decimali

2007-01-09 Thread Nuke
Nuke ha scritto: Ho cercato un poco sulla documentazione di python senza trovare una risposta soddisfacente al mio problema, quindi spero di trovare un aiuto qui. Ho creato un programmino che mi fa alcuni calcoli e riepiloghi personali e vorrei visualizzare i totali numerici in euro con la

Re: General Question About Python

2007-01-09 Thread Torabisu
I think the best I've heard is, Programming in Python is like writing poetry. Its really a beautiful language, so simple, short, powerful and to the point. We use it in conjunction with Django to implement a web based device management solution for our products. We've also written a

Re: line duplication using logging to file

2007-01-09 Thread Vinay Sajip
seb wrote: Hi, I am writing to a file some basic information using the logging module. It is working but in the log file some line are printed several time. I had put some print debugging messages in the logging function (so they appear on the consile) and they are called once only.

Re: General Question About Python

2007-01-09 Thread billie
Torabisu wrote: Its quite weird, we're looking for Python skills but are battling to find at the moment... Normally Python on its own will probably not land you a job, but the last two companies I've worked for are doing indepth Python development, so hopefully the tables are turning a bit.

A simple array in Python

2007-01-09 Thread bg_ie
Hi, I have the following enum - class State: Fire = 0 Water = 1 Earth = 2 And I want a variable which holds a value for each of these states, something like - myState1[State.Fire] = 10 myState1[State.Earth] = 4 myState2[State.Fire] = 20 myState2[State.Earth] = 24 How

Re: A simple array in Python

2007-01-09 Thread Laszlo Nagy
[EMAIL PROTECTED] wrote: Hi, I have the following enum - class State: Fire = 0 Water = 1 Earth = 2 And I want a variable which holds a value for each of these states, something like - class State: Fire = 0 Water = 1 Earth = 2 myState = {}

[ANN] html5lib 0.2

2007-01-09 Thread James Graham
DESCRIPTION HTML parsing library based on the WHATWG Web Applications 1.0 HTML5 specification[1]. The parser is designed to work with all existing flavors of HTML and implements well-defined error recovery that has been specified though analysis of the behavior of modern desktop web browsers.

I compile the Pychm in windows,But meet a lot of errors......

2007-01-09 Thread boyeestudio
The Error is show as below: D:\Downloads\pychm-0.8.4python setup.py build running build running build_py running build_ext building 'chm._chmlib' extension D:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\bin\link.exe /DLL /nologo /INCREMENTAL:NO /LIBPATH:D:\Python24\libs

Re: General Question About Python

2007-01-09 Thread [EMAIL PROTECTED]
Enteng wrote: To those who program in python, what programs do you do? Some Unix TCP servers, some data-driven command line apps, and some web stuff. Also what community projects are you involved in(OSS probably)? None that are Python-based, aside from the occasional patch to support new

Re: Why less emphasis on private data?

2007-01-09 Thread sturlamolden
[EMAIL PROTECTED] wrote: I let the user change the internal state of the engine, I have no assurances that my product (the engine) is doing its job... How would you proceed to protect this inner states? In C++ private members they can be accessed through a cast to void pointer. In Java it can

Re: Colons, indentation and reformatting. (2)

2007-01-09 Thread Paul McGuire
Paddy [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] If this is not the case then the user should be asked wether to re-indent the copy block to be equal to, or de-dented w.r.t. the paste line indent prior to pasting. How would the user know this? Every dedent is ambiguous,

Re: Maths error

2007-01-09 Thread Nick Maclaren
| Rory Campbell-Lange wrote: | | Is using the decimal module the best way around this? (I'm | expecting the first sum to match the second). It seem | anachronistic that decimal takes strings as input, though. As Dan Bishop says, probably not. The introduction to the decimal module makes

Re: Colons, indentation and reformatting. (2)

2007-01-09 Thread Jorgen Grahn
On 8 Jan 2007 23:57:29 -0800, Paddy [EMAIL PROTECTED] wrote: OK, whilst colons are not sufficient to re-format a completely mis-indented file. I'm thinking that they are sufficient for reformatting most pasted code blocks when refactoring say? Let's put it this way: if the formatter can

Re: Bitwise expression

2007-01-09 Thread Gigs_
Hendrik van Rooyen wrote: Gigs_ [EMAIL PROTECTED] wrote: Can someone explain me bitwise expression? few examples for every expression will be nice x y Left shift x y Right shift x y Bitwise AND x | y Bitwise OR x ^ y Bitwise XOR (exclusive OR) ~x Bitwise negation The short, and

Re: line duplication using logging to file

2007-01-09 Thread Paul McGuire
seb [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Hi, I am writing to a file some basic information using the logging module. It is working but in the log file some line are printed several time. I had put some print debugging messages in the logging function (so they appear on

Re: Execute binary code

2007-01-09 Thread Jorgen Grahn
On 8 Jan 2007 12:29:36 -0800, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: [EMAIL PROTECTED] wrote: Is it possible to execute a binary string stored within a python script as executable code ? The script is run under Windows, and the binary code (a full executable file) is stored in a

Re: A simple array in Python

2007-01-09 Thread Paul McGuire
[EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Hi, I have the following enum - class State: Fire = 0 Water = 1 Earth = 2 And I want a variable which holds a value for each of these states, something like - myState1[State.Fire] = 10 myState1[State.Earth] = 4

PyCFunction_New requires a pointer to a static PyMethodDef?

2007-01-09 Thread Ben Sizer
In following the example given at http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/54352, I find that if I instead try to create PyMethodDef instances on the stack and create methods that way, rather than providing pointers to a static array of them, executing the method later raises an

Re: how to find the longst element list of lists

2007-01-09 Thread Peter Otten
Steven D'Aprano wrote: On Mon, 08 Jan 2007 13:55:40 +0100, Peter Otten wrote: The precise results depend on the version of Python you're running, the amount of memory you have, other processes running, and the details of what's in the list you are trying to sort. But as my test shows, sort

Re: Non-blocking pipes during subprocess handling

2007-01-09 Thread Nick Craig-Wood
Tom Plunket [EMAIL PROTECTED] wrote: I'm using subprocess to launch, well, sub-processes, but now I'm stumbling due to blocking I/O. Is there a way for me to know that there's data on a pipe, and possibly how much data is there so I can get it? You might want to check out this

Re: General Question About Python

2007-01-09 Thread Michele Simionato
Enteng wrote: To those who program in python, what programs do you do? Also what community projects are you involved in(OSS probably)? Will mastering the language land me a job? Well, I few years ago I decided to learn Python to get a job and it worked. Of course, you should think of

Re: line duplication using logging to file

2007-01-09 Thread seb
Hi, Thanks for the help. Meanwhile I have written the logging function from scratch and it works without the multiple lines. This means that the multiple line copy is not due to the multiple processes (or thread) trying to access the log file but to something else. Thanks. Sebastien. the new

Re: Execute binary code

2007-01-09 Thread [EMAIL PROTECTED]
Jorgen Grahn wrote: On 8 Jan 2007 12:29:36 -0800, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: For what it's worth[1], under Unix it /is/ impossible. The only way to bring in new code (short of dynamic libraries) is to call exec(2) or its variations, and all need a file system object to load

Using with CSV library in Python 2.2!!!

2007-01-09 Thread mohan
Hi Guys, I'm back one more basic question, this time on using CSV (Comma Seperated Value) library with Python 2.2. At my workplace I have Python 2.2 installed and am using PythonWin 2.2.1 IDE from Mark Hammond. I want to use the CSV library module for reading data from the .csv files and when I

Re: Colons, indentation and reformatting.

2007-01-09 Thread Neil Cerutti
On 2007-01-09, Leif K-Brooks [EMAIL PROTECTED] wrote: Paddy wrote: Thinking about it a little, it seems that a colon followed by non-indented code that has just been pasted in could also be used by a Python-aware editor as a flag to re-indent the pasted code. How would it reindent this

Re: formattazione cifra con decimali

2007-01-09 Thread Jerry Hill
On 9 Jan 2007 01:43:41 -0800, Nuke [EMAIL PROTECTED] wrote: I need to visualize a number (or a string of that number) using the decimal separator. i have this number visualized: 50320,12 and i need that the visualization of this number is: 50.320,13. There is a function that directly convert

pyExcelerator big integer values

2007-01-09 Thread Gacha
I use pyExcelerator to import some data from xml file. One column contains integer values like: 4750456000708 4750456000715 4750456000333 ... But when I do import the pyExcelerator converts them to something like this: 4.7504560002e+12 4.7504560007e+12 4.7504560007e+12 4.7504560003e+12 How I

Re: Maths error

2007-01-09 Thread Carsten Haese
On Tue, 2007-01-09 at 11:38 +, Nick Maclaren wrote: | Rory Campbell-Lange wrote: | | Is using the decimal module the best way around this? (I'm | expecting the first sum to match the second). It seem | anachronistic that decimal takes strings as input, though. As Dan Bishop says,

mxODBC problems

2007-01-09 Thread Sean Davis
I have just installed mxODBC on my x86_64 suse linux machine, where I use unixODBC for connection. Running queries from isql or DataManager works fine for the DSN that I am using. However, under mxODBC, I can get a connection object and a cursor object, but all attempts to execute even the

Re: re.sub and re.MULTILINE

2007-01-09 Thread nyenyec
Paddy wrote: Check the arguments to re.sub. re.sub('(?m)^foo', 'bar', '\nfoo', count=0) '\nbar' - Paddy. Duh! :) I appreciate it, thanks. -- nyenyec -- http://mail.python.org/mailman/listinfo/python-list

Re: Using with CSV library in Python 2.2!!!

2007-01-09 Thread skip
mohan 1. Does Python 2.2 come with CSV library module or not? If yes, mohanhave I lost it somewhere?? As the docs for the csv module indicate, it was new in 2.3. mohan 2. If Python 2.2 does not come with CSV module, is it possible to mohanadd the csv module to the Python

Re: Using with CSV library in Python 2.2!!!

2007-01-09 Thread mohan
[EMAIL PROTECTED] wrote: mohan 1. Does Python 2.2 come with CSV library module or not? If yes, mohanhave I lost it somewhere?? As the docs for the csv module indicate, it was new in 2.3. mohan 2. If Python 2.2 does not come with CSV module, is it possible to mohanadd

Survey respondents needed for masters thesis

2007-01-09 Thread luffmusse
We are two students from the Royal Institute of Technology in Stockholm, Sweden (http://www.kth.se/eng/). We are currently doing our masters thesis in Applied Information Technology where we specialize in security. As a part of this thesis we will do a survey where we compare general information

Determine an object is a subclass of another

2007-01-09 Thread abcd
How can tell if an object is a subclass of something else? Imagine... class Thing: pass class Animal: pass class Dog: pass d = Dog() I want to find out that 'd' is a Dog, Animal and Thing. Such as... d is a Dog d is a Animal d is a Thing Thanks --

Re: Using with CSV library in Python 2.2!!!

2007-01-09 Thread skip
mohan Thanks man. What kind of source code changes should I do to mohan _csv.c file , have you any idea on that too?? I've no particular ideas. There are sometimes small C API changes between feature releases though. If you read through the What's New document for version 2.3 (google

Re: Determine an object is a subclass of another

2007-01-09 Thread Neil Cerutti
On 2007-01-09, abcd [EMAIL PROTECTED] wrote: How can tell if an object is a subclass of something else? Imagine... class Thing: pass class Animal: pass class Dog: pass d = Dog() I want to find out that 'd' is a Dog, Animal and Thing. Such as... d is a Dog d is a

Re: Determine an object is a subclass of another

2007-01-09 Thread Matimus
First you need to subclass the classes so that Dog actually is a subclass of Animal which is a subclass of thing... class Thing: pass class Animal(Thing): pass class Dog(Animal): pass class Weapon(Thing): pass class Gun(Weapon): pass Then you can use 'isinstance' d = Dog()

Re: How to write temporary data to file?

2007-01-09 Thread Thomas Ploch
Laszlo Nagy schrieb: Thomas Ploch írta: Hi folks, I have a data structure that looks like this: d = { 'url1': { 'emails': ['a', 'b', 'c',...], 'matches': ['d', 'e', 'f',...] }, 'url2': {... } This dictionary will get _very_ big, so I want to write it

Internet Survey

2007-01-09 Thread octabox
Hello all, I represent Octabox, an Internet Start-up developing a wide-scale platform for Internet services. We are very interested to know your thoughts on Internet productivity and how it might be improved, and to that end we have set up a short survey at our website -

Re: How to write temporary data to file?

2007-01-09 Thread Thomas Ploch
Thomas Ploch schrieb: Laszlo Nagy schrieb: Thomas Ploch írta: Hi folks, I have a data structure that looks like this: d = { 'url1': { 'emails': ['a', 'b', 'c',...], 'matches': ['d', 'e', 'f',...] }, 'url2': {... } This dictionary will get _very_ big, so I

Re: Determine an object is a subclass of another

2007-01-09 Thread abcd
yea i meant to have animal extend thing and dog extend animalmy mistake. anyways, is there a way to check without having an instance of the class? such as, isinstance(Dog, (Animal, Thing)) ?? thanks -- http://mail.python.org/mailman/listinfo/python-list

Re: Execute binary code

2007-01-09 Thread sturlamolden
Jorgen Grahn wrote: For what it's worth[1], under Unix it /is/ impossible. The only way to bring in new code (short of dynamic libraries) is to call exec(2) or its variations, and all need a file system object to load the code from. The x86 processor cannot tell the difference between code

Re: Determine an object is a subclass of another

2007-01-09 Thread Bruno Desthuilliers
abcd a écrit : yea i meant to have animal extend thing and dog extend animalmy mistake. anyways, is there a way to check without having an instance of the class? such as, isinstance(Dog, (Animal, Thing)) ?? issubclass(Dog, Animal) Note that such tests should only be used in a

Re: Internet Survey

2007-01-09 Thread zoara
On 9 Jan 2007 06:58:15 -0800, [EMAIL PROTECTED] wrote: Hello all, I represent Octabox, an Internet Start-up developing a wide-scale platform for Internet services. We are very interested to know your thoughts on Internet productivity and how it might be improved, and to that end we have

Re: Why less emphasis on private data?

2007-01-09 Thread Steven D'Aprano
On Tue, 09 Jan 2007 10:27:56 +0200, Hendrik van Rooyen wrote: Steven D'Aprano [EMAIL PROTECTED] wrote: On Mon, 08 Jan 2007 13:11:14 +0200, Hendrik van Rooyen wrote: When you hear a programmer use the word probability - then its time to fire him, as in programming even the lowest

Re: Execute binary code

2007-01-09 Thread Chris Mellon
On 9 Jan 2007 07:04:11 -0800, sturlamolden [EMAIL PROTECTED] wrote: Jorgen Grahn wrote: For what it's worth[1], under Unix it /is/ impossible. The only way to bring in new code (short of dynamic libraries) is to call exec(2) or its variations, and all need a file system object to load

Re: code formatter?

2007-01-09 Thread siggi
tabnanny? not quite! Hendrik van Rooyen [EMAIL PROTECTED] schrieb im Newsbeitrag news:[EMAIL PROTECTED] siggi [EMAIL PROTECTED] wrote: Is there a simple code formatter that first removes all indentations and then refomats correctly? tabnanny ? - Hendrik --

how to clean sys.path

2007-01-09 Thread siggi
Hi all, when I do sys.path in IDLE (winXP), i get a horrendously long list of paths, paths I may have used during a lot of trials and errors. How can I clean up sys.path? I mean, trim it of unnecessary paths? So far, I know only the command sys.path.append(r'c:etc...'), but how to delete

Re: Determine an object is a subclass of another

2007-01-09 Thread Felipe Almeida Lessa
On 9 Jan 2007 07:01:31 -0800, abcd [EMAIL PROTECTED] wrote: anyways, is there a way to check without having an instance of the class? In [1]: class A: ...: pass ...: In [2]: class B(A): ...: pass ...: In [3]: issubclass(B, A) Out[3]: True In [4]: isinstance(B(), B)

Re: Xah's Edu Corner: Introduction to 3D Graphics Programing

2007-01-09 Thread hg
Xah Lee wrote: I don't know OpenGL, but i think it is a low-level crap, and have done the industry huge irreparable damage the same way unix has. So you _are_ psychic ! is the end of the world be in 2007 ? -- http://mail.python.org/mailman/listinfo/python-list

Re: Using with CSV library in Python 2.2!!!

2007-01-09 Thread Larry Bates
mohan wrote: Hi Guys, I'm back one more basic question, this time on using CSV (Comma Seperated Value) library with Python 2.2. At my workplace I have Python 2.2 installed and am using PythonWin 2.2.1 IDE from Mark Hammond. I want to use the CSV library module for reading data from the

Re: mxODBC problems

2007-01-09 Thread Larry Bates
Sean Davis wrote: I have just installed mxODBC on my x86_64 suse linux machine, where I use unixODBC for connection. Running queries from isql or DataManager works fine for the DSN that I am using. However, under mxODBC, I can get a connection object and a cursor object, but all attempts to

Re: Internet Survey

2007-01-09 Thread Lawrence Statton XE2/N1GAK
zoara [EMAIL PROTECTED] writes: Link NOT removed to encourage more abuse ... http://www.octabox.com/productivity_poll.php I somehow missed this the first time. Thanks for the pointer -- I gave them some nice PDP-10 related responses. I truly hope to have my TOPS-20 productivity improved

Re: Internet Survey

2007-01-09 Thread Steve O'Hara-Smith
On Tue, 9 Jan 2007 15:25:43 + zoara [EMAIL PROTECTED] wrote: On 9 Jan 2007 06:58:15 -0800, [EMAIL PROTECTED] wrote: Hello all, I represent Octabox, an Internet Start-up developing a wide-scale snip Well, that was too tempting to pass up. Amusing answers related to dirty bastard

Re: Maths error

2007-01-09 Thread Tim Peters
[Rory Campbell-Lange] Is using the decimal module the best way around this? (I'm expecting the first sum to match the second). It seem anachronistic that decimal takes strings as input, though. [Nick Maclaren] As Dan Bishop says, probably not. The introduction to the decimal module makes

Re: Maths error

2007-01-09 Thread Bjoern Schliessmann
Nick Maclaren wrote: No, don't. That is about another matter entirely, It isn't. Regards, Björn -- BOFH excuse #366: ATM cell has no roaming feature turned on, notebooks can't connect -- http://mail.python.org/mailman/listinfo/python-list

Re: help: code formatter?

2007-01-09 Thread Bjoern Schliessmann
siggi wrote: Bjoern wrote: Why don't you just write one? :) Very funny! Just learning Python :( It isn't funny at all. You'll learn by doing and trying things. That's how all programmers start. Regards, Björn -- BOFH excuse #265: The mouse escaped. --

Question about using with

2007-01-09 Thread Steven W. Orr
From the tutorial, they said that the following construct will automatically close a previously open file descriptor: --- #! /usr/bin/python import sys for nn in range ( 1, len(sys.argv ) ): print arg , nn, value = , sys.argv[nn] with open(sys.argv[nn]) as f:

Re: Maths error

2007-01-09 Thread Nick Maclaren
In article [EMAIL PROTECTED], Tim Peters [EMAIL PROTECTED] writes: | | Well, just about any technical statement can be misleading if not qualified | to such an extent that the only people who can still understand it knew it | to begin with 0.8 wink. The most dubious statement here to my eyes

Re: Question about using with

2007-01-09 Thread Laszlo Nagy
591 ./cat.py cat.py File ./cat.py, line 6 with open(sys.argv[nn]) as f: ^ SyntaxError: invalid syntax 592 This example came from http://docs.python.org/tut/node10.html down in section 8.7 Am I missing something? Are you using python 2.5? The with statement

Re: how to clean sys.path

2007-01-09 Thread Laszlo Nagy
So far, I know only the command sys.path.append(r'c:etc...'), but how to delete or insert at the beginning of the list, I know not. You can delete a slice. For example, del sys.path[2:5] More about slicing: http://docs.python.org/ref/slicings.html sys.path is a regular list. List

Re: Maths error

2007-01-09 Thread Terry Reedy
Carsten Haese [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] | On Tue, 2007-01-09 at 11:38 +, Nick Maclaren wrote: | As Dan Bishop says, probably not. The introduction to the decimal | module makes exaggerated claims of accuracy, amounting to propaganda. | It is numerically no

Re: Question about using with

2007-01-09 Thread Steven Bethard
Steven W. Orr wrote: From the tutorial, they said that the following construct will automatically close a previously open file descriptor: --- #! /usr/bin/python import sys for nn in range ( 1, len(sys.argv ) ): print arg , nn, value = , sys.argv[nn] with

Re: Yield

2007-01-09 Thread Mathias Panzenboeck
Fredrik Lundh schrieb: Danny Colligan wrote: Carsten mentioned that generators are more memory-efficient to use when dealing with large numbers of objects. Is this the main advantage of using generators? Also, in what other novel ways are generators used that are clearly superior to

Re: Question about using with

2007-01-09 Thread Peter Otten
Steven W. Orr wrote: From the tutorial, they said that the following construct will automatically close a previously open file descriptor: --- #! /usr/bin/python import sys for nn in range ( 1, len(sys.argv ) ): print arg , nn, value = , sys.argv[nn] with

Re: Question about using with

2007-01-09 Thread Duncan Booth
Laszlo Nagy [EMAIL PROTECTED] wrote: 591 ./cat.py cat.py File ./cat.py, line 6 with open(sys.argv[nn]) as f: ^ SyntaxError: invalid syntax 592 This example came from http://docs.python.org/tut/node10.html down in section 8.7 Am I missing something? Are

distutils and ctypes

2007-01-09 Thread [EMAIL PROTECTED]
Hi all, I suspect that I'm doing something stupid, I would like some other opinions though. I'm getting started with ctypes and am trying to use distutils to help build my module. At the moment I simply want distutils to build a shared c library (not a python extension!). Under linux, the

A simple lexer

2007-01-09 Thread Neil Cerutti
I'm a royal n00b to writing translators, but you have to start someplace. In my Python project, I've decided that writing the dispatch code to sit between the Glulx virtual machine and the Glk API will be best done automatically, using the handy prototypes. Below is the prototype of the lexer,

Re: private variables

2007-01-09 Thread Gabriel Genellina
At Tuesday 9/1/2007 04:38, belinda thom wrote: I knew it was a beehive, but I had hoped someone would know which version they were released, so I can put the proper statement into my tutorial (e.g. In version foo, Python provided some support for private variables...). I've been avoiding

Re: Maths error

2007-01-09 Thread Simon Brunning
On 1/9/07, Tim Peters [EMAIL PROTECTED] wrote: Well, just about any technical statement can be misleading if not qualified to such an extent that the only people who can still understand it knew it to begin with 0.8 wink. +1 QTOW -- Cheers, Simon B [EMAIL PROTECTED] --

Re: Maths error

2007-01-09 Thread Robert Kern
Bjoern Schliessmann wrote: Nick Maclaren wrote: No, don't. That is about another matter entirely, It isn't. Actually it really is. That thread is about the difference between str(some_float) and repr(some_float) and why str(some_tuple) uses the repr() of its elements. -- Robert Kern I

Re: distutils and ctypes

2007-01-09 Thread Robert Kern
[EMAIL PROTECTED] wrote: So finally, my question is, is there a way to get distutils to simply build a shared library on windows so that I can use ctypes with them??? Not out-of-box, no. The OOF2 project has added a bdist_shlib command which should do most of what you want, though. It's

Re: distutils and ctypes

2007-01-09 Thread Robert Kern
Robert Kern wrote: [EMAIL PROTECTED] wrote: So finally, my question is, is there a way to get distutils to simply build a shared library on windows so that I can use ctypes with them??? Not out-of-box, no. The OOF2 project has added a bdist_shlib command which should do most of what you

Summarizing data by week

2007-01-09 Thread Mike Orr
What's the best way to summarize data by week? I have a set of timestamped records, and I want a report with one row for each week in the time period, including zero rows if there are weeks with no activity. I was planning to use ISO weeks because datetime has a convenient .isocalendar() method,

Newbie - converting csv files to arrays in NumPy

2007-01-09 Thread oyekomova
I would like to know how to convert a csv file with a header row into a floating point array without the header row. -- http://mail.python.org/mailman/listinfo/python-list

Re: Maths error

2007-01-09 Thread Nick Maclaren
In article [EMAIL PROTECTED], Robert Kern [EMAIL PROTECTED] writes: | | No, don't. That is about another matter entirely, | | It isn't. | | Actually it really is. That thread is about the difference between | str(some_float) and repr(some_float) and why str(some_tuple) uses the repr()

  1   2   >