Re: Prefered install method?

2007-01-25 Thread Gabriel Genellina
At Friday 26/1/2007 04:27, Tina I wrote: So my question is; What is the preferred/ common way to install a python application so it's not really distro specific? And are there any good resources on this on the web? distutils, included in the standard Python library. You surely have the docs i

Re: how to unistall a Python package?

2007-01-25 Thread Colin J. Williams
With Windows, a few packages, eg. PythonWin, also modify the registry. numpy, the elaboration of numarray/numeric, and PythonWin have RemoveXXX.exe in C:\Python25. I don't know whether this is the standard approach. There doesn't seem to be a reference to Removal in the distutils document. Co

Re: The reliability of python threads

2007-01-25 Thread Hendrik van Rooyen
"Carl J. Van Arsdall" <[EMAIL PROTECTED]> wrote: > Right, I wasn't coming here to get someone to debug my app, I'm just > looking for ideas. I constantly am trying to find new ways to improve > my software and new ways to reduce bugs, and when i get really stuck, > new ways to track bugs down

Re: Which BASTARD involved in Valerie Plame case? FINALLY EXPOSED

2007-01-25 Thread thermate
Libby trial pulls back White House curtain Friday, January 26, 2007 By Dana Milbank, The Washington Post WASHINGTON -- Memo to Tim Russert: Dick Cheney thinks he controls you. This delicious morsel about the "Meet the Press" host and the vice president was part of the extensive dish that Cathie

Prefered install method?

2007-01-25 Thread Tina I
Another noob question: I have written my first linux application that might actually be of interest to others. Just for fun I also wrote an install script that put the files in the common directories for my distro (Debian). That is in /usr/local/. (This particular program can be run directly fro

Re: Module for SVG?

2007-01-25 Thread Jean-François Piéronne
Sebastian Bassi a écrit : > Hello, > > I found http://www2.sfk.nl/svg as a Python module for writing SVG. > Last update was in 2004 and I am not sure if there is something > better. > Any recommendation for generating SVG graphics? I have ported to Python the Ruby SVG graph generation library htt

problems with pyzeroconf and linux

2007-01-25 Thread Simo Hosio
Hi all, I am trying to get pyzeroconf (http://sourceforge.net/projects/pyzeroconf) running on my machine but having trouble... Running the Zeroconf.py file seems to register the service, but is unable to find it. (same situation than in http://www.nabble.com/pyzeroconf-on-linux...-t481215.html

Re: doctest problem with null byte

2007-01-25 Thread Tim Peters
[Stuart D. Gathman] > I am trying to create a doctest test case for the following: > > def quote_value(s): > """Quote the value for a key-value pair in Received-SPF header > field if needed. No quoting needed for a dot-atom value. > > >>> quote_value(r'abc\def') > '"abcdef"

Which BASTARD involved in Valerie Plame case? FINALLY EXPOSED

2007-01-25 Thread thermate
http://www.latimes.com/news/nationworld/nation/la-na-libby26jan26,1,2730931.story?coll=la-headlines-nation Aide testifies Cheney helped effort to discredit Wilson By Richard B. Schmitt, Times Staff Writer 5:27 PM PST, January 25, 2007 WASHINGTON -- Vice President Dick Cheney and his former chief

Re: Python does not play well with others

2007-01-25 Thread John Nagle
Paul Rubin wrote: > John Nagle <[EMAIL PROTECTED]> writes: > >>That's the problem. We now have four SSL implementations for >>Python, none of which let you do all the things OpenSSL can do. > > > I'm aware of some OpenSSL wrappers plus TLSlite. Am I missing a > couple more? I guess maybe

Re: assertions to validate function parameters

2007-01-25 Thread Steven D'Aprano
On Thu, 25 Jan 2007 16:54:05 +, Matthew Wilson wrote: > Lately, I've been writing functions like this: > > def f(a, b): > > assert a in [1, 2, 3] > assert b in [4, 5, 6] > > The point is that I'm checking the type and the values of the > parameters. If somebody passes in a == MyNum

Re: Pyparsing - Dealing with a Blank Value

2007-01-25 Thread Paul McGuire
On Jan 25, 7:13 pm, "Steve" <[EMAIL PROTECTED]> wrote: > Hi All, > > I've picked up thePyParsingmodule and am trying to figure out how to > do a simple parsing of some HTML source code. My specific problem is > dealing with an element that is blank. > I'd also suggest use the makeHTMLTags helper

Re: Pyparsing - Dealing with a Blank Value

2007-01-25 Thread Paul McGuire
On Jan 25, 7:13 pm, "Steve" <[EMAIL PROTECTED]> wrote: > Hi All, > > I've picked up thePyParsingmodule and am trying to figure out how to > do a simple parsing of some HTML source code. My specific problem is > dealing with an element that is blank. > > > Any assistance would be greatly apprecia

I made a mistake in selecting America as a land of Freedom, EINSTEIN

2007-01-25 Thread thermate
I made a mistake in selecting America as a land of Freedom, EINSTEIN "Insanity: Doing the same thing over and over again, and expecting different results".-Albert Einstein "It is my conviction that killing under the cloak of war is nothing but an act of murder." -Albert Einstein "I came to

Re: Http listener

2007-01-25 Thread Gabriel Genellina
At Thursday 25/1/2007 23:32, [EMAIL PROTECTED] wrote: Am trying to find any resources that helps me to do write the Http Listener.. Use SimpleHTTPServer; see its source code for an example. -- Gabriel Genellina Softlab SRL _

Bush Ignores True Cost of Iraq war

2007-01-25 Thread thermate
http://www.gnn.tv/threads/22972/Bush_Ignores_True_Cost_of_Iraq_war Bush Ignores True Cost of Iraq war Asset H12937 Posted By GWHunta In his State of the Union address, President Bush makes the case for his plan to escalate the war in Iraq. He paints the potential costs of pulling out of Iraq in s

Http listener

2007-01-25 Thread elrondrules
Hi Am new to python and I am trying to do the following: 1. Write a Http Listener (listening on a particular port) that subscribes to a process. 2. This process posts events as xml docs. 3. Parse the xml docs as and when they are posted. Am trying to find any resources that helps me to do write

How do I build python with debug info? (and python module load questions)

2007-01-25 Thread sndive
I want to step into PyImport_ImportModule("my_foo") that's failing despite the my_foo.py being in the current directory. (PyRun_SimpleFileEx works on the exact same file). How would I run configure to build libpython with -g? I wonder if I should just keep using PyRun_SimpleFileEx. I want to be a

Lython

2007-01-25 Thread faulkner
I have Lython! I want to make sure that anybody else who wants it can access it, so, unless Mr. Egan objects, I'm hosting it here: http://home.comcast.net/~faulkner612/programming/python/lython.zip I had to patch it a bit because the number of arguments to compiler.ast.Function.__init__ changed bet

doctest problem with null byte

2007-01-25 Thread Stuart D. Gathman
I am trying to create a doctest test case for the following: def quote_value(s): """Quote the value for a key-value pair in Received-SPF header field if needed. No quoting needed for a dot-atom value. >>> quote_value(r'abc\def') '"abcdef"' >>> quote_value('abc..def')

Help extracting info from HTML source ..

2007-01-25 Thread s. d. rose
Hello All. I am learning Python, and have never worked with HTML. However, I would like to write a simple script to audit my 100+ Netware servers via their web portal. I was reading Chapter 8 of Dive into Python, which deals with this topic. In the web portal of the server, there is a sect

Re: stop script w/o exiting interpreter

2007-01-25 Thread Miki
Hello Alan, > I'm fairly new to Python and I've lately been running a script at > the interpreter while working on it. Sometimes I only want to > run the first quarter or half etc. What is the "good" way to do this? If you want to exit from the program then "raise SystemExit" is what you want. I

Re: Getting started with Crystal Reports...little help in the far court.

2007-01-25 Thread Carl Trachte
Marc, I've been able to get some Business Objects COM functionality in Business Objects 6.5 (the logging in functionality I have to do through a call to an Excel VBA macro; otherwise things appear to work for what I'm doing). Unfortunately, I don't have experience with Python in Business

Re: Pyparsing - Dealing with a Blank Value

2007-01-25 Thread Gabriel Genellina
At Thursday 25/1/2007 22:13, Steve wrote: I've picked up the PyParsing module and am trying to figure out how to do a simple parsing of some HTML source code. My specific problem is dealing with an element that is blank. Sorry for not answering your question exactly, but I'd use BeautifulSo

Re: ANN: Dejavu 1.5.0RC1

2007-01-25 Thread fumanchu
On Jan 25, 10:10 am, "olive" <[EMAIL PROTECTED]> wrote: > Do you consider a StorageManagers for Oracle ? Yes, and in fact, I already have a ticket for it: http://projects.amor.org/dejavu/ticket/59. I've downloaded Oracle 10.2g XE and played with it a little, but hit some snags right away due to it

Re: difflib qualm

2007-01-25 Thread Gabriel Genellina
At Thursday 25/1/2007 21:49, Larry Bates wrote: Gabriel Genellina wrote: > At Wednesday 24/1/2007 23:05, Sick Monkey wrote: > >> I am trying to write a python script that will compare 2 files which >> contains names (millions of them). >> >> More specifically, I have 2 files (Files1.txt and Files

Re: Right-Justifying Numeric Output

2007-01-25 Thread Gabriel Genellina
At Thursday 25/1/2007 19:34, Rich Shepard wrote: > assuming max size = 10 > > #with spaces >>> '% 10d' % 11 > '11' > #with zeros >>> '%010d' % 11 > '11' Thank you very much! I didn't see this in any of my Python books or on the Web. http://docs.python.org/lib/typesseq-strin

Pyparsing - Dealing with a Blank Value

2007-01-25 Thread Steve
Hi All, I've picked up the PyParsing module and am trying to figure out how to do a simple parsing of some HTML source code. My specific problem is dealing with an element that is blank. from pyparsing import * import sys integer = Word("0123456789") trStart = Literal("").suppress() trEnd

Re: My python programs need a GUI, wxPython or PyQt4?

2007-01-25 Thread Sean Schertell
That's really exciting! Thanks for the tip. Sean On Jan 25, 2007, at 9:42 AM, Robert Kern wrote: > Sean Schertell wrote: >> Not to totally hijack the thread -- but since you're all talking >> about best GUI frameworks. Any thoughts on the best looking framework >> for OS X only? Is there any w

Re: The reliability of python threads

2007-01-25 Thread Paul Rubin
[EMAIL PROTECTED] writes: > What makes you think Paddy indicated he wouldn't try to solve the problem? > Here's what he wrote: > > What I'm proposing is that if, for example, a process stops running > three times in a year at roughly three to four months intervals , and it > should hav

Re: Module for SVG?

2007-01-25 Thread Gabriel Genellina
At Thursday 25/1/2007 16:46, [EMAIL PROTECTED] wrote: Depending on the size of your project, the xist library from living logic is supporting svg xml: http://www.livinglogic.de/Python/xist/ http://www.livinglogic.de/Python/xist/ns/svg/ We've used it successfully, but later on came back to simpl

Re: difflib qualm

2007-01-25 Thread Larry Bates
Gabriel Genellina wrote: > At Wednesday 24/1/2007 23:05, Sick Monkey wrote: > >> I am trying to write a python script that will compare 2 files which >> contains names (millions of them). >> >> More specifically, I have 2 files (Files1.txt and Files2.txt). >> Files1.txt contains 180 thousand name

Re: The reliability of python threads

2007-01-25 Thread skip
Paul> I dunno about Nick, I'm saying it's best to assume that it's Paul> Poisson and do whatever is necessary to diagnose and fix the bug, Paul> and that the voodoo measure you're proposing is not all that Paul> likely to help and it will take years to find out whether it helps

Re: MIME text attachment question

2007-01-25 Thread Gabriel Genellina
At Thursday 25/1/2007 08:41, Neal Becker wrote: I want to send a file (plain text) as an attachment. I'm using MIMEText. This attaches text OK, but I would like to have a filename attached to it, so that the recipient could save it without having to specify a filename. part = MIMEText("Hello

Bush, yank bastards kicked by india in their arse Re: *POLL* How many sheeple believe in the 911 fairy tale and willing to accept an Orwellian doublespeak and enslavement world ?

2007-01-25 Thread thermate
Russia to build nuclear power plants in India http://www.tribuneindia.com/2007/20070126/main1.htm India, Russia for axis with China Rajeev Sharma Tribune News Service New Delhi, January 25 India and Russia today supported their trilateral axis with China, but opposed Beijing's January 11 testing

Re: Rendering text question (context is MSWin UI Automation)

2007-01-25 Thread Boris Borcic
Chris Mellon wrote: >> Maybe. In any case, color separation solves my (sub)problem : the blue layer >> from the wx generated model matches the green layer from the app's window, >> pixel >> for pixel (at least with antialiasing and cleartype on, while writing black >> on >> white). >> > > That's

Re: Question about docutils

2007-01-25 Thread Damjan
>> I'm using docutils 0.4. >> Is it possible to define special custom 'tags' (or something) that will >> invoke my own function? The function would then return the real content >> in the ReST document. > > I -think- this is what you're looking for: > http://docutils.sourceforge.net/docs/howto/rst-

Re: Possible bug in Python 2.5? (Was Re: pdb in python2.5)

2007-01-25 Thread R. Bernstein
"Rotem" <[EMAIL PROTECTED]> writes: > Hi, > > I noticed that pydb.pm() also fails in python2.5 when invoked on that > same example (seems like also trying to access a nonexistent > attribute/variable). > > Is this known to you as well/was it fixed? Doesn't do that for me for Python 2.5 on both

Re: Catching floating point errors from linked C code

2007-01-25 Thread John Pye
Hi John I think you're right, and I need to place FPE 'brackets' around my code. The thing that was confusing me was that python has division by zero exceptions (for which I assumed fenv.h was being used), but when from python I reach down into my SWIG code and do a 1/0, no SIGFPE is thrown. I w

[ANN] markup.py 1.6

2007-01-25 Thread Daniel Nogradi
The new 1.6 release of markup.py is available for download: http://sourceforge.net/project/showfiles.php?group_id=161108 What is it? Markup.py is an intuitive, lightweight, easy-to-use, customizable and pythonic HTML/XML generator. Where is the documentation? http://markup.sourceforge.net/ Wh

Re: stop script w/o exiting interpreter

2007-01-25 Thread Paul Rubin
"Alan Isaac" <[EMAIL PROTECTED]> writes: > I'm fairly new to Python and I've lately been running a script at > the interpreter while working on it. Sometimes I only want to > run the first quarter or half etc. What is the "good" way to do this? If it's single threaded then just call sys.exit().

Re: pdf to text

2007-01-25 Thread Dieter Deyke
tubby writes: > David Boddie wrote: > >> The pdftotext tool may do what you want: >> >> http://www.foolabs.com/xpdf/download.html >> >> Let us know how you get on with it. >> >> David > > Perhaps I'm just using pdftotext wrong? Here's how I was using it: > > f = filename > > try: > sout = os

stop script w/o exiting interpreter

2007-01-25 Thread Alan Isaac
I'm fairly new to Python and I've lately been running a script at the interpreter while working on it. Sometimes I only want to run the first quarter or half etc. What is the "good" way to do this? Possible ugly hacks include: - stick an undefined name at the desired stop point - comment out th

Re: pdf to text

2007-01-25 Thread Lee Harr
> Perhaps I'm just using pdftotext wrong? Here's how I was using it: > > sout = os.popen('pdftotext "%s" - ' %f) If you are having trouble with popen (not unlikely) how about just writing to a temporary file and reading the text from there? I've used pdftotext several times in the past f

Re: Fast Imaging for Webserver

2007-01-25 Thread Prateek
Thanks for all the responses so far.. The 'imaging' app that I mentioned is actually serving as a library for a bunch of other apps. A typical scenario is icon processing. The source image *could* be large (in this case it was 128x128 PNGA) Think of it as a Mac Finder/Win Explorer style view (gri

Re: Right-Justifying Numeric Output

2007-01-25 Thread Tobiah
> Thank you very much! I didn't see this in any of my Python books or on > the I like to look at the printf docs for any C compiler. On Unix, man 3 printf -- Posted via a free Usenet account from http://www.teranews.com -- http://mail.python.org/mailman/listinfo/python-list

Re: Right-Justifying Numeric Output

2007-01-25 Thread Rich Shepard
On Thu, 25 Jan 2007, hg wrote: > assuming max size = 10 > > #with spaces >>> '% 10d' % 11 > '11' > #with zeros >>> '%010d' % 11 > '11' Thank you very much! I didn't see this in any of my Python books or on the Web. Rich -- Richard B. Shepard, Ph.D. |The Env

Re: Right-Justifying Numeric Output

2007-01-25 Thread hg
Rich Shepard wrote: >I have this print statement in a function: > > print '%2d $%11.2f $%10.2f $%9.2f $%9.2f' %(nper, pv, diff, ten, > bonus) > > and I would like to have the output right justified in the specified > field. My trials using .rjust(n) have produced that string in the outp

Right-Justifying Numeric Output

2007-01-25 Thread Rich Shepard
I have this print statement in a function: print '%2d $%11.2f $%10.2f $%9.2f $%9.2f' %(nper, pv, diff, ten, bonus) and I would like to have the output right justified in the specified field. My trials using .rjust(n) have produced that string in the output, not the intended results. Is th

Re: pdf to text

2007-01-25 Thread tubby
David Boddie wrote: > The pdftotext tool may do what you want: > > http://www.foolabs.com/xpdf/download.html > > Let us know how you get on with it. > > David Perhaps I'm just using pdftotext wrong? Here's how I was using it: f = filename try: sout = os.popen('pdftotext "%s" - ' %f)

Re: pdf to text

2007-01-25 Thread tubby
David Boddie wrote: > The pdftotext tool may do what you want: > > http://www.foolabs.com/xpdf/download.html > > Let us know how you get on with it. I have used this tool. However, I need PDF read ability on Windows and Linux and in the future Macs. pdftotext works great on Linux, but poorly

Re: pdf to text

2007-01-25 Thread David Boddie
On Thursday 25 January 2007 22:05, tubby wrote: > I know this question comes up a lot, so here goes again. I want to read > text from a PDF file, run re searches on the text, etc. I do not care > about layout, fonts, borders, etc. I just want the text. I've been > reading Adobe's PDF Reference Gui

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

Re: Possible bug in Python 2.5? (Was Re: pdb in python2.5)

2007-01-25 Thread Rotem
Hi, I noticed that pydb.pm() also fails in python2.5 when invoked on that same example (seems like also trying to access a nonexistent attribute/variable). Is this known to you as well/was it fixed? On Jan 25, 9:15 pm, [EMAIL PROTECTED] (R. Bernstein) wrote: > I'd like to change my assessment of

Re: selective logger disable/enable

2007-01-25 Thread Gary Jefferson
Gary Jefferson wrote: > So maybe I don't have all this figured out quite as well as I thought. > What I really want to do is set an environment variable, MYDEBUG, which > contains a list of wildcarded logger names, such as "a.*.c a.d" (which > becomes ['a.*.c', 'a.d'], and then selectively crank th

Fwd: asyncore.dispatcher.handle_read

2007-01-25 Thread Indy
-- Forwarded message -- From: Indy <[EMAIL PROTECTED]> Date: Jan 25, 2007 11:27 PM Subject: Re: asyncore.dispatcher.handle_read To: Jordan <[EMAIL PROTECTED]> OK, problem fixed. Thanks anyway :-) On 25 Jan 2007 10:08:01 -0800, Jordan <[EMAIL PROTECTED]> wrote: > That was not enti

Re: logging module and doctest

2007-01-25 Thread Gary Jefferson
Peter Otten wrote: > Peter Otten wrote: > > > Gary Jefferson wrote: > > > >> I've written a logging.filter and would like to use doctest on it > >> (using a StreamHandler for stdout), but this doesn't seem possible. > >> Output from the logger seems to disappear (running the doctest strings > >> th

Re: Python does not play well with others

2007-01-25 Thread Jarek Zgoda
Harry George napisał(a): > You experience isn't shared by everyone. Some of us find Python the > most functional and portable of the candidates you mention. The point on MySQLdb is rather common, many people who used it with SQLObject will confirm. Fortunately for MySQLdb, the MySQL on its own i

Re: The reliability of python threads

2007-01-25 Thread Nick Maclaren
In article <[EMAIL PROTECTED]>, "Paddy" <[EMAIL PROTECTED]> writes: |> |> No, you should think of the service that needs to be up. You seem to be |> talking about how it can't be fixed rather than looking for ways to |> keep things going. A little learning is fine but "it can't |> theoretically b

Re: The reliability of python threads

2007-01-25 Thread Paul Rubin
"Paddy" <[EMAIL PROTECTED]> writes: > > But you're proposing cargo cult programming. > i don't know that term. http://en.wikipedia.org/wiki/Cargo_cult_programming > What I'm proposing is that if, for example, a process stops running > three times in a year at roughly three to four months interval

pdf to text

2007-01-25 Thread tubby
I know this question comes up a lot, so here goes again. I want to read text from a PDF file, run re searches on the text, etc. I do not care about layout, fonts, borders, etc. I just want the text. I've been reading Adobe's PDF Reference Guide and I'm beginning to develop a better understandin

Re: Python does not play well with others

2007-01-25 Thread Paul Rubin
John Nagle <[EMAIL PROTECTED]> writes: > That's the problem. We now have four SSL implementations for > Python, none of which let you do all the things OpenSSL can do. I'm aware of some OpenSSL wrappers plus TLSlite. Am I missing a couple more? I guess maybe the OpenSSL wrappers also work o

Re: Python does not play well with others

2007-01-25 Thread John Nagle
Paul Rubin wrote: > "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> writes: > >>I haven't had a need to do anything with OpenSSL from Python; all >>that takes place in the Apache server > > > That's a reasonable approach for a typical server-side web > application, but there are other types of Python a

Re: The reliability of python threads

2007-01-25 Thread Paddy
On Jan 25, 8:00 pm, Paul Rubin wrote: > "Paddy" <[EMAIL PROTECTED]> writes: > > No, you should think of the service that needs to be up. You seem to be > > talking about how it can't be fixed rather than looking for ways to > > keep things going. > But you're proposing

Re: running applications in python

2007-01-25 Thread Daniel
2007-01-25 18:28:44 lee <[EMAIL PROTECTED]> wrote in message <[EMAIL PROTECTED]> > how can i run or open a windows application from the python prompt?for > e.g.mediaplayer opening,folder acess etc Here's another way of doing it: import os TheCommandIwantTorun = '"C:\Program\Windows Media Player

Re: Python does not play well with others

2007-01-25 Thread Paul Rubin
"[EMAIL PROTECTED]" <[EMAIL PROTECTED]> writes: > I haven't had a need to do anything with OpenSSL from Python; all > that takes place in the Apache server That's a reasonable approach for a typical server-side web application, but there are other types of Python apps that can also want to use SS

Re: The reliability of python threads

2007-01-25 Thread Paul Rubin
"Paddy" <[EMAIL PROTECTED]> writes: > No, you should think of the service that needs to be up. You seem to be > talking about how it can't be fixed rather than looking for ways to > keep things going. But you're proposing cargo cult programming. There is no reason whatsoever to expect that restar

Re: Python does not play well with others

2007-01-25 Thread [EMAIL PROTECTED]
On Jan 25, 12:17 pm, John Nagle <[EMAIL PROTECTED]> wrote: > My main concern is with glue code to major packages. The connections > to OpenSSL, MySQL, and Apache (i.e. mod_python) all exist, but have major > weaknesses. If you're doing web applications, those are standard pieces > which need

Re: The reliability of python threads

2007-01-25 Thread Paddy
On Jan 25, 7:36 pm, [EMAIL PROTECTED] (Nick Maclaren) wrote: > In article <[EMAIL PROTECTED]>,"Paddy" <[EMAIL PROTECTED]> writes:|> > |> > |> Three to four months before `strange errors`? I'd spend some time > |> > |> correlating logs; not just for your program, but for everything > running > |>

Re: Module for SVG?

2007-01-25 Thread Boris . Boutillier
Depending on the size of your project, the xist library from living logic is supporting svg xml: http://www.livinglogic.de/Python/xist/ http://www.livinglogic.de/Python/xist/ns/svg/ We've used it successfully, but later on came back to simply use the standard dom creation tools in python to reduce

Re: The reliability of python threads

2007-01-25 Thread Nick Maclaren
In article <[EMAIL PROTECTED]>, "Paddy" <[EMAIL PROTECTED]> writes: |> |> > |> Three to four months before `strange errors`? I'd spend some time |> > |> correlating logs; not just for your program, but for everything running |> > |> on the server. Then I'd expect to cut my losses and arrange to s

Possible bug in Python 2.5? (Was Re: pdb in python2.5)

2007-01-25 Thread R. Bernstein
I'd like to change my assessment of whether the problem encountered is a pdb bug or not. It could be a bug in Python. (Right now it is only known to be a bug in version 2.5.) For a given traceback t, the question is whether t.tb_frame.f_lineno can ever be different from t.tb_lineno. Still, for no

Re: Do I need Python to run Blender correctly?

2007-01-25 Thread Boris Borcic
[EMAIL PROTECTED] wrote: > Also note that only standard modules bundled in the Blender package are > available. And extension modules e.g. numpy can't be installed into it. Not my experience, I've installed and used numpy (or was it Numeric ?) with Blender Python a couple years ago. YMMV, Bori

Re: The reliability of python threads

2007-01-25 Thread Carl J. Van Arsdall
Aahz wrote: > [snip] > > My response is that you're asking the wrong questions here. Our database > server locked up hard Sunday morning, and we still have no idea why (the > machine itself, not just the database app). I think it's more important > to focus on whether you have done all that is re

Re: The reliability of python threads

2007-01-25 Thread Paddy
On Jan 25, 9:26 am, [EMAIL PROTECTED] (Nick Maclaren) wrote: > In article <[EMAIL PROTECTED]>,"Paddy" <[EMAIL PROTECTED]> writes:|> > |> Three to four months before `strange errors`? I'd spend some time > |> correlating logs; not just for your program, but for everything running > |> on the serve

Re: Rendering text question (context is MSWin UI Automation)

2007-01-25 Thread Chris Mellon
On 1/25/07, Boris Borcic <[EMAIL PROTECTED]> wrote: > Chris Mellon wrote: > > On 1/25/07, Boris Borcic <[EMAIL PROTECTED]> wrote: > >> Chris Mellon wrote: > > > > > Some quick & dirty wxPython code > > > > def getTextBitmap(text, font, fgcolor, bgcolor): > > dc = wx.MemoryDC

Module for SVG?

2007-01-25 Thread Sebastian Bassi
Hello, I found http://www2.sfk.nl/svg as a Python module for writing SVG. Last update was in 2004 and I am not sure if there is something better. Any recommendation for generating SVG graphics? Best, SB. -- http://mail.python.org/mailman/listinfo/python-list

Re: While loop with "or"? Please help!

2007-01-25 Thread Daniel
2007-01-25 11:26:09 [EMAIL PROTECTED] wrote in message <[EMAIL PROTECTED]> > Hmm, my while loop with "or" doesn't seem to work as I want it to... > How do I tell the while loop to only accept "Y" or "y" or "N" or "n" > input from the str(raw_input)? > > Thank's in advance! > > Snippet of code:

RE: Overloading assignment operator

2007-01-25 Thread Carroll, Barry
> -Original Message- > From: Gabriel Genellina [mailto:[EMAIL PROTECTED] > Sent: Tuesday, January 23, 2007 9:24 PM > To: python-list@python.org > Subject: Re: Overloading assignment operator > > "Carroll, Barry" <[EMAIL PROTECTED]> escribió en el mensaje > news:[EMAIL PROTECTED] > > > * .

Re: Rendering text question (context is MSWin UI Automation)

2007-01-25 Thread Boris Borcic
Chris Mellon wrote: > On 1/25/07, Boris Borcic <[EMAIL PROTECTED]> wrote: >> Chris Mellon wrote: > > Some quick & dirty wxPython code > > def getTextBitmap(text, font, fgcolor, bgcolor): > dc = wx.MemoryDC() > dc.SetFont(font) > width, height= dc.GetTextExte

Re: Thoughts on using isinstance

2007-01-25 Thread Matthew Woodcraft
Bruno Desthuilliers <[EMAIL PROTECTED]> wrote: > Matthew Woodcraft a écrit : >> Adding the validation code can make your code more readable, in that >> it can be clearer to the readers what kind of values are being >> handled. > This is better expressed in the docstring. And if it's in the > doc

Re: ANN: Dejavu 1.5.0RC1

2007-01-25 Thread olive
Looks interesting... Do you consider a StorageManagers for Oracle ? Olive. On Jan 24, 11:57 pm, "Robert Brewer" <[EMAIL PROTECTED]> wrote: > The Dejavu Object-Relational Mapper (version 1.5.0RC1) is now available > and in the public domain. Get it athttp://projects.amor.org/dejavu, > or from PyP

Re: asyncore.dispatcher.handle_read

2007-01-25 Thread Jordan
That was not entirely helpful, it's way more likely a mistake you made in subclassing dispatcher than a problem within asycore itself (that ended up sounding a lot more mean/angry than intended, sorry ¬_¬ ), you really need to show us what changes you made to asyncore.dispatcher if you want help.

Re: Email attachments

2007-01-25 Thread Facundo Batista
Steve Holden wrote: > I'm having some trouble getting attachments right for all recipients, > and it seems like Apple's mail.app is the pickiest client at the moment. > It doesn't handle attachments that both Thunderbird and Outlook find > perfectly acceptable. The following code works ok with

Re: running applications in python

2007-01-25 Thread Jordan
os.system, os.spawn, the process module, os.popen[1,2,3,4], this is a pretty basic thing, not trying to be mean, but you should look in the python docs, this is definitely in there. Also, the subprocess module is meant to replace all of those but i haven't looked too closely at it yet, so the foll

Re: Two dimensional lists

2007-01-25 Thread Travis Oliphant
Laszlo Nagy wrote: >># shouldn't I be able to fill the lists simply by pointing to a location? >> >>matrix[a_idx, p_idx] = 0x219 # and so on? >> > > Lists are not matrices. For example: > > L = [ [1,2,3], ['a','b','c'], 10 ] > print L[1][2] # Prints 'c', you will like this syntax but... > prin

Re: Python does not play well with others

2007-01-25 Thread skip
John> My main concern is with glue code to major packages. The John> connections to OpenSSL, MySQL, and Apache (i.e. mod_python) all John> exist, but have major weaknesses. I have no SSL experience or direct mod_python experience (I do use Myghty effectively), but I have used MySQLdb

Re: Python does not play well with others

2007-01-25 Thread Paul Rubin
John Nagle <[EMAIL PROTECTED]> writes: > My main concern is with glue code to major packages. The connections > to OpenSSL, MySQL, and Apache (i.e. mod_python) all exist, but have major > weaknesses. If you're doing web applications, those are standard pieces > which need to work right. Ther

running applications in python

2007-01-25 Thread lee
how can i run or open a windows application from the python prompt?for e.g.mediaplayer opening,folder acess etc -- http://mail.python.org/mailman/listinfo/python-list

Re: assertions to validate function parameters

2007-01-25 Thread George Sakkis
On Jan 25, 11:54 am, Matthew Wilson <[EMAIL PROTECTED]> wrote: > Lately, I've been writing functions like this: > > def f(a, b): > > assert a in [1, 2, 3] > assert b in [4, 5, 6] > > The point is that I'm checking the type and the values of the > parameters. > > I'm curious how this does o

Re: Two dimensional lists

2007-01-25 Thread Peter Otten
gonzlobo wrote: > I might get an answer since I didn't call them arrays. :^) > > Ok, I have 2 lists that I need to process individually, then merge > them into a 2x list and fill with data. > > arinc429 = ['ab', '2b', '0b', '21', 'c1', '61', '11', 'db', '9b', '5b', > 'eb', > '6b', '1b',

Re: Python does not play well with others

2007-01-25 Thread John Nagle
Paul Boddie wrote: > On 25 Jan, 12:01, "Ben Sizer" <[EMAIL PROTECTED]> wrote: > >> I think that is why many of the SIGs are stagnant, why the standard library >> has so much fluff yet still lacks in key areas such as multimedia and web >> development, etc. > ... I think this is also a good insight

asyncore.dispatcher.handle_read

2007-01-25 Thread Indy
Greetings. I am writing an asynchronous server, and I use the standard library's module asyncore. I subclass asyncore.dispatcher. handle_accept works just right, that is, when a client socket makes a request to connect to my server socket, things that I set in handle_accept definition, happen. So,

assertions to validate function parameters

2007-01-25 Thread Matthew Wilson
Lately, I've been writing functions like this: def f(a, b): assert a in [1, 2, 3] assert b in [4, 5, 6] The point is that I'm checking the type and the values of the parameters. I'm curious how this does or doesn't fit into python's duck-typing philosophy. I find that when I detect inv

Re: free variables /cell objects question

2007-01-25 Thread gangesmaster
[Steven] > My solution is, don't try to have one function do too much. Making a list > of foos should be a separate operation from making a single foo: that's exactly what my second example does (as well as my production code) [Paul] > But it does work as expected, if your expectations are based

Re: Using Timing function problem.....

2007-01-25 Thread Jona
Thanks so much! that did it! you can tell I'm new with python.. lol... thanks again.. Jonathan -- http://mail.python.org/mailman/listinfo/python-list

Re: Two dimensional lists

2007-01-25 Thread Laszlo Nagy
> # shouldn't I be able to fill the lists simply by pointing to a location? > > matrix[a_idx, p_idx] = 0x219 # and so on? > Lists are not matrices. For example: L = [ [1,2,3], ['a','b','c'], 10 ] print L[1][2] # Prints 'c', you will like this syntax but... print L[2][5] # TypeError: 10 is not

Re: Do I need Python to run Blender correctly?

2007-01-25 Thread John Nagle
AKA gray asphalt wrote: > I downloaded Blender but there was no link for python. Am I on the right > track? Blender doesn't require Python, but if you have Python, you can write plug-ins for Blender. Get "The Blender Book"; otherwise you'll never figure Blender out.

Re: ANN: Dejavu 1.5.0RC1

2007-01-25 Thread Michele Cella
On 25 Gen, 09:02, "fumanchu" <[EMAIL PROTECTED]> wrote: > > > I am curious ... how this compare to SQLAlchemy?The comparisons could be > > endless ;) but here are some of the larger > differences: > > 1. Dejavu uses generic "storage" concepts and syntax, while SQLAlchemy > prefers database concep

Re: sqlite user-defined functions & unicode issue

2007-01-25 Thread Gerhard Häring
Ben Wolfson wrote: I've got a db some of whose elements have been created automatically from filesystem data (whose encoding is iso-8859-1). If I try to select one of those elements using a standard SQL construct, things work fine: [...] How can I get around this? I really want to be able to s

  1   2   >