Re: MySQLdb and ordering of column names in list returned by keys() w/ a DictCursor

2009-07-02 Thread Wells Oliver
I can suss out. Any ideas? Thanks! >> >> (cursor being a MySQLdb.cursors.DictCursor object.) >> > > My guess is you're experiencing the fact that dicts are unordered by nature > which allows it to return in any order it likes (usually per the internal > representation/storage). > > -tkc > > > > -- Wells Oliver we...@submute.net -- http://mail.python.org/mailman/listinfo/python-list

interactive fiction in Python?

2009-07-15 Thread George Oliver
hi, I'm just curious who might be working on interactive fiction modules in the style of Inform or TADS for Python. I've seen a few threads on this list [1] (among many that mention IF tangentially), and there are old projects like PUB and PAWS. There are some newer potential projects such as Curve

Question regarding style/design..

2009-07-17 Thread Wells Oliver
scope such that the preference shifts from the former to the latter? I understand the use of the __name__ == 'main' convention for building unit tests, but I'm mixed on using it in scripts/small applications. Thanks for any thoughts! -- Wells Oliver we...@submute.net -- http://mail.python.org/mailman/listinfo/python-list

RPY2 examples?

2009-07-22 Thread Wells Oliver
I am trying to find examples using RPY2 to render R graphs to PNG/PDF/etc. The only things I can find use rpy 1.x. Any references? Thanks! -- Wells Oliver we...@submute.net -- http://mail.python.org/mailman/listinfo/python-list

Sorting dict by value w/ operator.itemgetter- using key name?

2009-07-30 Thread Wells Oliver
is email. Any tips? -- Wells Oliver we...@submute.net -- http://mail.python.org/mailman/listinfo/python-list

Ordering of dict keys & values

2009-08-03 Thread Wells Oliver
on the value being in the same index as its corresponding key? -- Wells Oliver we...@submute.net -- http://mail.python.org/mailman/listinfo/python-list

embedding python ImportError: libpyglib PyExc_ImportError

2010-10-28 Thread Oliver Marks
Hi i am a new member on this list and thought if some people may be able to enlighten me to the error below ? I am running 64 bit ubuntu 10.10 and python 2.6 in case there are know issues with this setup, basically i am embedding python inside a c application i managed to get this to work i can c

Embedded python issue with gtk

2010-11-10 Thread Oliver Marks
I have already emailed about this issue, but have still not got any where. I have reduced the plugin down to its bare minimum it simple loads the the python interpreter and imports gtk library. If i do this outside the embedded python it imports and i can use the gtk library, so why does it not w

Re: Letting a Python application phone home

2006-07-15 Thread Nils Oliver Kröger
Am Freitag, 14. Juli 2006 15:26 schrieb Dieter Vanderelst: This is surely possible. You need to define a protocol for the communication between client and server. As you are planning to send data over the internet you should build it on top of tcp. Look at the python module "socket" resp. "Sock

Re: calling a class instance of function

2006-12-21 Thread Nils Oliver Kröger
Hi, Methods i.e functions bound to a class instance (or object) the self argument in their definition: [code] class pid: def add(self, toadd): pass #or some sensible code [/code] If you want to define a method without that implicit self argument you'll have to make this method a st

Re: what is wrong with my code?

2006-12-21 Thread Nils Oliver Kröger
Hi, this is the line that breaks your code: def progressTable(progress_table, action, task, pid=len(progress_table) your parameter progress_table is known inside the function, not inside its definition. So "pid=len(progress_table)" won't do. If you really think that it is possible that pid is

Re: Python is removing my quotes!

2007-08-21 Thread Nils Oliver Kröger
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Robert Dailey schrieb: > Thank you for your response. The back slashes work! It's a bit annoying; but > I have Microsoft to thank for that. It's not Microsoft, you would experience the same problems under any Unix I know of. At least the bash treats q

Re: How to optimise this code?

2007-08-21 Thread Nils Oliver Kröger
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 David N Montgomery schrieb: > class testCase: > def __init__(self, tc): > if tc == 1:self.testCase1() > if tc == 2:self.testCase2() > if tc == 3:self.testCase3() > if tc == 4:self.testCase4() > if tc == 5:sel

Re: Threads and racing conditions

2007-08-22 Thread Nils Oliver Kröger
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Flavio Preto schrieb: > Hi, > > I have a doubt. Supose that i have the minimun class below: > > class db: > def __init__(self): > self.db = {} > def read(self, key): > return self.db[key] > def write(self, key, value): >

Re: Class destruction

2007-08-22 Thread Nils Oliver Kröger
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Robert Dailey schrieb: > Hi, > > I'm wondering where the most appropriate location is to cleanup class > objects. For example, i have a file handle as an instance attribute in one > of my classes and I need to call f.close() on it when the class objec

Re: pdf to text

2007-01-25 Thread Nils Oliver Kröger
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 have a look at the pdflib (www.pdflib.com). Their Text Extraction Toolkit might be what you are looking for, though I'm not sure whether you can use it detached from the pdflib itself. hth Nils tubby schrieb: > I know this question comes up a lot, s

I need a crack for pyext1.2.5 plugin

2007-02-18 Thread Oliver Sosa Cano
Hi pythoneros. I'm a cuban guy interested in python and I need the crack of an Eclipse plugin: pyext 1.2.5 Thanks very much cheers Oliver Sosa -- http://mail.python.org/mailman/listinfo/python-list

RE: I need a crack for pyext1.2.5 plugin

2007-02-18 Thread Oliver Sosa Cano
alternative... Thanks (sorry my english) On Feb 18, 8:07 pm, "Oliver Sosa Cano" <[EMAIL PROTECTED]> wrote: > Hi pythoneros. I'm a cuban guy interested in python and I need the crack of an Eclipse plugin: pyext 1.2.5 > > Thanks very much > > cheers >

Re: Cant run application as ./myapp.py

2008-03-03 Thread Nils Oliver Kröger
s I have other applications which > run just fine using the ./somthing.py syntax. Is there any reason why > this doesn’t work? > > > > Cheers, > > > > Robert > -BEGIN PGP SIGNATURE- iD8DBQFHzALBzvGJy8WEGTcRAtE8AJ4jGFTjZ8G8ayZM2AUcLcArnF5d1QCdH0gj

Re: Exception or not

2008-03-03 Thread Nils Oliver Kröger
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hello, I don't think it is a good pattern because you are kind of mixing exceptions with return codes which makes the code a lot less readable later on. I personally would strongly opt for return codes in this case as one would intuitively expect a f

Re: Python Query: Related to locking a resource in a multithreaded environment

2008-08-19 Thread Nils Oliver Kröger
--- > > -- > http://mail.python.org/mailman/listinfo/python-list -BEGIN PGP SIGNATURE----- iD8DBQFIqxfCzvGJy8WEGTcRApe+AJ9MNqWI9FOsJIKuTKxy8ZNSGYTy2gCdHtGc clDPMMAPRoIxsBvVm4ygi6U= =vIPW -END PGP SIGNATURE- begin:vcard fn;quoted-printable:Nils Oliver Kr=C3=B6ger n;quoted-printable:Kr=C3=B6ger;Nils Oliver email;internet:[EMAIL PROTECTED] version:2.1 end:vcard -- http://mail.python.org/mailman/listinfo/python-list

Imports and dot-notation

2023-08-09 Thread Oliver Schinagl via Python-list
Dear list, First a disclaimer, I am a python novice ;) so apologies beforehand for any incorrect terms and use thereof :) I have a question about the preferred/pythonic way dealing with imports. But let me start by giving a little bit of an example (which lead me to this question). Lookin

Re: test-ignore

2024-02-15 Thread Tony Oliver via Python-list
On Thursday 15 February 2024 at 21:16:22 UTC, E.D.G. wrote: > Test - ignore February 15, 2024 > > Test post to see if my Newsgroup post program is working. Aim your test messages at alt.test, please. -- https://mail.python.org/mailman/listinfo/python-list

<    1   2