unicode printing on Windows

2012-02-09 Thread BlueBird
Hi, The question is not totally related to Python but there is a strong connection. Everytime that I try to debug some python programs under Windows, I encounter the issue that things printed on the console simply break the program because : 1. My windows console does not support UTF8 2. Things pr

Re: Deeply nested dictionaries - should I look into a database or am I just doing it wrong?

2011-08-02 Thread BlueBird
I love named tuples, they rock for this kind of task: storing complicated structure in a python compatible way, without too much hassle. And as far as load/save on disk is concerned, I simply use regular python structure with safe eval [1]. I get all the flexibility that I need for the file format

Re: SOAP 1.2 Python client ?

2010-03-23 Thread BlueBird
On 5 mar, 13:19, lbolla wrote: > On Mar 5, 10:01 am, BlueBird wrote: > > > > > > > On 3 mar, 20:35, Stefan Behnel wrote: > > > > BlueBird, 03.03.2010 17:32: > > > > > I am looking for aSOAP1.2 python client. To my surprise, it seems > > &

Re: SOAP 1.2 Python client ?

2010-03-05 Thread BlueBird
On 3 mar, 20:35, Stefan Behnel wrote: > BlueBird, 03.03.2010 17:32: > > > I am looking for a SOAP 1.2 python client. To my surprise, it seems > > that this does not exist. Does anybody know about this ? > > SOAP may be an overly bloated protocol, but it's certainl

SOAP 1.2 Python client ?

2010-03-03 Thread BlueBird
Hi, I am looking for a SOAP 1.2 python client. To my surprise, it seems that this does not exist. Does anybody know about this ? The following clients seem to be both unmaintained and still supporting only SOAP 1.1 : - SUDS - zsi - SOAPy cheers, Philippe -- http://mail.python.org/mailman/li

Re: Docstrings considered too complicated

2010-03-03 Thread BlueBird
On Feb 24, 9:23 pm, Andreas Waldenburger wrote: > Hi all, > > a company that works with my company writes a lot of of their code in > Python (lucky jerks). I've seen their code and it basically looks like > this: > > """Function that does stuff""" > def doStuff(): >     while not wise(up): >      

Re: Memory footpring of python objects

2009-04-22 Thread BlueBird
On 22 avr, 11:56, Steven D'Aprano wrote: > On Wed, 22 Apr 2009 02:30:32 -0700, Chris Rebert wrote: > > On Wed, Apr 22, 2009 at 2:24 AM, BlueBird wrote: > > >> Hi, > > >> I have a program that manages several thousands instances of one > >> objec

Memory footpring of python objects

2009-04-22 Thread BlueBird
Hi, I have a program that manages several thousands instances of one object. To reduce memory consumption, I want of course that specific object to have the smallest memory footpring possible. I have a few ideas that I want to experiment with, like using __slots__, using a tuple or using a dict.

Re: Event Handling and Signal-Slot Mechanism

2009-01-19 Thread BlueBird
On Jan 19, 4:10 am, Steven Woody wrote: > Hi, > > Python has Signal-Slot mechanism, Python does not have signal/slot mechanism. You are talking about the Qt toolkit, which is initially a (nice) C++ toolkit, available also in python via the PyQt wrapper. Signal/slots were introduced by Qt to make

Re: How to "kill" orphaned threads at program exit

2009-01-05 Thread BlueBird
On Dec 28 2008, 6:33 pm, "Giampaolo Rodola'" wrote: > Hi, > I know that it's not possible to "kill" threads but I'm wondering if > does exist some workaround for my problem. > I have a test suite which does a massive usage of threads. > Sometimes happens that one test fails, the test suite keeps r

Re: How to distribute a Python app together with its dependencies?

2008-12-01 Thread BlueBird
Alessio Pace wrote: > Hi, > > I have to distribute a Python application which relies on an external > library, and I'm not very fluent in this kind of stuff with Python (I > come from the Java world where I would have used the Maven build tool > to create an "assembly with dependencies" of all it

Re: Interrupt python thread

2008-08-25 Thread BlueBird
On Aug 24, 8:35 pm, Dennis Lee Bieber <[EMAIL PROTECTED]> wrote: > On Sun, 24 Aug 2008 01:48:46 -0700 (PDT), BlueBird > <[EMAIL PROTECTED]> declaimed the following in comp.lang.python: > > > > > Whenever an exception occurs, in the master thread or in one of the &

Interrupt python thread

2008-08-24 Thread BlueBird
Hi, I have a program with a master thread and several slave threads. Whenever an exception occurs, in the master thread or in one of the slave threads, I would like to interrupt all the threads and the main program. Threading API does not seem to provide a way to stop a thread, is there anyway to

Re: Continuous integration for Python projects

2008-07-30 Thread BlueBird
On Jul 29, 4:56 pm, "Diez B. Roggisch" <[EMAIL PROTECTED]> wrote: > Hussein B wrote: > > Hi. > > Please correct my if I'm wrong but it seems to me that the major > > continuous integration servers (Hudson, CruiseControl, TeamCity ..) > > don't support Python based application. > > It seems they mai

Re: How to generate binary python?

2008-05-06 Thread BlueBird
On May 6, 6:29 am, "Gabriel Genellina" <[EMAIL PROTECTED]> wrote: > En Mon, 05 May 2008 19:43:24 -0300, David Anderson <[EMAIL PROTECTED]> > escribió: > > > Hi, i'm comingo from Java and I'm wanting to know what in Python is the > > equivalent to the file.class in java, I am producing some apps tha

Re: how to use subprocess.Popen execute "find" in windows

2008-05-06 Thread BlueBird
On May 6, 11:19 am, [EMAIL PROTECTED] wrote: > In cmd, I can use find like this. > > C:\>netstat -an | find "445" > TCP0.0.0.0:4450.0.0.0:0 LISTENING > UDP0.0.0.0:445*:* > > C:\> > > And os.system is OK.>>> import os > >>> os.system('netstat -an | fi

Re: python scripts to standalone executable

2008-04-01 Thread BlueBird
On Mar 31, 7:24 pm, Amit Gupta <[EMAIL PROTECTED]> wrote: > Hi > > I am looking for a some tool that can convert python scripts to > executable on Linux. > > I found freeeze.py as the only option so far. Couple of queries on > freeze: > > 1. Have anyone used the freeze utility and any experiences t

Re: Using QSystemTrayIcon with PyQt

2008-04-01 Thread BlueBird
On Apr 1, 6:00 am, Alex Teiche <[EMAIL PROTECTED]> wrote: > On Mar 31, 7:53 pm, Benjamin <[EMAIL PROTECTED]> wrote: > > > > > On Mar 31, 8:41 pm, Alex Teiche <[EMAIL PROTECTED]> wrote: > > > > On Mar 31, 6:40 pm, Alex Teiche <[EMAIL PROTECTED]> wrote: > > > > > On Mar 31, 11:49 am, Alex Teiche <[EM

Re: Is there a way to "link" a python program from several files?

2008-02-18 Thread BlueBird
On Feb 16, 7:53 pm, [EMAIL PROTECTED] (Edward A. Falk) wrote: > IOW, is there a "linker" for python? I've written a program comprised of > about > five .py files. I'd like to find a way to combine them into a single > executable. I wrote a small wiki page to sum-up my findings about such typica

Re: Static linking of python and pyqt

2007-12-20 Thread BlueBird
On Dec 19, 1:26 pm, Markus Dahlbokum <[EMAIL PROTECTED]> wrote: > > > I just want the qt libs linked to the interpreter without accessing them > > > by a module. I tried the configure option '--with-libs='lib ...''. The > > > make did fine but the executable is too small and the qt symbols are not

Re: Best way to protect my new commercial software.

2007-12-10 Thread BlueBird
On Dec 10, 8:15 am, farsheed <[EMAIL PROTECTED]> wrote: > I wrote a software and I want to protect it so can not be cracked > easily. I wrote it in python and compile it using py2exe. what is the > best way in your opinion? I used SoftwarePassport ( http://www.siliconrealms.com/ ) for exactly this

Re: Code Management

2007-12-07 Thread BlueBird
On Dec 2, 4:27 pm, BlueBird <[EMAIL PROTECTED]> wrote: > On Nov 26, 5:07 pm, "Sergio Correia" <[EMAIL PROTECTED]> wrote: > > >Bluebird: > > > If you are using python 2.5, relative imports are no longer an > > issue:http://docs.python.org/whatsnew/pe

Re: Python surpasses Perl in TIOBE index

2007-12-05 Thread BlueBird
On Dec 4, 4:08 pm, [EMAIL PROTECTED] wrote: > This is *not* an attempt to start yet another Python-versus- > AnyOtherProgrammingLanguage flame war, but I thought people might be > interested in this: > > http://www.tiobe.com/tpci.htm > > Marc I find Ohloh comparisons also useful: http://www.ohloh.

Re: Code Management

2007-12-02 Thread BlueBird
On Nov 26, 5:07 pm, "Sergio Correia" <[EMAIL PROTECTED]> wrote: > Bluebird: > > If you are using python 2.5, relative imports are no longer an > issue:http://docs.python.org/whatsnew/pep-328.html It does not solve my problem, or I missed something: [EMAIL PROTECTED]

Re: Code Management

2007-11-24 Thread BlueBird
On Nov 21, 7:05 am, "Sergio Correia" <[EMAIL PROTECTED]> wrote: > As a side note, I find much easier to drop a PTH file than messing > with pythonpath. If you are not familiar with PTH files, what I do is > this > > 1) Go to "C:\Program Files\Python25\Lib\site-packages" or whatever is > appropiate

Re: Python too complex ?!?!?!

2007-11-21 Thread BlueBird
On Nov 20, 9:36 pm, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > FWIW it's trivial to run pyflakes on your code (automatically behind > the scenes) to get syntax checking; in vim, my syntax errors get > underlined immediately for python code. Can you describe your setup a bit more precisel

Re: PyQt with embedded python in Qt App

2007-11-02 Thread BlueBird
On Nov 2, 8:03 am, "Bart." <[EMAIL PROTECTED]> wrote: > Friday 02 of November 2007 01:06:58 Diez B. Roggisch napisa (a): > > > > So how to pass this object into embeded python interpreter (executed > > > script)? Anyone know any example? > > > You don't pass it, you _retrieve_ it in the embedded in

Re: building a linux executable

2007-10-29 Thread BlueBird
Hi, Some time ago, I compiled a small list of tools to perform the some "python executable bundling" tasks. It might be useful for you. Here is the list: http://www.freehackers.org/Packaging_a_python_program Philippe -- http://mail.python.org/mailman/listinfo/python-list

Re: Is there a way to tell if a script has been run by Pythonw.exe instead of Python.exe?

2007-10-19 Thread BlueBird
On Oct 18, 11:56 pm, Metalone <[EMAIL PROTECTED]> wrote: > In particular I want to know how to tell if reading and writing to the > console can occur. > Something like > sys.isConsolePresent() For a different problem, I have the following code. It might help: def isrealfile(file): """

Re: EasyMock for python ?

2007-10-12 Thread BlueBird
On Oct 11, 4:26 pm, "Simon Brunning" <[EMAIL PROTECTED]> wrote: > On 10/10/07, BlueBird <[EMAIL PROTECTED]> wrote: > > > Does anybody know where to find a library like EasyMock for python ? I > > searched quickly but could not find anything. > >

Re: Cross-platform GUI development

2007-10-12 Thread BlueBird
On Oct 12, 12:30 pm, Nick Craig-Wood <[EMAIL PROTECTED]> wrote: > > > My question is if Tix is old hat, what is the GUI toolkit I *should* > > > be using for quick-n-dirty cross platform GUI development? I guess > > > this is tangentially related to: > > > >http://groups.google.com/group/comp.lang.

EasyMock for python ?

2007-10-10 Thread BlueBird
Hi, Does anybody know where to find a library like EasyMock for python ? I searched quickly but could not find anything. I found python-mocks on sourceforge but form quickly reading the docs, it is not an EasyMock style mock. Actually, according to http://martinfowler.com/articles/mocksArent

Re: Reading text files where last line has no EOL

2007-09-17 Thread BlueBird
On 17 sep, 13:24, Steve Holden <[EMAIL PROTECTED]> wrote: > BlueBird wrote: > > I tried and failed to read text files where the last line does not > > contain proper EOL. For my tests, I use a file that I create with the > > equivalent of : > > > open(&

Reading text files where last line has no EOL

2007-09-17 Thread BlueBird
I tried and failed to read text files where the last line does not contain proper EOL. For my tests, I use a file that I create with the equivalent of : open('toto', 'w').write( '1234\n4567\n89AB' ) My reading code looks like this : l = f.readline() while len(l): self

Re: QPicture and Qpainter PyQt4

2007-09-17 Thread BlueBird
Hi, It looks like you have several things wrong: On Sep 17, 9:29 am, luca72 <[EMAIL PROTECTED]> wrote: > class Form(QWidget, Ui_Form): > [...] > > @pyqtSignature("") > def on_pushButton_clicked(self): > """ > Slot documentation goes here. > """ > # TOD