rsync for python?

2006-12-20 Thread nienfeng
Hi, everyone I want to build rsync server that can run in linux and windows, and configure by python. So I'm looking for something like rsync for python. I find rsync.py and pysync. But rsync.py looks like a client mode, it can't be a rsync server, is it? Can pysync be a rsync server? T

Re: a question on python dict

2006-12-20 Thread could . net
Thank you very much for your explanation! I made a mistake that I said the hash value should be recalculated each time the dict resize, what I wanted to say was that the position of each item should be recalculated. Maybe I should take a look at the source code of python dict some day. I'll some

Re: a question on python dict

2006-12-20 Thread Tim Peters
[EMAIL PROTECTED] > Python dict is a hash table, isn't it? Yup. > I know that hashtable has the concept of "bucket size" and "min bucket > count" stuff, Some implementations of hash tables do. Python's does not. Python's uses what's called "open addressing" instead. > and they should be confi

a question on python dict

2006-12-20 Thread could . net
Python dict is a hash table, isn't it? I know that hashtable has the concept of "bucket size" and "min bucket count" stuff, and they should be configurable so I can set them to the proper value when I know how many items I'm going to handle. If these two values can't be set, the hashtable will gi

Re: your opinion about psycopg vs pygresql

2006-12-20 Thread johnf
Martin P. Hellwig wrote: > Hi all, > > I'm playing a bit with PostgreSQL, in which I've set me the target to > create a python script which with user input creates a new user role and > a database with that owner (connecting to template1 since I know that at > least that db exists). > > Ok so I

Re: tuple.index()

2006-12-20 Thread Hendrik van Rooyen
"Nick Maclaren" <[EMAIL PROTECTED]> wrote: > Not at all. I didn't say that they came in pairs. Consider: > > [str1, str2, agent1, str3, agent2, agent3, agent4, str4, ...] > > See Algol 68 for an example of this. When I looked at the above, I went "tilt" - If you had no a priori knowledge

Re: Fall of Roman Empire

2006-12-20 Thread Hendrik van Rooyen
"Thomas Ploch" <[EMAIL PROTECTED]> wrote: > Ben Finney schrieb: > > "John Machin" <[EMAIL PROTECTED]> writes: > > > >> Ben Finney wrote: > >> > >>> \ "...one of the main causes of the fall of the Roman Empire was | > >>> `\that, lacking zero, they had no way to indicate successfu

Re: merits of Lisp vs Python

2006-12-20 Thread Ken Tilton
[EMAIL PROTECTED] wrote: > Come on; you guys can't just leave this at 999 posts! > Funny you should whine, i was just getting ready to sign off with: I noticed while singing the praises of auto-indentation that there was a shortcoming in The Greatest Feature Known to Editing source code, whic

Re: Support of IPv6 extension headers

2006-12-20 Thread Martin v. Löwis
cychong schrieb: > BTW, is there any way to send the packet with the IPV6 extension header > w/o using sendmsg? That depends on your operating system. Find out whether your operating system supports that; if it does, it is easy to tell whether that is exposed in Python or not. Regards, Martin --

Re: list1.append(list2) returns None

2006-12-20 Thread Steven D'Aprano
On Thu, 21 Dec 2006 16:29:01 +1100, Ben Finney wrote: > Pyenos <[EMAIL PROTECTED]> writes: > >> def enlargetable(table,col): >> return table.append(col) >> >> def removecolfromtable(table,col): >> return table.remove(col) >> >> print enlargetable([[1],[2],[3]],[4]) # returns None >> >> Wh

ANN: M2Crypto 0.17

2006-12-20 Thread Heikki Toivonen
M2Crypto is the most complete Python wrapper for OpenSSL. Homepage: http://wiki.osafoundation.org/bin/view/Projects/MeTooCrypto Changes in 0.17: - setup.py has new test command to run unit tests (requires setuptools) - Added m2urllib2, by James Bowes (python 2.4 and later, at least for now) - Ad

Re: list1.append(list2) returns None

2006-12-20 Thread Ben Finney
Pyenos <[EMAIL PROTECTED]> writes: > def enlargetable(table,col): > return table.append(col) > > def removecolfromtable(table,col): > return table.remove(col) > > print enlargetable([[1],[2],[3]],[4]) # returns None > > Why does it return None instead of [[1],[2],[3],[4]] which I expected?

Re: Does any one know of any good folder/directory modules

2006-12-20 Thread weir
"[EMAIL PROTECTED] 写道: " > Hi > > Does any one know of any good folder/directory modules. I need to be > able to see what files and directories are in a folder, I also need to > be able to see the size of the directory content. > > Thanks This one is more convenient: http://www.jorendorff.com/art

Re: list1.append(list2) returns None

2006-12-20 Thread Gabriel Genellina
> > def enlargetable(table,col): > > return table.append(col) Google for "python pitfalls" -- Gabriel Genellina -- http://mail.python.org/mailman/listinfo/python-list

Re: Using difflib to compare text ignoring whitespace differences

2006-12-20 Thread Gabriel Genellina
On 19 dic, 11:53, Neilen Marais <[EMAIL PROTECTED]> wrote: > Hi > > I'm trying to compare some text to find differences other than whitespace. > I seem to be misunderstanding something, since I can't even get a basic > example to work: > > In [104]: d =difflib.Differ(charjunk=difflib.IS_CHARACTER_J

Re: calling a class instance of function

2006-12-20 Thread Gabriel Genellina
On 20 dic, 21:09, Pyenos <[EMAIL PROTECTED]> wrote: > class pid: > "pid" > def add(original_pid,toadd): > "add pid" > original_pid.append(toadd) > return original_pid For a method, you have to include an *explicit* first parameter (usually called "self") that refers

Re: list1.append(list2) returns None

2006-12-20 Thread Edward Kozlowski
Pyenos wrote: > def enlargetable(table,col): > return table.append(col) > > def removecolfromtable(table,col): > return table.remove(col) > > print enlargetable([[1],[2],[3]],[4]) # returns None > > Why does it return None instead of [[1],[2],[3],[4]] which I expected? return the table.

Re: list1.append(list2) returns None

2006-12-20 Thread Todd Neal
Pyenos wrote: > def enlargetable(table,col): > return table.append(col) > > def removecolfromtable(table,col): > return table.remove(col) > > print enlargetable([[1],[2],[3]],[4]) # returns None > > Why does it return None instead of [[1],[2],[3],[4]] which I expected? append modifies the

Re: Good Looking UI for a stand alone application

2006-12-20 Thread Vincent Delporte
On Tue, 19 Dec 2006 08:15:18 -0600, "Chris Mellon" <[EMAIL PROTECTED]> wrote: >There's a few more caveats I haven't addressed, and there are places >where wx isn't perfect. BTW, do you know of a good article/book on writing cross-platform GUI apps, with recommendations, pitfalls, etc. especially

list1.append(list2) returns None

2006-12-20 Thread Pyenos
def enlargetable(table,col): return table.append(col) def removecolfromtable(table,col): return table.remove(col) print enlargetable([[1],[2],[3]],[4]) # returns None Why does it return None instead of [[1],[2],[3],[4]] which I expected? -- http://mail.python.org/mailman/listinfo/python

Re: calling a class instance of function

2006-12-20 Thread Julio Biason
On Wed, December 20, 2006 22:09, Pyenos wrote: > class pid: > "pid" > def add(original_pid,toadd): [...] > def remove(something_to_remove_from,what): [...] > def modify(source,element,changewiththis): [...] > why do i get an error? Did you copy'n'pasted the code here or typed it d

Re: what is wrong with my code?

2006-12-20 Thread rzed
Pyenos <[EMAIL PROTECTED]> wrote in news:[EMAIL PROTECTED]: > thanks for your point. so because i have said class blah: i must > explicitly say self for every instantiation of object? > No, for every method within the class. Given: class Blah(object): def method1(self,arg1):

Re: what is wrong with my code?

2006-12-20 Thread Carl Banks
Pyenos wrote: > thanks for your point. so because i have said class blah: i must > explicitly say self for every instantiation of object? http://docs.python.org/tut/ Carl Banks -- http://mail.python.org/mailman/listinfo/python-list

Re: pickle fun

2006-12-20 Thread Pyenos
Pyenos <[EMAIL PROTECTED]> writes: > class pickle_service: > import cPickle as p > > # accept list as arg then serialize it to a file > def serialize(some_list,picklefile): > f=file(picklefile,"w") > p.dump(some_list,f) # so dumped this shit to the

Re: what is wrong with my code?

2006-12-20 Thread Pyenos
thanks for your point. so because i have said class blah: i must explicitly say self for every instantiation of object? -- http://mail.python.org/mailman/listinfo/python-list

pickle fun

2006-12-20 Thread Pyenos
class pickle_service: import cPickle as p # accept list as arg then serialize it to a file def serialize(some_list,picklefile): f=file(picklefile,"w") p.dump(some_list,f) # so dumped this shit to the file f.close() # which one

Re: what is wrong with my code?

2006-12-20 Thread Carl Banks
Pyenos wrote: > "Calvin Spealman" <[EMAIL PROTECTED]> writes: > > On 21 Dec 2006 09:16:58 +1100, Pyenos <[EMAIL PROTECTED]> wrote: > > > import cPickle, shelve > > > > > > could someone tell me what things are wrong with my code? > > > > > > class progress: > > > > > > PROGRESS_TABLE_ACTIONS=[

Re: Support of IPv6 extension headers

2006-12-20 Thread cychong
Thanks for your reply. BTW, is there any way to send the packet with the IPV6 extension header w/o using sendmsg? Chae-yong Jean-Paul Calderone wrote: > On 20 Dec 2006 07:07:02 -0800, cychong <[EMAIL PROTECTED]> wrote: > >Hi, > > > >There is no probleming in programming the basic IPv6 socket prog

Re: what is wrong with my code?

2006-12-20 Thread Gabriel Genellina
At Wednesday 20/12/2006 19:16, Pyenos wrote: could someone tell me what things are wrong with my code? My crystal ball is at the repair shop - could you please tell us: - what do you expect the code to do? - what do you get instead? - any compiler error messages you see? - in case of an except

Re: Tkinter, StringVar and dict

2006-12-20 Thread James Stroud
Kevin Walzer wrote: > I'm trying to manage user preferences in a Tkinter application by > initializing some values that can then be configured from a GUI. The > values are set up as a dict, like so: > > self.prefs= { > 'interface': '-en1', > 'verbose': '-v', >

Re: Tkinter, StringVar and dict

2006-12-20 Thread James Stroud
Kevin Walzer wrote: > I'm trying to manage user preferences in a Tkinter application by > initializing some values that can then be configured from a GUI. The > values are set up as a dict, like so: > > self.prefs= { > 'interface': '-en1', > 'verbose': '-v', >

Re: Tkinter, StringVar and dict

2006-12-20 Thread James Stroud
Kevin Walzer wrote: > I'm trying to manage user preferences in a Tkinter application by > initializing some values that can then be configured from a GUI. The > values are set up as a dict, like so: > > self.prefs= { > 'interface': '-en1', > 'verbose': '-v', >

Re: TypeError: unbound method must be called with class instance 1st argument

2006-12-20 Thread void . no . spam . com
Matimus wrote: > > Can someone please explain why I get the following error: > > The following line: > threading.Thread.__init__() > Should be written as: > threading.Thread.__init__(self) Thank you! -- http://mail.python.org/mailman/listinfo/python-list

Re: calling a class instance of function

2006-12-20 Thread Brett Hoerner
Brett Hoerner wrote: > Also, in order to call a function without arguments you still need to > use (), so you probably wanted to use pid.original() in your pid.add > call. Sorry, never mind this bit, I misread the line. But you do probably want to change the class test into a function test. Bret

Re: tuple.index()

2006-12-20 Thread greg
Nick Maclaren wrote: > Not at all. I didn't say that they came in pairs. Consider: > > [str1, str2, agent1, str3, agent2, agent3, agent4, str4, ...] That's homogeneous. Any item of the list can be either a string or an agent, and the only thing the position in the list affects is what orde

Re: TypeError: unbound method must be called with class instance 1st argument

2006-12-20 Thread Matimus
> Can someone please explain why I get the following error: The following line: threading.Thread.__init__() Should be written as: threading.Thread.__init__(self) -- http://mail.python.org/mailman/listinfo/python-list

Re: calling a class instance of function

2006-12-20 Thread Brett Hoerner
Pyenos wrote: > class test(pid): > pid.original=[1,2,3] > pid.toadd=4 > pid.add(pid.original,pid.toadd) # error here says that > # it expects pid instance as first arg > # not a list that it got. > > why do i get an

TypeError: unbound method must be called with class instance 1st argument

2006-12-20 Thread void . no . spam . com
I'm a novice at Python, and found some code samples on how to use threads. My script is being run by a product that contains a Jython interpreter. Can someone please explain why I get the following error: Traceback (innermost last): File "/full/path/to/file/GenerateData.py", line 104, in ? F

Re: what is wrong with my code?

2006-12-20 Thread Pyenos
"Calvin Spealman" <[EMAIL PROTECTED]> writes: > It is hard to determine what is wrong with your code without you > telling anyone why it is you believe something is wrong with it. Did > you get an exception? Did it simply not do what it was expected to do? > There seems to be some apparent indenti

calling a class instance of function

2006-12-20 Thread Pyenos
class pid: "pid" def add(original_pid,toadd): "add pid" original_pid.append(toadd) return original_pid def remove(something_to_remove_from,what): "remove pid" something_to_remove_from.remove(what) return something_to_remove_from def m

Re: def index(self):

2006-12-20 Thread George Sakkis
Gert Cuykens wrote: > > > class HelloWorld(object): > > > @cherrypy.exposed > > > def index(self): > > >return "Hello World" > > do i have to write @cherrypy.exposed before every def or just once for > all the def's ? and why not write something like @index.exposed ? > > in other wo

RE: glibc detected double free or corruption

2006-12-20 Thread Delaney, Timothy (Tim)
Grant Edwards wrote: > When I try to run pycadia > > I get the following error message as soon as I click "start game" > > *** glibc detected *** python: double free or corruption (out): > 0xbff43b10 *** > > Then the program locks up and has to

Re: def index(self):

2006-12-20 Thread Gert Cuykens
> > class HelloWorld(object): > > @cherrypy.exposed > > def index(self): > >return "Hello World" do i have to write @cherrypy.exposed before every def or just once for all the def's ? and why not write something like @index.exposed ? in other words i have no idea what @ actually d

Re: what is wrong with my code?

2006-12-20 Thread Fredrik Lundh
Pyenos wrote: > could someone tell me what things are wrong with my code? do you want a free code review, or do you have problems with the code and just forgot to mention what they are? -- http://mail.python.org/mailman/listinfo/python-list

Re: what is wrong with my code?

2006-12-20 Thread Calvin Spealman
It is hard to determine what is wrong with your code without you telling anyone why it is you believe something is wrong with it. Did you get an exception? Did it simply not do what it was expected to do? There seems to be some apparent indenting problems, but maybe that is just from pushing it thr

Re: merits of Lisp vs Python

2006-12-20 Thread jayessay
"Anders J. Munch" <[EMAIL PROTECTED]> writes: > jayessay wrote: > > Please note: GC is not part of CL's definition. It is likely not part > > of any Lisp's definition (for reasons that should be obvious), and for > > the same reasons likely not part of any language's definition. > > Really? R

Tkinter, StringVar and dict

2006-12-20 Thread Kevin Walzer
I'm trying to manage user preferences in a Tkinter application by initializing some values that can then be configured from a GUI. The values are set up as a dict, like so: self.prefs= { 'interface': '-en1', 'verbose': '-v', 'fontname': 'Courier',

glibc detected double free or corruption

2006-12-20 Thread Grant Edwards
When I try to run pycadia I get the following error message as soon as I click "start game" *** glibc detected *** python: double free or corruption (out): 0xbff43b10 *** Then the program locks up and has to be killed with a SIGKILL. pycadia is a

what is wrong with my code?

2006-12-20 Thread Pyenos
import cPickle, shelve could someone tell me what things are wrong with my code? class progress: PROGRESS_TABLE_ACTIONS=["new","remove","modify"] DEFAULT_PROGRESS_DATA_FILE="progress_data" PROGRESS_OUTCOMES=["pass", "fail"] def unpickleProgressTable(pickled_progress_data_file):

ANN: Pygments 0.6 "Zimtstern" released

2006-12-20 Thread Georg Brandl
I'm happy to announce the second public release of Pygments, the generic Python syntax highlighter. Download it from , or look at the demonstration at . News The new features since 0.5.1 include: * New lexers: S

Re: perl better than python for users with disabilities?

2006-12-20 Thread Steven D'Aprano
On Thu, 21 Dec 2006 00:11:10 +0800, Dan Jacobson wrote: > Can I feel even better about using perl vs. python, as apparently > python's dependence of formatting, indentation, etc. vs. perl's > "(){};" etc. makes writing python programs perhaps very device > dependent. I can't think of what sort of

Re: [ANN] PyInstaller 1.3 released

2006-12-20 Thread Robin Becker
Giovanni Bajo wrote: > yeah that's pretty cryptic. It's a known bug which I need to come around > and fix it. Anyway, the message itself is harmless: if the program then > exits, there is *another* problem. > > If you want to help with that, you could enable the console+debug mode > an

Re: [ANN] PyInstaller 1.3 released

2006-12-20 Thread Robin Becker
Giovanni Bajo wrote: > yeah that's pretty cryptic. It's a known bug which I need to come around > and fix it. Anyway, the message itself is harmless: if the program then > exits, there is *another* problem. > > If you want to help with that, you could enable the console+debug mode > an

Re: using methods base64 module in conjunction with Crypto.Hash.SHA256

2006-12-20 Thread Klaas
[EMAIL PROTECTED] wrote: > I am attempting to implement a process, and I'm pretty sure that a > major roadblock is that I do not understand the nomenclature. The > specs indicate that the goal is to calculate a message digest using an > SHA-256 algorithm. There are 2 examples included with the s

new Python-Ideas mailing list

2006-12-20 Thread [EMAIL PROTECTED]
At Guido's suggestion, a new mailing list has been created named Python-Ideas (http://mail.python.org/mailman/listinfo/python-ideas). This list is meant as a place for speculative, pie-in-the-sky language design ideas to be discussed and honed to the point of practically being a PEP before being pr

Re: [ANN] PyInstaller 1.3 released

2006-12-20 Thread Giovanni Bajo
Robin Becker wrote: > I just tried this on something which we currently use py2exe+nsis to > package and it certainly seems to produce a small exe, but when run I > see a cryptic message on two message boxes > > ! msvcr71.dll > > ! could not be extracted > > the program then exits. yeah that

Re: merits of Lisp vs Python

2006-12-20 Thread Rob Thorpe
Anders J. Munch wrote: > Rob Thorpe wrote: > > Anders J. Munch wrote: > >> Really? So how do you write a portable program in CL, that is to > >> run for unbounded lengths of time? > > > > You can't. > > > > The thing about the spec not defining GC is almost a bit of humour. > > No-one woul

Re: TypeError: cannot concatenate 'str' and 'NoneType' objects

2006-12-20 Thread Carsten Haese
On Wed, 2006-12-20 at 11:33 -0800, Mark Peters wrote: > Warning: I know nothing about the Python ArcGIS stuff. > > The first thing that jumps out at me is your while condition. You are > testing "Townshps" when it seems from the code that you should be > testing "Townshp". However, the typical P

Re: error with IDLE on debian

2006-12-20 Thread johnzenger
Just a guess, but I think you need to be using at least Python 2.4 if you are going to use IDLE version 2.4.4-2. On Dec 20, 1:16 pm, altern <[EMAIL PROTECTED]> wrote: > Hi > > when i try to run IDLE on my debian laptop I get this error. > > $ idle > Traceback (most recent call last): >File "/u

Re: TypeError: cannot concatenate 'str' and 'NoneType' objects

2006-12-20 Thread thompson . marisa
I've had a lot of replies suggesting different things. These are the results: When I change while Townshps !="": to while Townshp is not None: and when I change while Townshps !="": to for Townshp in iter(gp.ListFeatureClasses().next, None): They both work perfectly, and it solved my problem.

Re: perl better than python for users with disabilities?

2006-12-20 Thread johnzenger
Blind programmers can use braille displays, which let them perceive indentation as easily as sighted programmers can. http://xrl.us/tydj As for people with physical disabilities that have trouble typing, a Python-aware editor does the identation for you, so all you have to do is type a colon and

Re: merits of Lisp vs Python

2006-12-20 Thread Anders J. Munch
Rob Thorpe wrote: > Anders J. Munch wrote: >> Really? So how do you write a portable program in CL, that is to >> run for unbounded lengths of time? > > You can't. > > The thing about the spec not defining GC is almost a bit of humour. > No-one would use an implementation with no GC. > >

Re: TypeError: cannot concatenate 'str' and 'NoneType' objects

2006-12-20 Thread Bruno Desthuilliers
Bruno Desthuilliers a écrit : > [EMAIL PROTECTED] a écrit : > > 4/ the Python 'for' loop is meant to iterate over an iterable and taking > care of boundaries, so you'd be better using it: > > townships = gp.ListFeatureClasses ("*") > for township in townships: > doSomethingWith(township) Actu

Re: TypeError: cannot concatenate 'str' and 'NoneType' objects

2006-12-20 Thread Bruno Desthuilliers
[EMAIL PROTECTED] a écrit : > Hi. > > I'm extremely new to Python and programming as a whole. I have written > a python script with the assistance of ESRI ArcGIS 9.2, which uses > Python 2.4.1, however, it gives me this error when I try to run it. Please post the full traceback. It's meant to he

Re: TypeError: cannot concatenate 'str' and 'NoneType' objects

2006-12-20 Thread Fredrik Lundh
Mark Peters wrote: > However, the typical Python way to iterate through a list for be to > use a for loop. Perhaps replace the while statement with: > for Townshp in Townshps: > and remove the "Townshp = Townshps.next()" lines that assumes that the feature class list is actually a Python iterab

Re: TypeError: cannot concatenate 'str' and 'NoneType' objects

2006-12-20 Thread Fredrik Lundh
Fredrik Lundh wrote: > while Townshps is not None: or rather, while Townshp is not None: since that's the variable you're using later on. -- http://mail.python.org/mailman/listinfo/python-list

Re: TypeError: cannot concatenate 'str' and 'NoneType' objects

2006-12-20 Thread Carsten Haese
On Wed, 2006-12-20 at 20:22 +0100, Fredrik Lundh wrote: > [EMAIL PROTECTED] wrote: > > > I'm extremely new to Python and programming as a whole. I have written > > a python script with the assistance of ESRI ArcGIS 9.2, which uses > > Python 2.4.1, however, it gives me this error when I try to ru

Re: merits of Lisp vs Python

2006-12-20 Thread Rob Thorpe
Pascal Bourguignon wrote: > "Rob Thorpe" <[EMAIL PROTECTED]> writes: > > Anders J. Munch wrote: > >> jayessay wrote: > >> > Please note: GC is not part of CL's definition. It is likely not part > >> > of any Lisp's definition (for reasons that should be obvious), and for > >> > the same reasons

Re: TypeError: cannot concatenate 'str' and 'NoneType' objects

2006-12-20 Thread Mark Peters
> # Begin going through the loop > Townshp = Townshps.next() > while Townshps !="": > #Set the output name to be the same as input > outName = outputPath + "/" + Townshp + "land" + ".img" > Output_table = outputPath + "/" + Townshp + "table" + ".dbf" > #For each extract by Mask >

Re: TypeError: cannot concatenate 'str' and 'NoneType' objects

2006-12-20 Thread Fredrik Lundh
[EMAIL PROTECTED] wrote: > I'm extremely new to Python and programming as a whole. I have written > a python script with the assistance of ESRI ArcGIS 9.2, which uses > Python 2.4.1, however, it gives me this error when I try to run it. > I've already posted at ESRI support, and I was hoping that

Re: MySQLdb, lots of columns and newb-ness

2006-12-20 Thread Andrew Sackville-West
On Wed, Dec 20, 2006 at 09:22:59AM +0100, Fredrik Lundh wrote: > Andrew Sackville-West wrote: > > > I've also tried building tuples and lists and then using this > > > > cursor.execute("insert into daily values (%s)", values) > > > > with no luck. it appears to me that I have to put in all 132 '

Re: Boost Python tutorial needs MSVC?

2006-12-20 Thread Max Wilson
Cancel that--I found the answer. http://groups.google.com/group/boost-list/browse_frm/thread/5a17077679a33dca/7360f2038d6e6cca?lnk=gst&q=bjam+mingw&rnum=3#7360f2038d6e6cca Short answer: bjam.exe should not be in /bin or /usr/bin because MinGW treats programs in there differently. In my case I simp

TypeError: cannot concatenate 'str' and 'NoneType' objects

2006-12-20 Thread thompson . marisa
Hi. I'm extremely new to Python and programming as a whole. I have written a python script with the assistance of ESRI ArcGIS 9.2, which uses Python 2.4.1, however, it gives me this error when I try to run it. I've already posted at ESRI support, and I was hoping that Python people could help me

Boost Python tutorial needs MSVC?

2006-12-20 Thread Max Wilson
Hi, Has anyone here built Boost.Python modules under MinGW? I'm trying to build the Boost.Python tutorial under MinGW and getting an error that says it depends on MSVC, which puzzles me because Boost built using g++. Here's some of my output: [EMAIL PROTECTED] /c/Boost/libs/python/example/tutoria

Re: MySQLdb, lots of columns and newb-ness

2006-12-20 Thread Andrew Sackville-West
On Wed, Dec 20, 2006 at 07:00:38AM -0800, Ant wrote: > > > On Dec 20, 5:20 am, Andrew Sackville-West <[EMAIL PROTECTED]> > wrote: > > > >>> values = ", ".join([escapeAndQuote(f[:-2]) for f in fields]) > > Obviously this is the appropriate choice since this is a database app. > In general the str

Re: What am I supposed to do with an egg?!

2006-12-20 Thread Morpheus
On Wed, 20 Dec 2006 13:35:26 +, Duncan Booth wrote: > "F. GEIGER" <[EMAIL PROTECTED]> wrote: > >> Sorry for not being clear. I did exec easy_install - no errors so far. >> But the egg was still there. I'd expected, that it was converted into >> .py-files somehow, which could be imported by my

Re: Need Simple Way To Determine If File Is Executable

2006-12-20 Thread Fredrik Lundh
Sebastian 'lunar' Wiesner wrote: no, I'm showing that a local file marked as executable overrides a shared one, even if the local file isn't actually an executable. >>> >>> Only if you have your system set up badly. The current directory >>> should not be in the search path, and it esp

Re: perl better than python for users with disabilities?

2006-12-20 Thread Georg Brandl
Thomas Ploch schrieb: > Martin P. Hellwig schrieb: >> Quite punny title though I assume you are really serious and mean people >> with a physical disability, I won't comment any further on this subject >> :-), if I already offended anyone, please excuse me, since I'm original >> from Germany I'm

Re: Need Simple Way To Determine If File Is Executable

2006-12-20 Thread Sebastian 'lunar' Wiesner
Fredrik Lundh <[EMAIL PROTECTED]> schrieb > Paul Arthur wrote: > >>> no, I'm showing that a local file marked as executable overrides a >>> shared one, even if the local file isn't actually an executable. >> >> Only if you have your system set up badly. The current directory >> should not be in

Re: merits of Lisp vs Python

2006-12-20 Thread Pascal Bourguignon
"Rob Thorpe" <[EMAIL PROTECTED]> writes: > Anders J. Munch wrote: >> jayessay wrote: >> > Please note: GC is not part of CL's definition. It is likely not part >> > of any Lisp's definition (for reasons that should be obvious), and for >> > the same reasons likely not part of any language's def

Re: PIL broken on win32?

2006-12-20 Thread Fredrik Lundh
Chris Mellon wrote: > PIL 1.1.5 and 1.1.6 both seem to be broken, in different ways, on win32. > > 1.1.5 will load and access images, but ImageDraw fails: > i = Image.open("good.jpg") > d = ImageDraw.Draw(i) > d.line((10,10,20,20)) > Traceback (most recent call last): > File "", line 1, in ? >

Re: Does any one know of any good folder/directory modules

2006-12-20 Thread Thomas Ploch
[EMAIL PROTECTED] schrieb: > Hi > > Does any one know of any good folder/directory modules. I need to be > able to see what files and directories are in a folder, I also need to > be able to see the size of the directory content. > > Thanks > You should have a look here: http://docs.python.org

Re: merits of Lisp vs Python

2006-12-20 Thread [EMAIL PROTECTED]
Anders J. Munch wrote: > jayessay wrote: > > Please note: GC is not part of CL's definition. It is likely not part > > of any Lisp's definition (for reasons that should be obvious), and for > > the same reasons likely not part of any language's definition. > > Really? So how do you write a por

error with IDLE on debian

2006-12-20 Thread altern
Hi when i try to run IDLE on my debian laptop I get this error. $ idle Traceback (most recent call last): File "/usr/bin/idle", line 5, in ? main() File "idlelib/PyShell.py", line 1359, in main File "idlelib/FileList.py", line 44, in new File "idlelib/PyShell.py", line 105, in __

Does any one know of any good folder/directory modules

2006-12-20 Thread moishyyehuda
Hi Does any one know of any good folder/directory modules. I need to be able to see what files and directories are in a folder, I also need to be able to see the size of the directory content. Thanks -- http://mail.python.org/mailman/listinfo/python-list

PIL broken on win32?

2006-12-20 Thread Chris Mellon
PIL 1.1.5 and 1.1.6 both seem to be broken, in different ways, on win32. 1.1.5 will load and access images, but ImageDraw fails: i = Image.open("good.jpg") d = ImageDraw.Draw(i) d.line((10,10,20,20)) Traceback (most recent call last): File "", line 1, in ? File "C:\Python24\Lib\site-packages\

Re: merits of Lisp vs Python

2006-12-20 Thread Rob Thorpe
Anders J. Munch wrote: > jayessay wrote: > > Please note: GC is not part of CL's definition. It is likely not part > > of any Lisp's definition (for reasons that should be obvious), and for > > the same reasons likely not part of any language's definition. > > Really? So how do you write a port

Re: Need Simple Way To Determine If File Is Executable

2006-12-20 Thread Fredrik Lundh
Paul Arthur wrote: >> no, I'm showing that a local file marked as executable overrides a >> shared one, even if the local file isn't actually an executable. > > Only if you have your system set up badly. The current directory should > not be in the search path, and it especially shouldn't have

Re: perl better than python for users with disabilities?

2006-12-20 Thread Thomas Ploch
Martin P. Hellwig schrieb: > Quite punny title though I assume you are really serious and mean people > with a physical disability, I won't comment any further on this subject > :-), if I already offended anyone, please excuse me, since I'm original > from Germany I'm not supposed to be funny.

Re: perl better than python for users with disabilities?

2006-12-20 Thread Michele
What about indenting with a single space? This does not seem a problem to me, even on tiny tiny screens =) On 12/20/06, Dan Jacobson <[EMAIL PROTECTED]> wrote: Can I feel even better about using perl vs. python, as apparently python's dependence of formatting, indentation, etc. vs. perl's "(){}

Re: perl better than python for users with disabilities?

2006-12-20 Thread Martin P. Hellwig
Dan Jacobson wrote: > Can I feel even better about using perl vs. python, as apparently > python's dependence of formatting, indentation, etc. vs. perl's > "(){};" etc. makes writing python programs perhaps very device > dependent. Whereas perl can be written on a tiny tiny screen, and can > withst

your opinion about psycopg vs pygresql

2006-12-20 Thread Martin P. Hellwig
Hi all, I'm playing a bit with PostgreSQL, in which I've set me the target to create a python script which with user input creates a new user role and a database with that owner (connecting to template1 since I know that at least that db exists). Ok so I installed PostGreSQL and pygresql since

tkFileDialog closes main application

2006-12-20 Thread mdmdmd
Hello, I wish to collect 4 files from a user. So I have decided to use tkFileDialog askopenfilename. My problem is that after a few file selections the root window is destroyed (the whole program just dissappears) I have created a simple example and was able to reproduce the same thing with

Re: Fall of Roman Empire

2006-12-20 Thread Sion Arrowsmith
Ben Finney <[EMAIL PROTECTED]> wrote: >"John Machin" <[EMAIL PROTECTED]> writes: >> Ben Finney wrote: >> > \ "...one of the main causes of the fall of the Roman Empire was | >> > `\that, lacking zero, they had no way to indicate successful | >> > _o__) termination of

Re: merits of Lisp vs Python

2006-12-20 Thread Anders J. Munch
jayessay wrote: > Please note: GC is not part of CL's definition. It is likely not part > of any Lisp's definition (for reasons that should be obvious), and for > the same reasons likely not part of any language's definition. Really? So how do you write a portable program in CL, that is to r

perl better than python for users with disabilities?

2006-12-20 Thread Dan Jacobson
Can I feel even better about using perl vs. python, as apparently python's dependence of formatting, indentation, etc. vs. perl's "(){};" etc. makes writing python programs perhaps very device dependent. Whereas perl can be written on a tiny tiny screen, and can withstand all kinds of users with va

Re: Fall of Roman Empire

2006-12-20 Thread Georg Brandl
Felix Benner schrieb: >> Sorry, somehow had to do this. Please slap me (i like it, don't worry) >> if it's totally stupid >> >> > > s totally stupid! You forgot the main function! (not to mention you > returned universe instead of everything) > > static int main(int argc, char **argv) { >

[ANNOUNCE] Thirty-fifth release of PythonCAD now available

2006-12-20 Thread Art Haas
Hi. I'm pleased to announce the thirty-fifth development release of PythonCAD, a CAD package for open-source software users. As the name implies, PythonCAD is written entirely in Python. The goal of this project is to create a fully scriptable drafting program that will match and eventually exceed

Re: Any easy-to-use email send module?

2006-12-20 Thread ina
I put this together for some automated testing I do with an email system. I hope it is of help to you. It dosn't do cc and bcc In this version but it would be simple to add to the eMessage headder. http://phlik.ishpeck.net/index.php?P=b1114201575phlik -- http://mail.python.org/mailman/listinfo

Re: Fall of Roman Empire

2006-12-20 Thread Thomas Ploch
Felix Benner schrieb: > Thomas Ploch schrieb: >>> Ben Finney schrieb: "John Machin" <[EMAIL PROTECTED]> writes: > Ben Finney wrote: > >> \ "...one of the main causes of the fall of the Roman Empire was | >> `\that, lacking zero, they had no way to indicate

  1   2   >