Re: xmlrcp - how to marshall objects

2010-02-05 Thread Adam Tauno Williams
On Fri, 2010-02-05 at 17:03 +0100, Jean-Michel Pichavant wrote: > Deos anyone knows where to find an code sample describing how to > implement the interface to marshall one object into XMLRPC compliant > structures ? > I googled without any success, and what google does not find does not exist. >

Re: xmlrcp - how to marshall objects

2010-02-05 Thread Adam Tauno Williams
On Fri, 2010-02-05 at 18:24 +0100, Jean-Michel Pichavant wrote: > Jean-Michel Pichavant wrote: > > Deos anyone knows where to find an code sample describing how to > > implement the interface to marshall one object into XMLRPC compliant > > structures ? > > I googled without any success, and what

Re: Pickle in a POST/GET request give EOFError

2010-11-17 Thread Adam Tauno Williams
string you can base64 encode it (using the base64 module). -- Adam Tauno Williams -- http://mail.python.org/mailman/listinfo/python-list

Re: Pickle in a POST/GET request give EOFError

2010-11-18 Thread Adam Tauno Williams
e. JSON is best for communicating simple data to stupid clients [web browsers]. JSON doesn't know about dates, it doesn't know about string vs. unicode, etc... -- Adam Tauno Williams -- http://mail.python.org/mailman/listinfo/python-list

Re: do something every n seconds

2010-11-25 Thread Adam Tauno Williams
scheduler' issue your application will ever have. <http://packages.python.org/APScheduler/> -- Adam Tauno Williams LPIC-1, Novell CLA <http://www.whitemiceconsulting.com> OpenGroupware, Cyrus IMAPd, Postfix, OpenLDAP, Samba -- http://mail.python.org/mailman/listinfo/python-list

Re: IMAP support

2010-11-30 Thread Adam Tauno Williams
On Tue, 2010-11-30 at 13:03 -0800, pakalk wrote: > Please, give me an example of raw query to IMAP server? I'm not certain what you mean by "raw query". > And why do you focus on "Nevermind is so ekhm... nevermind... "??

Re: SAX unicode and ascii parsing problem

2010-12-01 Thread Adam Tauno Williams
On Tue, 2010-11-30 at 12:28 -0800, goldtech wrote: > I'm trying to parse an xml file using SAX. About half-way through a > file I get this error: > Traceback (most recent call last): > File "C:\Python26\Lib\site-packages\pythonwin\pywin\framework > \scriptutils.py", line 325, in RunScript >

Re: is id(self) constant over an object lifetime ?

2010-12-03 Thread Adam Tauno Williams
On Fri, 2010-12-03 at 14:44 +0100, Jean-Michel Pichavant wrote: > Hello fellows, > I would need a unique internal identifier to an object. Can I use the > object python id ? > class Foo: > def getUniqueIdentifier(): >return id(self) > This id needs to be unique and constant over the p

Re: Task Engine Framework?

2010-12-07 Thread Adam Tauno Williams
On Mon, 2010-12-06 at 15:11 -0800, Nate wrote: > Hello, > I'm in the process of developing a task engine / workflow module for > my Python application and I'm wondering if anyone knows of existing > code that could be used or adapted. Since I know that's far too > generic a question, let me share

Re: class browser

2010-12-08 Thread Adam Tauno Williams
On Wed, 2010-12-08 at 13:18 +0530, Rustom Mody wrote: > If I have a medium to large python code base to browse/study, what are > the class browsers available? Monodevelop has good Python support which includes a working Python class browser for Python projects & solutions.

Re: class browser

2010-12-13 Thread Adam Tauno Williams
On Sun, 2010-12-12 at 05:01 -0800, rusi wrote: > On Dec 8, 11:24 pm, Adam Tauno Williams > wrote: > > On Wed, 2010-12-08 at 13:18 +0530, Rustom Mody wrote: > > > If I have a medium to large python code base to browse/study, what are > > > the class browsers avail

PyUNO [Was: Read / Write OpenOffice SpreadSheet ?]

2010-12-17 Thread Adam Tauno Williams
On Fri, 2010-12-17 at 10:19 +0100, Torsten Mohr wrote: > Thanks, i read about it but as i understood it, UNO needs Python 2.3.x and > i'd like to base on something actual. I do not *believe* this is true. for instance is Python 2.6 and uses PyUNO. I

Re: Trying to parse a HUGE(1gb) xml file

2010-12-20 Thread Adam Tauno Williams
On Mon, 2010-12-20 at 11:34 -0800, spaceman-spiff wrote: > Hi c.l.p folks > This is a rather long post, but i wanted to include all the details & > everything i have tried so far myself, so please bear with me & read > the entire boringly long post. > I am trying to parse a ginormous ( ~ 1gb) xml f

Re: Trying to parse a HUGE(1gb) xml file

2010-12-20 Thread Adam Tauno Williams
On Mon, 2010-12-20 at 12:29 -0800, spaceman-spiff wrote: > I need to detect them & then for each 1, i need to copy all the > content b/w the element's start & end tags & create a smaller xml > file. Yep, do that a lot; via iterparse. > 1. Can you point me to some examples/samples of using SAX, >

Re: issubclass(dict, Mapping)

2010-12-22 Thread Adam Tauno Williams
On Wed, 2010-12-22 at 14:20 +, kj wrote: > In a message (<4cf97c94$0$30003$c3e8da3$54964...@news.astraweb.com>) > on a different thread, Steven D'Aprano tells me: > >I suspect you're trying to make this more complicated than it actually > >is. You keep finding little corner cases that expose i

Re: Hosting a Python based TCP server

2010-12-23 Thread Adam Tauno Williams
On Thu, 2010-12-23 at 04:40 -0800, bobicanprogram wrote: > On Dec 23, 7:01 am, Oltmans wrote: > > Hi all, > > I'm writing a very small TCP server(written in Python) and now I want > > to host it on some ISP so that it can be accessed anywhere from the > > Internet. I've never done that before so I

Re: lxml etree question

2010-12-24 Thread Adam Tauno Williams
On Fri, 2010-12-24 at 20:48 +0530, Nitin Pawar wrote: > On Fri, Dec 24, 2010 at 8:40 PM, Jim wrote: > Hello, I wonder if someone knows about lxml.etree and > namespaces? Yes, and don't. > I want to build an ElementTree where some of the sub-elements have > attributes that serial

Re: Trying to parse a HUGE(1gb) xml file

2010-12-25 Thread Adam Tauno Williams
"Steve Holden" wrote: >On 12/23/2010 4:34 PM, Stefan Sonnenberg-Carstens wrote: >> For large datasets I always have huge question marks if one says >"xml". >> But I don't want to start a flame war. >I agree people abuse the "spirit of XML" using it to transfer gigabytes >of data, How so? I th

Re: Trying to parse a HUGE(1gb) xml file

2010-12-25 Thread Adam Tauno Williams
On Sat, 2010-12-25 at 22:34 +, Nobody wrote: > On Sat, 25 Dec 2010 14:41:29 -0500, Roy Smith wrote: > >> XML works extremely well for large datasets. > One advantage it has over many legacy formats is that there are no > inherent 2^31/2^32 limitations. Many binary formats inherently cannot > su

Re: User input masks - Access Style

2010-12-27 Thread Adam Tauno Williams
On Sun, 2010-12-26 at 20:37 -0800, flebber wrote: > Is there anyay to use input masks in python? Similar to the function > found in access where a users input is limited to a type, length and > format. Typically this is handled by a call

Re: Trying to parse a HUGE(1gb) xml file

2010-12-27 Thread Adam Tauno Williams
On Mon, 2010-12-27 at 22:55 +0100, Stefan Behnel wrote: > Alan Meyer, 27.12.2010 21:40: > > On 12/21/2010 3:16 AM, Stefan Behnel wrote: > >> Adam Tauno Williams, 20.12.2010 20:49: > > ... > >>> You need to process the document as a stream of elements; aka SAX.

Re: Digitally Signing a XML Document (using SHA1+RSA or SHA1+DSA)

2010-12-27 Thread Adam Tauno Williams
On Tue, 2010-12-28 at 03:25 +0530, Anurag Chourasia wrote: > Hi All, > I have a requirement to digitally sign a XML Document using SHA1+RSA > or SHA1+DSA > Could someone give me a lead on a library that I can use to fulfill > this requirement? Never used it though. > The

Re: Python - NAWIT / Community

2010-12-28 Thread Adam Tauno Williams
On Tue, 2010-12-28 at 02:26 -0800, flebber wrote: > Can't help thinking they open sourced Pydev so they could bench it. So? That isn't uncommon at all; to Open Source when you've moved on. > I started thinking that the only consistent env each python person has > is idle as it ships in the ins

Re: Python - NAWIT / Community

2010-12-28 Thread Adam Tauno Williams
On Tue, 2010-12-28 at 03:24 -0800, flebber wrote: > On Dec 28, 10:16 pm, Adam Tauno Williams > wrote: > > On Tue, 2010-12-28 at 02:26 -0800, flebber wrote: > > > Is pydev actively being developed and for who? SPE is a great idea but > > > is Stan still developing?

Re: Trying to parse a HUGE(1gb) xml file

2010-12-28 Thread Adam Tauno Williams
On Tue, 2010-12-28 at 07:08 +0100, Stefan Behnel wrote: > Roy Smith, 28.12.2010 00:21: > > To go back to my earlier example of > > FALSE > > using 432 bits to store 1 bit of information, stuff like that doesn't > > happen in marked-up text documents. Most of the file is CDATA (do they > >

Re: etl tool!!!!!

2010-12-28 Thread Adam Tauno Williams
rge.net/lists/listinfo/coils-project> -- Adam Tauno Williams LPIC-1, Novell CLA <http://www.whitemiceconsulting.com> OpenGroupware, Cyrus IMAPd, Postfix, OpenLDAP, Samba -- http://mail.python.org/mailman/listinfo/python-list

Re: How to initialize each multithreading Pool worker with an individual value?

2010-12-30 Thread Adam Tauno Williams
On Thu, 2010-12-30 at 08:01 -0800, Aahz wrote: > In article , > Valery Khamenya wrote: > >However it doesn't look possible to use it to initialize each Pool's > >worker with some individual value (I'd wish to be wrong here) > >So, how to initialize each multithreading Pool worker with the > >indi

Re: Streaming templating languages for use as WSGI body.

2011-01-06 Thread Adam Tauno Williams
On Wed, 2011-01-05 at 14:56 -0800, Alice Bevan–McGregor wrote: > Howdy! > I'm trying to find a templating engine whose templates can be consumed > directly as a WSGI response body iterable. So far I haven't been very > successful with Google; the engines I've found universally generate a > mono

Re: Streaming templating languages for use as WSGI body.

2011-01-06 Thread Adam Tauno Williams
On Thu, 2011-01-06 at 11:07 -0800, Alice Bevan–McGregor wrote: > On 2011-01-06 10:00:39 -0800, Adam Tauno Williams said: > > > With HTTP/1.0 [and WSGI is HTTP/1.0 only] you have to provide a > > Content-Length header - so you have to generate the entire response at > > o

Re: apscheduler error

2011-01-07 Thread Adam Tauno Williams
On Fri, 2011-01-07 at 17:08 -0800, linna li wrote: > I tried to use the apscheduler and used the sample code below from the > tutorial, but got the error message: Exception in thread APScheduler > (most likely raised during interpreter shutdown). What's going on > here? I really appreciate any hel

Re: Python app dev tools for Gnome?

2011-01-08 Thread Adam Tauno Williams
On Sat, 2011-01-08 at 16:07 +, kj wrote: > There's a zillion utility apps that I've had kicking around in my > head for years, but I've never implemented because I absolutely > hate GUI programming. > But I'm increasingly impressed by the quality, stability, and sheer > number, of Gnome apps t

Re: Print to an IPP printer (pkipplib?)

2011-01-10 Thread Adam Tauno Williams
On Mon, 2011-01-10 at 10:37 -0700, Michael Torrie wrote: > On 10/16/2010 10:49 AM, Adam Tauno Williams wrote: > > I've found the module pkipplib which seems to work well for things like > > interrogating an IPP (CUPS) server. But is there a way to send a print > > job t

Re: Print to an IPP printer (pkipplib?)

2011-01-10 Thread Adam Tauno Williams
On Mon, 2011-01-10 at 10:49 -0800, Emile van Sebille wrote: > On 1/10/2011 10:40 AM Adam Tauno Williams said... > > First I have to make a text stream into a PDF, so I have something to > > send. Surprisingly I've been able to find no code to steal which does > > that

Re: How to Buffer Serialized Objects to Disk

2011-01-12 Thread Adam Tauno Williams
On Wed, 2011-01-12 at 17:29 -0500, Scott McCarty wrote: > Been digging ever since I posted this. I suspected that the response > might be use a database. I use shelve extensively; there are many use-cases where it makes sense. And there are many where a database makes sense. Basically, if I just

Re: how to use priority queue with multiprocessing

2011-01-14 Thread Adam Tauno Williams
On Fri, 2011-01-14 at 10:57 -0800, John Nagle wrote: > On 1/13/2011 9:07 AM, Marco Hornung wrote: > I want to run several jobs on a server. The jobs are being sent by > users. However, all jobs have a different priority, and high-priority > jobs should be processed before any low-priority job ge

Re: examples of realistic multiprocessing usage?

2011-01-16 Thread Adam Tauno Williams
> Instead of explaining my problem and asking for design suggestions, > I'll ask: is there a compendium of realistic Python multiprocessing > examples somewhere? Not that I've ever seen. > Or an open source project to look at? OpenGroupware Coils uses multiprocessing [in conjunction with AMQ]

Re: examples of realistic multiprocessing usage?

2011-01-17 Thread Adam Tauno Williams
On Mon, 2011-01-17 at 13:55 +, Albert van der Horst wrote: > In article , > Philip Semanchuk wrote: > > >I grepped through the code to see that it's using = > >multiprocessing.Listener. I didn't go any further than that because our = > >project is BSD licensed and the license for Gluino is

Re: examples of realistic multiprocessing usage?

2011-01-21 Thread Adam Tauno Williams
On Fri, 2011-01-21 at 03:20 -0800, Adam Skutt wrote: > On Jan 20, 11:51 pm, Albert van der Horst > wrote: > > This is what some people want you to believe. Arm twisting by > > GPL-ers when you borrow their ideas? That is really unheard of. > Doesn't matter, you're still legally liable if your wor

Re: IDLE: A cornicopia of mediocrity and obfuscation.

2011-02-01 Thread Adam Tauno Williams
On Tue, 2011-02-01 at 04:38 -0800, rantingrick wrote: > On Feb 1, 4:20 am, flebber wrote: > > Sorry Rick too boringtrying to get bored people to bite at your > > ultra lame post yawn... > Well reality and truth both has a tendency to be boring. Even more true of pointless and drawn-o

Re: Idea for removing the GIL...

2011-02-08 Thread Adam Tauno Williams
On Tue, 2011-02-08 at 01:39 -0800, Vishal wrote: > Is it possible that the Python process, creates copies of the > interpreter for each thread that is launched, and some how the thread > is bound to its own interpreter ? > and it "may" also allow the two threads to run in parallel, assuming > the

Re: Idea for removing the GIL...

2011-02-08 Thread Adam Tauno Williams
On Tue, 2011-02-08 at 11:52 -0500, Roy Smith wrote: > In article , > Robert Kern wrote: > > Unlike a UNIX fork, CreateProcess() does not have the same copy-on-write > > semantics for initializing the memory of the new process. If you want to > > pass > > data to the children, the data must be

Re: wsgi, ajax, and multiple requests

2011-02-09 Thread Adam Tauno Williams
On Wed, 2011-02-09 at 14:31 +0200, Frank Millman wrote: > I am dabbling with writing an ajax-style app. On occasion, I want to send > more than one message from the client to the server. It is important that > the server processes the messages in the same order that they are generated. > I have

Re: encoding

2011-02-14 Thread Adam Tauno Williams
On Mon, 2011-02-14 at 13:03 -0500, Verde Denim wrote: > On Mon, Feb 14, 2011 at 12:46 PM, MRAB > wrote: > On 14/02/2011 17:10, Verde Denim wrote: > All > I'm a bit new to py coding and need to setup some code to > encode/decode > base 128. > Anyone here have some info they can poi

Re: Write web apps in Python?

2010-04-20 Thread Adam Tauno Williams
On Mon, 2010-04-19 at 15:15 +0200, Bruno Desthuilliers wrote: > Gilles Ganault a écrit : > > On Thu, 15 Apr 2010 12:41:56 +0200, Bruno Desthuilliers > > wrote: > >> The PHP execution model (mostly based on CGI FWIW) tends to be a bit > >> unpractical for non-trivial applications since you have to

Re: Write web apps in Python?

2010-04-20 Thread Adam Tauno Williams
On Tue, 2010-04-20 at 17:05 +0200, Bruno Desthuilliers wrote: > Adam Tauno Williams a écrit : > > On Mon, 2010-04-19 at 15:15 +0200, Bruno Desthuilliers wrote: > >> Gilles Ganault a écrit : > >>> On Thu, 15 Apr 2010 12:41:56 +0200, Bruno Desthuilliers > >>&

Re: Write web apps in Python?

2010-04-21 Thread Adam Tauno Williams
On Wed, 2010-04-21 at 10:28 +0200, Bruno Desthuilliers wrote: > Bryan a écrit : > > > > I think I see what you mean > > Err... > > > -- correct me if I'm wrong: > > You are, sorry !-) > > > You want to > > keep complex application data structures around between requests. > > Nope. I want to

Re: when should I explicitly close a file?

2010-04-22 Thread Adam Tauno Williams
On Thu, 2010-04-22 at 12:53 +1200, Lawrence D'Oliveiro wrote: > In message <4bc9aad...@dnews.tpgi.com.au>, Lie Ryan wrote: > > Since in python nothing is guaranteed about implicit file close ... > It is guaranteed that objects with a reference count of zero will be > disposed. In my experiments, t

Re: when should I explicitly close a file?

2010-04-23 Thread Adam Tauno Williams
On Fri, 2010-04-23 at 16:29 +1200, Lawrence D'Oliveiro wrote: > In message , Chris > Rebert wrote: > > On Wed, Apr 21, 2010 at 5:53 PM, Lawrence D'Oliveiro wrote: > >> In message <4bc9aad...@dnews.tpgi.com.au>, Lie Ryan wrote: > >>> Since in python nothing is guaranteed about implicit file close .

Re: parsing XML

2010-05-14 Thread Adam Tauno Williams
x27;file', 'rb') doc = etree.parse(handle) handle.close() players = [ ] for player in doc.xpath('/team/player'): players.append({ 'name': player.xpath('./@name')[0], 'age': player.xpath('./@age')[0],

Puzzled by code pages

2010-05-14 Thread Adam Tauno Williams
I'm trying to process OpenStep plist files in Python. I have a parser which works, but only for strict ASCII. However plist files may contain accented characters - equivalent to ISO-8859-2 (I believe). For example I read in the line: >>> handle = open('file.txt', 'rb') >>> data = handle.read()

Re: Puzzled by code pages

2010-05-14 Thread Adam Tauno Williams
On Fri, 2010-05-14 at 20:27 -0400, Adam Tauno Williams wrote: > I'm trying to process OpenStep plist files in Python. I have a parser > which works, but only for strict ASCII. However plist files may contain > accented characters - equivalent to ISO-8859-2 (I believe). For examp

Re: Puzzled by code pages

2010-05-15 Thread Adam Tauno Williams
On Sat, 2010-05-15 at 20:30 +1000, Lie Ryan wrote: > On 05/15/10 10:27, Adam Tauno Williams wrote: > > I'm trying to process OpenStep plist files in Python. I have a parser > > which works, but only for strict ASCII. However plist files may contain > > accented char

Reading XML namespaces

2010-05-15 Thread Adam Tauno Williams
rom lxml. -- Adam Tauno Williams LPIC-1, Novell CLA <http://www.whitemiceconsulting.com> OpenGroupware, Cyrus IMAPd, Postfix, OpenLDAP, Samba -- http://mail.python.org/mailman/listinfo/python-list

Re: Reading XML namespaces

2010-05-15 Thread Adam Tauno Williams
On Sat, 2010-05-15 at 22:29 +0200, Stefan Behnel wrote: > Adam Tauno Williams, 15.05.2010 20:37: > > Say I have an XML document that begins with: > > > > http://www.dsml.org/DSML";> > > How can one access the namespaces define in this node? I've done

Re: Reading XML namespaces

2010-05-15 Thread Adam Tauno Williams
On Sat, 2010-05-15 at 22:58 +0200, Stefan Behnel wrote: > Adam Tauno Williams, 15.05.2010 22:40: > > On Sat, 2010-05-15 at 22:29 +0200, Stefan Behnel wrote: > >> Adam Tauno Williams, 15.05.2010 20:37: > >>> Say I have an XML document that begins with: > &g

Re: Reading XML namespaces

2010-05-15 Thread Adam Tauno Williams
sure I understand your problem. Could you provide some > more details? This is an action in a workflow action (business process modeling). It has an input message of an XML document and a parameter of an xpath; it invokes a subordinate action [think: foreach] for each node resulting from the expre

Re: Reading XML namespaces

2010-05-15 Thread Adam Tauno Williams
On Sat, 2010-05-15 at 23:37 +0200, Martin v. Loewis wrote: > > BTW, I'm still not sure I understand your problem. Could you provide > > some more details? > Wouldn't it be easier if you told the OP how to access the prefix :) > mappings in lxml etree, or, if this was actually not possible, admitt

Re: Reading XML namespaces

2010-05-15 Thread Adam Tauno Williams
On Sun, 2010-05-16 at 02:37 +0200, Martin v. Loewis wrote: > > ??? The namespaces are embedded in the document. Personally I find it > > odd I have to tell xpath about the namespace of the document it is a > > $*&@(*& method of. > How so? Why do you say it's a "method", and why do you say "of"? >

Re: python application question

2010-05-17 Thread Adam Tauno Williams
On Mon, 2010-05-17 at 06:20 -0700, a wrote: > if i want to plot it i have to use something like matplotlib? but > this doesn't come with the standard installation. so if i want > someone else to use this application, do they have to install > matplotlib themselves or is there a better way? Use P

Re: subprocess and gvfs-mount

2010-05-18 Thread Adam Tauno Williams
"Run in > terminal") ... there is no interaction with the user. Which is normal [there is a run-in-terminal check box somewhere?]. If your users are running it in GNOME then you should implement a GUI (PyGTK) for the user interaction [prompting for the password]. Or better use the GN

Re: Multi-Threading in Python

2010-05-18 Thread Adam Tauno Williams
sing separate processes]. IMO, it is hard to screw up as you don't get any shared-state for free. > This has probably been brought up already, so if it has, thanks anyway -- Adam Tauno Williams LPIC-1, Novell CLA <http://www.whitemiceconsulting.com> OpenGroupware, Cyrus IMAPd, Postfix

RE: Multi-Threading in Python

2010-05-18 Thread Adam Tauno Williams
]. IMO, it is hard to > screw > > up as you don't get any shared-state for free. > > > > > This has probably been brought up already, so if it has, thanks > anyway > > > > -- > > Adam Tauno Williams LPIC-1, Novell CLA > &g

Re: Reading data from a Microsoft Access 2003 database

2010-05-19 Thread Adam Tauno Williams
y read a few > > columns of data from some tables. > > this worked like a charm for me: > http://code.activestate.com/recipes/528868-extraction-and-manipulation-class-for-microsoft-ac/ The OP: "I use Ubuntu 64 bit" Does something that contains "import win32com.clien

Re: Reading data from a Microsoft Access 2003 database

2010-05-19 Thread Adam Tauno Williams
> problem, and although there are some references to this problem in the > archives of this group, they are mainly very old and I wonder if there > is anything more recent that members could suggest to me? > Python would be my language of choice, however if someone has any > other sugges

Re: intervall of about 1 second for xmlrpc calls?

2010-05-20 Thread Adam Tauno Williams
ls back to 127.0.0.1. Make sure IPv6 is properly configured/enabled and try the script again. -- Adam Tauno Williams LPIC-1, Novell CLA <http://www.whitemiceconsulting.com> OpenGroupware, Cyrus IMAPd, Postfix, OpenLDAP, Samba -- http://mail.python.org/mailman/listinfo/python-list

Re: intervall of about 1 second for xmlrpc calls?

2010-05-20 Thread Adam Tauno Williams
On Thu, 2010-05-20 at 22:46 +0200, News123 wrote: > Hi Adam, > Adam Tauno Williams wrote: > > On Thu, 2010-05-20 at 03:40 -0700, Thomas Lehmann wrote: > >>> What's wrong? > >> Obviously there's a problem with "localhost". When using the IP of

Re: intervall of about 1 second for xmlrpc calls?

2010-05-21 Thread Adam Tauno Williams
, port), > ExtendedXMLRPCRequestHandler) > self.server.register_function(self.is_even, "is_even") > self.server.register_function(self.stop, "stop_server") > (...) > I would also change all 'localhost' occurences in the code to ip > '

Re: where are the program that are written in python?

2010-05-21 Thread Adam Tauno Williams
the 'packaging' mechanism is less end-user friendly than .NET. I personally would not choose to create an end-user application in Python; but it has become my first choice for server-side development. -- Adam Tauno Williams LPIC-1, Novell CLA <http://www.whitemiceconsulting.com> OpenGroupware, Cyrus IMAPd, Postfix, OpenLDAP, Samba -- http://mail.python.org/mailman/listinfo/python-list

Re: Reading data from a Microsoft Access 2003 database

2010-05-21 Thread Adam Tauno Williams
MS calls. Yes, just like a DB-API provider, except that the 'translation' happens in the ODBC driver. -- Adam Tauno Williams LPIC-1, Novell CLA <http://www.whitemiceconsulting.com> OpenGroupware, Cyrus IMAPd, Postfix, OpenLDAP, Samba -- http://mail.python.org/mailman/listinfo/python-list

Re: creating addon system

2010-05-21 Thread Adam Tauno Williams
("from strip import %s as _x"%striper["striper"]) > string = _x.start(string) This is how I chose to do it. Just walking a list of bundles and discover the available classes [as plugins]. <http://coils.hg.sourceforge.net/hgweb/coils/coils/file/b3538e9fafb9/src/coils

Re: Just To Be Sure...MySQL

2010-05-22 Thread Adam Tauno Williams
tring formatting for SQL commands unless you +1 And they are hideous code. Use an ORM: <http://freshmeat.net/projects/sqlalchemy> > carefully quote and validate the strings. Otherwise your SQL application > is vulnerable to SQL injection attacks. SQL injections are one o

Re: where are the program that are written in python?

2010-05-22 Thread Adam Tauno Williams
th it. But since the framework is essentially general purpose - why not publish the code? I think of my Open Source code as "commercial". -- Adam Tauno Williams LPIC-1, Novell CLA <http://www.whitemiceconsulting.com> OpenGroupware, Cyrus IMAPd, Postfix, OpenLDAP, Samba -- http://mail.python.org/mailman/listinfo/python-list

Re: to prevent reveres engineering for Python

2010-05-25 Thread Adam Tauno Williams
dongle or application to perform the key management. -- Adam Tauno Williams LPIC-1, Novell CLA <http://www.whitemiceconsulting.com> OpenGroupware, Cyrus IMAPd, Postfix, OpenLDAP, Samba -- http://mail.python.org/mailman/listinfo/python-list

Re: to prevent reveres engineering for Python

2010-05-25 Thread Adam Tauno Williams
On Wed, 2010-05-26 at 05:40 +1000, Lie Ryan wrote: > On 05/26/10 01:09, Adam Tauno Williams wrote: > > On Tue, 2010-05-25 at 18:49 +0500, Sandy Ydnas wrote: > >> Agree, reveres engineering is crucial issuer for programming > >> language > >> but every executa

Re: Indentation

2010-05-26 Thread Adam Tauno Williams
noDevelop Highlight text, right-click, click "Indent Selection" in context menu. Or any decent IDE should provide the same kind of thing. <http://monodevelop.com/> -- Adam Tauno Williams LPIC-1, Novell CLA <http://www.whitemiceconsulting.com> OpenGroupware, Cyrus IMAPd, Pos

Re: multiprocessing and accessing server's stdout

2010-05-26 Thread Adam Tauno Williams
chanism to communicate between the client and the server if you need feedback. -- Adam Tauno Williams LPIC-1, Novell CLA <http://www.whitemiceconsulting.com> OpenGroupware, Cyrus IMAPd, Postfix, OpenLDAP, Samba -- http://mail.python.org/mailman/listinfo/python-list

Re: multiprocessing and accessing server's stdout

2010-05-28 Thread Adam Tauno Williams
On Thu, 2010-05-27 at 08:36 -0700, Tim Arnold wrote: > On May 26, 4:52 pm, Adam Tauno Williams > wrote: > > On Wed, 2010-05-26 at 11:47 -0700, Tim Arnold wrote: > > > Hi, > > > I'm using multiprocessing's BaseManager to create a server on one > >

Re: multiprocessing and accessing server's stdout

2010-05-28 Thread Adam Tauno Williams
On Fri, 2010-05-28 at 15:41 +0100, Martin P. Hellwig wrote: > On 05/28/10 13:17, Adam Tauno Williams wrote: > > > You should be able to point it any any file-like object. But, again, > > why? > > If you have the data in the process why send it to stdout and redirect &g

Re: Python vs. Fedora and CentOS

2010-06-01 Thread Adam Tauno Williams
l.iuscommunity.org/pub/ius/stable/Redhat/5/i386/ius-release-1-4.ius.el5.noarch.rpm yum -y install python26 python26-setuptools <http://sourceforge.net/apps/trac/coils/wiki/ProvisioningCentOS5> -- Adam Tauno Williams LPIC-1, Novell CLA <http://www.whitemiceconsulting.com> Ope

Re: Python vs. Fedora and CentOS

2010-06-01 Thread Adam Tauno Williams
supposing that if anyone wanted to do this, the EPEL > folks would be happy to let that person be the package maintainer. rpm -Uvh http://dl.iuscommunity.org/pub/ius/stable/Redhat/5/i386/ius-release-1-4.ius.el5.noarch.rpm yum -y install python26 python26-setuptools -- Adam Tauno Williams LPIC-

Re: Python vs. Fedora and CentOS

2010-06-01 Thread Adam Tauno Williams
On Tue, 2010-06-01 at 10:55 -0600, Michael Torrie wrote: > On 06/01/2010 05:01 AM, Adam Tauno Williams wrote: > > Yes, we install Python 2.6 on CentOS and run a production app on it - no > > problems. > > rpm -Uvh > > http://dl.iuscommunity.org/pub/ius/stable/Redhat/5/i

Re: Python Forum

2010-06-02 Thread Adam Tauno Williams
; in exploring the world of Python and programming > > overall. The main goal of PythonForum.org is to popularize Python by > > welcoming all newcomers. > Newcomers have always been welcomed here. And yet another forum *where > the helpful experts won't post nor correc

Re: Python Forum

2010-06-03 Thread Adam Tauno Williams
e Mono project; which provides both a "web forum" and a mail list interface. <http://lists.ximian.com/mailman/listinfo/mono-list> <http://go-mono.com/forums/> It works very well; and everyone [except the 3 or 4 NNTP hold outs] are happy. -- Adam Tauno Williams LPIC-1, Nove

Re: Python Forum

2010-06-03 Thread Adam Tauno Williams
t. > So the OP's initiative should be an incentive to think on the format > of the interaction between all the range of Python users, from newbees > to gurus. We are in the 2.0 era, with social networks all over the > place using a pleasant interface, I suppose that is a mat

Re: Python Forum

2010-06-03 Thread Adam Tauno Williams
On Thu, 2010-06-03 at 12:35 +0100, Paul Rudin wrote: > Adam Tauno Williams writes: > > Most people use this list via e-mail... > Do you know this to be the case, or is that a guess? Scan through a bunch of threads with show-headers. Watch the User-Agent value (set by the senders c

Re: Python Forum

2010-06-03 Thread Adam Tauno Williams
On Thu, 2010-06-03 at 13:42 +0100, Paul Rudin wrote: > Adam Tauno Williams writes: > > On Thu, 2010-06-03 at 12:35 +0100, Paul Rudin wrote: > >> Adam Tauno Williams writes: > >> > Most people use this list via e-mail... > >> Do you know this to be the case

Re: Python Forum

2010-06-04 Thread Adam Tauno Williams
for you. > Ah, so you feel up to my "xsl for xmlrunner.py" question? I do a fair amount of xslt, but I don't have any idea what xmlrunner.py is. It isn't a GED-level question if it involves specific knowledge about a tertiary product/project. -- Adam Tauno Williams

Re: GUIs - A Modest Proposal

2010-06-05 Thread Adam Tauno Williams
On Sat, 2010-06-05 at 19:22 -0700, ant wrote: > I get the strong feeling that nobody is really happy with the state of > Python GUIs. > WxPython and PyGtk are both powerful, but quirky in different ways. All widget libraries are quirky - because sophisticated user interfaces are complicated. If

Re: store .png file in a script

2010-06-06 Thread Adam Tauno Williams
Just base64 encode the file, store it as a string in the file, and decode it to a byte-stream when you need the image. Everything required to do that is in the standard library. >Would you please let me know that how can I >store a .png or .gif or .jpg file, in a python script? -- http://mail

Re: GUIs - A Modest Proposal

2010-06-06 Thread Adam Tauno Williams
[Monodevelop and it's awesome Gtk# support for Mono/.NET is a good example; the tool makes the toolkit east to use - people go with the toolkit]. -- Adam Tauno Williams LPIC-1, Novell CLA <http://www.whitemiceconsulting.com> OpenGroupware, Cyrus IMAPd, Postfix, OpenLDAP, Samba -- http://mail.python.org/mailman/listinfo/python-list

Re: GUIs - A Modest Proposal

2010-06-06 Thread Adam Tauno Williams
t try several > (as I have - I will admit I didn't try PyQt; > GUI fatigue was setting in by then). This isn't a language issue; it is a tool-chain issue. Get a better IDE. -- Adam Tauno Williams LPIC-1, Novell CLA <http://www.whitemiceconsulting.com> OpenGroupware, Cyrus IMAPd, Postfix, OpenLDAP, Samba -- http://mail.python.org/mailman/listinfo/python-list

Re: GUIs - A Modest Proposal

2010-06-06 Thread Adam Tauno Williams
On Mon, 2010-06-07 at 11:11 +1000, Lie Ryan wrote: > On 06/07/10 10:48, Adam Tauno Williams wrote: > > On Sun, 2010-06-06 at 17:03 -0700, AD. wrote: > >> On Jun 7, 10:55 am, ant wrote: > >>> My concern is simple: I think that Python is doomed to remain a minor >

Re: GUIs - A Modest Proposal

2010-06-07 Thread Adam Tauno Williams
On Mon, 2010-06-07 at 13:19 +1000, Lie Ryan wrote: > On 06/07/10 12:18, Adam Tauno Williams wrote: > > On Mon, 2010-06-07 at 11:11 +1000, Lie Ryan wrote: > >> On 06/07/10 10:48, Adam Tauno Williams wrote: > >>> On Sun, 2010-06-06 at 17:03 -0700, AD. wrote: > &g

Re: GUIs - A Modest Proposal

2010-06-08 Thread Adam Tauno Williams
This statement is devoid of meaning. -- Adam Tauno Williams LPIC-1, Novell CLA <http://www.whitemiceconsulting.com> OpenGroupware, Cyrus IMAPd, Postfix, OpenLDAP, Samba -- http://mail.python.org/mailman/listinfo/python-list

Re: GUIs - A Modest Proposal

2010-06-08 Thread Adam Tauno Williams
issue? Every, or pretty darn close, significant Python application depends on 3rd party modules/component/libraries. -- Adam Tauno Williams LPIC-1, Novell CLA <http://www.whitemiceconsulting.com> OpenGroupware, Cyrus IMAPd, Postfix, OpenLDAP, Samba -- http://mail.python.org/mailman/listinfo/python-list

Re: GUIs - A Modest Proposal

2010-06-08 Thread Adam Tauno Williams
situation as it is. Witness the awesome Zeitgeist application in GNOME 3 - a GUI, developed in *gasp* Python. A real working solution that is part of a major project... H. > So keep the ideas rolling in people. We need to hear from every side > of this forum. Meanwhile everyone who disagrees

Re: GUIs - A Modest Proposal

2010-06-09 Thread Adam Tauno Williams
On Tue, 2010-06-08 at 18:49 -0700, geremy condra wrote: > On Tue, Jun 8, 2010 at 6:20 PM, Adam Tauno Williams > wrote: > > On Tue, 2010-06-08 at 18:12 -0700, geremy condra wrote: > >> > * IronPython relies on the .Net environment for everything > >> Since .Net

Re: GUIs - A Modest Proposal

2010-06-09 Thread Adam Tauno Williams
an't be me - I don't have the clout You get "clout", whatever that means, by writing code. This isn't the senate, it is Open Source. -- Adam Tauno Williams LPIC-1, Novell CLA <http://www.whitemiceconsulting.com> OpenGroupware, Cyrus IMAPd, Postfix, OpenLDAP, Samba -- http://mail.python.org/mailman/listinfo/python-list

Re: GUIs - A Modest Proposal

2010-06-09 Thread Adam Tauno Williams
> The GUI must be small, pythonic, and cross platform. And how many times have I heard that? I develop GUIs... good luck. Come back in ten years when you have some working code. > Tkinter is aimed at the newbie and i would think that was Guido's > original vision. And it's not the worst GUI by

resource module returns just zeros

2010-10-04 Thread Adam Tauno Williams
turns 0 Anyone know what condition causes this? Or is there a better / more-reliable way to check memory utilization of the current process? -- Adam Tauno Williams LPIC-1, Novell CLA <http://www.whitemiceconsulting.com> OpenGroupware, Cyrus IMAPd, Postfix, OpenLDAP, Samba -- http://mail.p

<    1   2   3   >