Re: Microsoft Hatred FAQ

2005-10-31 Thread Mike Meyer
"David Schwartz" <[EMAIL PROTECTED]> writes: > "Mike Meyer" <[EMAIL PROTECTED]> wrote in message > news:[EMAIL PROTECTED] >>> Microsoft's behavior consisted of arguments, that is, did not >>> involve force, the threat of force, fraud, or the threat of >>> fraud. This is perhaps the most vital dist

yapsnmp - on windows

2005-10-31 Thread py
I have installed net-snmp and of course python on windows xp. I downloaded yapsnmp (http://yapsnmp.sourceforge.net/) and I can't seem to use it. It has a swig interface...but I get errors when trying to swig it.. C:\yapsnmp-0.7.8\src>"c:\Program Files\swigwin-1.3.25\swig.exe" -python net-snmp.i

Re: Recursive generators and backtracking search

2005-10-31 Thread Tim Peters
[Talin] > I've been using generators to implement backtracking search for a while > now. Unfortunately, my code is large and complex enough (doing > unification on math expressions) that its hard to post a simple > example. So I decided to look for a simpler problem that could be used > to demonstr

Re: Microsoft Hatred FAQ

2005-10-31 Thread David Schwartz
"Mike Meyer" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Of course, you've dropped the real point, which is your own inabillity > to distinguish between, as you put it, "guns and arguments." You > always act as if every mention of a crime committed by someone other > than micro

Re: Problem With Insert with MySQLdb

2005-10-31 Thread Steve Horsley
David Mitchell wrote: > Hello, > > I am a complete beginner with Python. I've managed to get mod_python up and > running with Apache2 and I'm trying to a simple insert into a table in a > MySQL database. > > I'm using the MySQLdb library for connectivity. I can read from the database > no proble

Re: Python Linked list?

2005-10-31 Thread Michael P. Soulier
On 10/31/05, Simon Roses Femerling <[EMAIL PROTECTED]> wrote: > I'm looking for a linked list class or lib ? Any suggestions ? I'm not sure anyone would bother making one for Python. Why do you feel that you need one? Are dictionaries and lists not enough? Can you not simply make one via referenc

Re: Why the nonsense number appears?

2005-10-31 Thread Steve Horsley
Ben O'Steen wrote: > On Mon, October 31, 2005 10:23, Sybren Stuvel said: >> Ben O'Steen enlightened us with: >>> Using decimal as opposed to float sorts out this error as floats are >>> not built to handle the size of number used here. >> They can handle the size just fine. What they can't handle i

Re: frozenset/subclassing/keyword args

2005-10-31 Thread Bengt Richter
On Mon, 31 Oct 2005 19:31:33 GMT, "Mark E. Fenner" <[EMAIL PROTECTED]> wrote: >Hello all, > >I was migrating some code from sets.ImmutableSet to frozenset and noticed >the following: > >**code >#!/usr/bin/env python > >from sets import ImmutableSet > > >class MSet1(ImmutableSet): >

Re: Microsoft Hatred FAQ

2005-10-31 Thread Mike Meyer
"David Schwartz" <[EMAIL PROTECTED]> writes: > "Mike Meyer" <[EMAIL PROTECTED]> wrote in message > news:[EMAIL PROTECTED] >> Of course, you've dropped the real point, which is your own inabillity >> to distinguish between, as you put it, "guns and arguments." You >> always act as if every mention

looking for a good python module for MS SQL server

2005-10-31 Thread Anat
Hi, Does anyone know a good python mudule that works with MS SQL server? Thanks, Anat -- http://mail.python.org/mailman/listinfo/python-list

Re: looking for a good python module for MS SQL server

2005-10-31 Thread Jarek Zgoda
Anat napisał(a): > Does anyone know a good python mudule that works with MS SQL server? Google will yield something, but I prefer adodbapi over specialized modules. Works good with SQLServer using SSPI auth (others rather not). -- Jarek Zgoda http://jpa.berlios.de/ -- http://mail.python.org/ma

Re: Rename files with numbers

2005-10-31 Thread Micah Elliott
On Oct 31, [EMAIL PROTECTED] wrote: > but my focus is to learn how to acess a folder and rename all files in > this folder. This is a little more flexible than my last post, and it does the whole job:: #! /usr/bin/env python import glob, os, string def fix_ugly_song_names(songdir, b

Re: Using graphviz to visualize trace.py output, anybody?

2005-10-31 Thread svenn . are
I am referring to the trace.py which comes with python2.3 which is installed on Panther by default. (I found it with 'locate trace.py' after reading about its existence here) I was thinking in the direction of your suggestion 2) but before I reinvent the wheel, I would like to know if someone has

Re: Rename files with numbers

2005-10-31 Thread Micah Elliott
On Oct 31, Micah Elliott wrote: > Now I need to go beautify my collection. :-) While a fun exercise, there are probably already dozens (or thousands?) of utilities in existence that do this and much more. -- _ _ ___ |V|icah |- lliott http://micah.elliott.name [EMAIL PROTECTED] " " """

Re: Microsoft Hatred FAQ

2005-10-31 Thread David Schwartz
"Mike Meyer" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Another straw man. I'm not trying to oblitarate that difference No matter how many times I quote to you where you specifically do exactly this, you insist you aren't. Yes, you are. You equate metaphorical force wit

Re: Microsoft Hatred FAQ

2005-10-31 Thread Mouser
It's good to see that tilting at windmills hasn't gone out of style since Cervantes' time. [[hehehehehe...]] -- http://mail.python.org/mailman/listinfo/python-list

[Ann] RO package 2005-10-31

2005-10-31 Thread Russell E. Owen
RO package 2005-10-31 is now available from What is it? A package of python utilities I wrote to support a telescope control interface. RO has a strong emphasis on the Tkinter GUI library, networking, astronomy and cross-platform support (uni

cx_Oracle, is anything selected?

2005-10-31 Thread Damjan
Is there a way to see if the SELECT in cx_Oracle didn't return anything? I want to optimize the situation when the number of selected rows is zero. Is select count(*) the only option, seems inefficient? -- damjan -- http://mail.python.org/mailman/listinfo/python-list

Storing empties (was Re: Automatic binding of **kwargs to variables)

2005-10-31 Thread Aahz
In article <[EMAIL PROTECTED]>, Alex Martelli <[EMAIL PROTECTED]> wrote: > >the canonical idiom when you need such distinction is: > >_not_there = object() >def foo(bar=_not_there, baz=_not_there, bap=_not_there): >if bar is _not_there: ... > >Other unique objects can be substituted for the 'se

Re: Microsoft Hatred FAQ

2005-10-31 Thread Mike Meyer
"David Schwartz" <[EMAIL PROTECTED]> writes: >> I'm trying to find out why you regularly ignore that difference for >> everyone but MS. > To substantiate that claim, you'd have to point to some cases where I > talk about something other than MS. You do that *every time* someone compares MS wi

Re: Microsoft Hatred FAQ

2005-10-31 Thread David Schwartz
"Mike Meyer" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > "David Schwartz" <[EMAIL PROTECTED]> writes: >>> I'm trying to find out why you regularly ignore that difference for >>> everyone but MS. >> To substantiate that claim, you'd have to point to some cases where I >> talk

Re: Tkinter problem

2005-10-31 Thread dale cooper
Thanks, but I've got another question: can't find Tcl configuration script "tclConfig.sh" This is what I received trying to install TkBLT. What is tclConfig.sh? I did installed tcl/tk 8.4.9-3 as I mentioned before, I tried to find this file, but I don't have it in my filesystem. How to get it? -

Re: Arguments for button command via Tkinter?

2005-10-31 Thread Ron Adam
Steve Holden wrote: > Francesco Bochicchio wrote: > >> Il Mon, 31 Oct 2005 06:23:12 -0800, [EMAIL PROTECTED] ha scritto: >> >> >>> And yet the stupidity continues, right after I post this I finnally >>> find an answer in a google search, It appears the way I seen it is to >>> create a class for

Re: Microsoft Hatred FAQ

2005-10-31 Thread Mike Meyer
"David Schwartz" <[EMAIL PROTECTED]> writes: > "Mike Meyer" <[EMAIL PROTECTED]> wrote in message > news:[EMAIL PROTECTED] >> "David Schwartz" <[EMAIL PROTECTED]> writes: I'm trying to find out why you regularly ignore that difference for everyone but MS. >>> To substantiate that cla

Re: cx_Oracle, is anything selected?

2005-10-31 Thread Diez B. Roggisch
Damjan wrote: > Is there a way to see if the SELECT in cx_Oracle didn't return anything? > I want to optimize the situation when the number of selected rows is zero. > Is select count(*) the only option, seems inefficient? I don't understand your problem - if your select doesn't return anything,

Re: Microsoft Hatred FAQ

2005-10-31 Thread David Schwartz
"Mike Meyer" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > "David Schwartz" <[EMAIL PROTECTED]> writes: >> You have not disproved that. The closest you've come to a disproof is >> one case where the word "theft" was used (while earlier in the thread, >> actual physical force

Re: MacOS Extension Carbon.File.FSCatalogInfo file sizes should be UInt64?

2005-10-31 Thread donbro
Kevin, Thanks for the tip. I'll post this to the pythonmac-sig mailing list. Don -- http://mail.python.org/mailman/listinfo/python-list

Re: Scanning a file

2005-10-31 Thread Steve Holden
Paul Watson wrote: > Steve Holden wrote: > >>>Since everyone needs this, how about building it in such that files >>>which are closed by the runtime, and not user code, are reported or >>>queryable? Perhaps a command line switch to either invoke or suppress >>>reporting them on exit. >>> >> >>

Reuse base-class implementation of classmethod?

2005-10-31 Thread Giovanni Bajo
Hello, what's the magic needed to reuse the base-class implementation of a classmethod? class A(object): @classmethod def foo(cls, a,b): # do something pass class B(A): @classmethod def foo(cls, a, b): A.foo(cls, a, b) # WRONG! I need to call the base-clas

Re: 'super' to only be used for diamond inheritance problems?

2005-10-31 Thread Giovanni Bajo
Alex Hunsley wrote: > I've seen a few discussion about the use of 'super' in Python, > including the opinion that 'super' should only be used to solve > inheritance diamond problem. (And that a constructor that wants to > call the superclass methods should just call them by name and forget > about

Re: looking for a good python module for MS SQL server

2005-10-31 Thread Brian
I've had good results with adodbapi as well. -- http://mail.python.org/mailman/listinfo/python-list

Re: Asyncore Loop Question

2005-10-31 Thread Steve Holden
John W wrote: > On 10/31/05, Steve Holden <[EMAIL PROTECTED]> wrote: > >>John W wrote: >> >>>Hello, >>> >>>I have a gui application where I am trying to use the asyncore module to >>>gather data from other computers. I am able to connect, but I am getting >>>constant handle_write_event method call

Re: looking for a good python module for MS SQL server

2005-10-31 Thread Steve Holden
Jarek Zgoda wrote: > Anat napisał(a): > > >>Does anyone know a good python mudule that works with MS SQL server? > > > Google will yield something, but I prefer adodbapi over specialized > modules. Works good with SQLServer using SSPI auth (others rather not). > Though it does have problems wi

Re: looking for a good python module for MS SQL server

2005-10-31 Thread Grig Gheorghiu
I successfully used mxODBC () Grig -- http://mail.python.org/mailman/listinfo/python-list

Re: Expanding Python as a macro language

2005-10-31 Thread gmilas
[EMAIL PROTECTED] wrote: > Imagine you want to access a big database from a html server which > only allows you to access such data in chunks pressing a "next" > button on an ASP file. It will take several hours to click the button > and then save the new data supplied by the server! > That is a ty

Re: Scanning a file

2005-10-31 Thread John J. Lee
Paul Watson <[EMAIL PROTECTED]> writes: [...] > How "ill" will things be when large bodies of code cannot run > successfully on a future version of Python or a non-CPython > implementation which does not close files. Might as well put file > closing on exit into the specification. [...] There

Re: MySQLdb and cgi

2005-10-31 Thread robert
I am sending it again, since it didn't appear on the mailing list.  Dear group, I have a problem with importing MySQLdb in a cgi-script. The code fragment at the beginning:   1 #!/usr/bin/env python   2   3 print "Content-Type: text/html\n\n"   4   5 import re   6 import cgi

Re: OpenSSL in Python

2005-10-31 Thread dcrespo
> wouldn't your question then not be more appropriate on the > OpenSSL newsgroup/mailinglist/forum/whatever? Well, I think that because python is the language where I want it to run, I ask it right here. OpenSSL is written in C, so they wont help me. I need the right wrappers to that C library. T

Re: OpenSSL in Python

2005-10-31 Thread dcrespo
First, is the PYTHON OpenSSL C wrapper what I need to get running. Second, if you don't know how to answer, then limit your opinion to yourself. Thanks. -- http://mail.python.org/mailman/listinfo/python-list

Re: Tkinter problem

2005-10-31 Thread jepler
On Mon, Oct 31, 2005 at 03:17:05PM -0800, dale cooper wrote: > Thanks, but I've got another question: > > can't find Tcl configuration script "tclConfig.sh" This file comes from the following package: $ rpm -qf /usr/lib*/tclConfig.sh tcl-devel-8.4.9-3 Fedora generally splits packages which are

Re: Rename files with numbers

2005-10-31 Thread Dudu Figueiredo
Micah, thanks a lot, nice script! But its not completly working, i ran this: fix_ugly_song_names('C:\My Shared Folder\Rubber Soul', 'The Beatles', spacerepl=' ') And the shell prints this: 01 drive my car.mp3 --> The Beatles - Drive My Car.mp3 02 norwegian wood (this bird has flo).mp

Re: Rename files with numbers

2005-10-31 Thread Dudu Figueiredo
Oh, forget what i've just said, i didn't read the __debug__ part. It worked perfectly =] Realy good Python classes! Eduardo Figueiredo http://dudufigueiredo.com -- http://mail.python.org/mailman/listinfo/python-list

Re: Scanning a file

2005-10-31 Thread Paul Rubin
[EMAIL PROTECTED] (John J. Lee) writes: > Closing off this particular one would make it harder to get benefit of > non-C implementations of Python, so it has been judged "not worth it". > I think I agree with that judgement. The right fix is PEP 343. -- http://mail.python.org/mailman/listinfo/pyt

Where to save classes? How to access classes?

2005-10-31 Thread David Mitchell
Hi, I'm trying to get into the object oriented aspect of Python. If I create a custom class (in it's own file), how do I access that class in a function in a different file? In Java there's the notion of a CLASSPATH, where you can tell the compiler to look for classes. Is there something simil

Re: data hiding/namespace pollution

2005-10-31 Thread Steven Bethard
Alex Hunsley wrote: > The two main versions I've encountered for data pseudo-hiding > (encapsulation) in python are: > > method 1: > > _X - (single underscore) - just cosmetic, a convention to let someone > know that this data should be private. > > > method 2: > > __X - (double unders

Re: Where to save classes? How to access classes?

2005-10-31 Thread jepler
This section of the tutorial discusses the module search path: http://docs.python.org/tut/node8.html 6.1.1 The Module Search Path When a module named spam is imported, the interpreter searches for a file named spam.py in the current directory, and then in the list of director

Re: Where to save classes? How to access classes?

2005-10-31 Thread David Wahler
David Mitchell wrote: > Hi, > > I'm trying to get into the object oriented aspect of Python. If I create > a custom class (in it's own file), how do I access that class in a > function in a different file? In Java there's the notion of a CLASSPATH, > where you can tell the compiler to look for cla

Does Asyncore Send require newline?

2005-10-31 Thread John W
Hello, I have a test environment that consists of a server and an application that opens an asyncore socket and communicates with it. In my application, on the handle_write call, if I do not append a "\n" to my message the server never gets the message.  If I do append it, the server can read the

Re: Reuse base-class implementation of classmethod?

2005-10-31 Thread David Wahler
Giovanni Bajo wrote: > Hello, > > what's the magic needed to reuse the base-class implementation of a > classmethod? > > class A(object): >@classmethod >def foo(cls, a,b): ># do something >pass > > class B(A): > @classmethod > def foo(cls, a, b): > A.foo(cl

Re: Does Asyncore Send require newline?

2005-10-31 Thread Steve Holden
John W wrote: > Hello, > > I have a test environment that consists of a server and an application that > opens an asyncore socket and communicates with it. > > In my application, on the handle_write call, if I do not append a "\n" to my > message the server never gets the message. If I do append

Re: Does Asyncore Send require newline?

2005-10-31 Thread John W
Hi Steve, Here is what I have for my server (This code is really not that pretty, I apologize): import socket import SocketServer class CommonServer(SocketServer.ThreadingTCPServer):     def server_bind(self):     """Override server_bind to store the server name."""     SocketServer.TCPS

Re: Reuse base-class implementation of classmethod?

2005-10-31 Thread Bengt Richter
On Tue, 01 Nov 2005 00:24:37 GMT, "Giovanni Bajo" <[EMAIL PROTECTED]> wrote: >Hello, > >what's the magic needed to reuse the base-class implementation of a >classmethod? > >class A(object): > @classmethod > def foo(cls, a,b): > # do something > pass > >class B(A): >@classmethod

Re: Why the nonsense number appears?

2005-10-31 Thread Dan Bishop
Steve Horsley wrote: > Ben O'Steen wrote: > > On Mon, October 31, 2005 10:23, Sybren Stuvel said: > >> Ben O'Steen enlightened us with: > >>> Using decimal as opposed to float sorts out this error as floats are > >>> not built to handle the size of number used here. > >> They can handle the size ju

how to import extension module from embedding application on aix5

2005-10-31 Thread zhang xiaoning
Hi, I download and extract python-2.4.2 source code for unix, and then, build and install it on aix5, the configure option I used is: ./configure --enable-shared --disable-ipv6 --prefix=/usr/python then, I run: make and make install because I want to embed python in other language, so I contin

Re: Rename files with numbers

2005-10-31 Thread Dave Benjamin
On Mon, 31 Oct 2005, Micah Elliott wrote: > On Oct 31, Micah Elliott wrote: >> Now I need to go beautify my collection. :-) > > While a fun exercise, there are probably already dozens (or > thousands?) of utilities in existence that do this and much more. Seconded. I initially considered writing

Re: Scanning a file

2005-10-31 Thread Alex Martelli
Steve Holden <[EMAIL PROTECTED]> wrote: ... > > The runtime knows it is doing it. Please allow the runtime to tell me > > what it knows it is doing. Thanks. > > In point oif fact I don't believe the runtime does any such thing > (though I must admit I haven't checked the source, so you may p

Re: Storing empties

2005-10-31 Thread Alex Martelli
Aahz <[EMAIL PROTECTED]> wrote: > In article <[EMAIL PROTECTED]>, > Alex Martelli <[EMAIL PROTECTED]> wrote: > > > >the canonical idiom when you need such distinction is: > > > >_not_there = object() > >def foo(bar=_not_there, baz=_not_there, bap=_not_there): > >if bar is _not_there: ... > > >

Re: Looking for info on Python's memory allocation

2005-10-31 Thread Edvard Majakari
Steven D'Aprano <[EMAIL PROTECTED]> writes: > I'm discussing memory allocation techniques with somebody, and I'm trying to > find a quote from -- I think -- Tim Peters where he discusses the way Python > allocates memory when you append to lists. In basic terms, he says that every > time you try t

Forced to Embed?

2005-10-31 Thread Lloyd
Hi After researching on Extending and Embedding it appears Extending is favoured greatly over Embedding. I've tested Boost::Python successfully in a test project but have run into an issue. I have about 10 shared libraries that up until now have only been statically linked into an application

Re: looking for a good python module for MS SQL server

2005-10-31 Thread Frank Millman
Anat wrote: > Hi, > Does anyone know a good python mudule that works with MS SQL server? > Thanks, > Anat I use the odbc module from pywin32. I believe that it is not 100% DB-API 2.0 compliant, but it works fine for me. It has the advantage that if you have installed pywin32 (which is advisable o

Re: Forced to Embed?

2005-10-31 Thread Miki Tebeka
Hello Lloyd, > I have about 10 shared libraries that up until now have only been > statically linked into an application and used from C++. I'd like to > expose a lot of this functionality as different Python modules ( core, > network, input, etc ), however the interdependency between the libra

Re: Rich __repr__

2005-10-31 Thread Erik Max Francis
Ben Finney wrote: > The builtin types have __repr__ attributes that return something nice, > that looks like the syntax one would use to create that particular > instance. > > The default __repr__ for custom classes show the fully-qualified class > name, and the memory address of the instance. >

<    1   2