Instatiable Pseudo-Random Number Generator

2009-09-10 Thread Hans Georg Schaathun
I wonder if someone knows of an API with the features I need... random.Random and numpy.random each have only half of it... My application includes an object to hold a pseudo-randomly generated matrix too large to be kept in memory. Hence I try to store only the seed, and generate the numbers on

How to create an array which can be used also as a dictionary

2009-09-10 Thread Hans Müller
].value1 = 1000 is d[aax].value1 now 1000 or still hello as in this example ? Any ideas to get access to the SAME object by index (0..n-1) AND by key ? Emphasis here is on speed. Thanks a lot, Hans -- http://mail.python.org/mailman/listinfo/python-list

Re: Instatiable Pseudo-Random Number Generator

2009-09-10 Thread Hans Georg Schaathun
On Thu, 10 Sep 2009 02:53:33 -0700 (PDT), sturlamolden sturlamol...@yahoo.no wrote: : On 10 Sep, 10:50, Hans Georg Schaathun ge...@ii.uib.no wrote: : : Can anyone recommend a PRNG which supported multiple instances : with independent states, and that also can return numpy.array

Re: How to create an array which can be used also as a dictionary

2009-09-10 Thread Hans Müller
Diez B. Roggisch wrote: Hans Müller wrote: Hello, I have a lot of items having a name and a given sequence. To access these items fast in a sequence order they should be used as a list, but to be fetched fast by name they also should be in a dictionary. Code could be something like

win32pipe

2009-09-03 Thread Hans Müller
Hello, I'd like to play a little with named pipes on windows. For this purpose google told me there is a win32pipe module. My python2.6 on windows doesn't know it - so where can I get ? Does it belong to the std. python for windows or is it a separate package ? Thank a lot, Hans -- http

CodeInvestigator version 0.14.0

2009-08-05 Thread hans moleman
CodeInvestigator version 0.14.0 was released on August 6. Required Python version: = 2.6 and 3.0 Changes: Unicode characters. They are handled better. Performance changes: The database is written more efficiently, so that recording takes less time. Performance

[issue1424152] urllib/urllib2: HTTPS over (Squid) Proxy fails

2009-07-17 Thread Hans Lellelid
Hans Lellelid h...@velum.net added the comment: Personally, I also think that this is a bugfix, though I realize that in order to fix the bug an API addition had to be made. So +1 from me on rolling into 2.6 (though my opinion is simply that of someone who's eager to see it fixed

Re: Fractions as result from divisions

2009-07-08 Thread Hans Nowak
and hard to debug for beginners. -- Hans Nowak (zephyrfalcon at gmail dot com) http://4.flowsnake.org/ -- http://mail.python.org/mailman/listinfo/python-list

Once again, comparison wxpython with PyQt

2009-06-19 Thread Hans Müller
with one or both frameworks ? Thanks a lot, Greetings Hans -- http://mail.python.org/mailman/listinfo/python-list

Re: Once again, comparison wxpython with PyQt

2009-06-19 Thread Hans Müller
Thanks for all your informative replies. If I understand you right, for a commercial, closed source program I only need a commercial PyQt license for ~ 500€ ? As far as I know I also need a Qt Licenses which is ~3500€ per OS. What is right ? Thanks a lot, Hans -- http://mail.python.org

Funny xmlrpc / linux problem

2009-06-16 Thread Hans Müller
: 1.985000 ' Whats this ?! - smaler packets, more time ?! Checking with 32 time for 10 loops: 2.00 Checking with 16 time for 10 loops: 2.00 Checking with 10 time for 10 loops: 2.00 Checking with 1 time for 10 loops: 2.00 Tanks a lot, Hans -- http://mail.python.org/mailman

Re: Funny xmlrpc / linux problem

2009-06-16 Thread Hans Müller
Small addition: While tracing the network data I found the server to be the problem, the answer to a request is beeing delayed by about 180ms - no idea why. -- http://mail.python.org/mailman/listinfo/python-list

Re: Funny xmlrpc / linux problem

2009-06-16 Thread Hans Müller
for 10 loops: 0.063000 The problem seems to be on the windows side. Any ideas ? Thanks, greetings Hans -- http://mail.python.org/mailman/listinfo/python-list

Re: Funny xmlrpc / linux problem

2009-06-16 Thread Hans Müller
case (i need speed for small packets) ? Thanks a lot Hans -- http://mail.python.org/mailman/listinfo/python-list

Seach for encrypted socket wrapper

2009-06-02 Thread Hans Müller
but this seems quite fat. Better ideas ?! Importand is also that the C-Lib on the cobol side should be coded as simple as possible. Platforms: Windows, *ix Thanks a lot. Hans -- http://mail.python.org/mailman/listinfo/python-list

Version 0.12.0 of CodeInvestigator was released on May 26.

2009-05-25 Thread hans moleman
CodeInvestigator version 0.12.0 was released on May 26. Bug fixes: - A garbage collect issue with GTK - Aborting a run tries to retain as much debug information as possible New features: - A clock in the status window helps with locating the event handler in the list

[issue1424152] urllib/urllib2: HTTPS over (Squid) Proxy fails

2009-05-20 Thread Hans L
Hans L h...@velum.net added the comment: These patches (well, the 2.6 patch) works for me. If there's something I can do to help get this accepted/applied, I'd be happy to do it. Obviously, I had no part in these patches, but I can take a stab at updating documentation or something

[issue1424152] urllib/urllib2: HTTPS over (Squid) Proxy fails

2009-05-20 Thread Hans Lellelid
Hans Lellelid h...@velum.net added the comment: Sure -- I will tackle that this week; I hope I can come up with something satisfactory. As I have not provided doc patches before for Python I may need to spin up a bit on that (and of course on the exact meaning of the set_tunnel method

[issue1424152] urllib/urllib2: HTTPS over (Squid) Proxy fails

2009-05-15 Thread Hans L
Changes by Hans L h...@velum.net: -- nosy: +hozn ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1424152 ___ ___ Python-bugs-list mailing list

CodeInvestigator version 0.11.1

2009-04-28 Thread hans moleman
CodeInvestigator version 0.11.1 was released on April 28. Bug fix: - A windows installation issue was resolved. CodeInvestigator is a tracing tool for Python programs. Running a program through CodeInvestigator creates a recording. Program flow, function calls, variable values and

RE: best way to compare contents of 2 lists?

2009-04-23 Thread Hans DushanthaKumar
'set' comes to mind, though I'm not sure if there are performance inplications with large amopunts of data. a=[1, 2, 3] b=[2, 3, 1] set(a) == set(b) True Cheers, Hans -Original Message- From: python-list-bounces+hans.dushanthakumar=hcn.com...@python.org [mailto:python-list-bounces

RE: sorting two corresponding lists?

2009-04-23 Thread Hans DushanthaKumar
Just being pedantic here :) [items[x] for x in [i for i in map(values.index, new_values)]] Is the same as [items[x] for x in map(values.index, new_values)] -Original Message- From: python-list-bounces+hans.dushanthakumar=hcn.com...@python.org

[issue5099] subprocess.POpen.__del__() AttributeError (os module == None!)

2009-04-07 Thread Hans L
Changes by Hans L h...@velum.net: -- nosy: +hozn ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5099 ___ ___ Python-bugs-list mailing list

Set Frozenset?

2009-03-08 Thread Hans Larsen
or frozenset! hope somebody can help! -- Hans Larsen Galgebakken Sønder 4-11A DK-2620 Albertslund Danmark/Danio begin 666 Hans Larsen.vcf M0D5'24XZ5D-!4D0-E9%4E-)3TXZ,BXQ#0I..DQAG-E;CM(86YS#0I3CI( M86YS($QAG-E;@T*14U!24P[4%)%1CM)3E1%4DY%5#IJ;V-J;T!M86EL+F1K C#0I2158Z,C P.3 S,#A4,3T-C,y

Anoying unicode / str conversion problem

2009-01-26 Thread Hans Müller
to a dictionary. The purpose of using a dictionary is to find equal rows in some database tables. Perhaps using a md5 hash from the column data is also an idea ? Thanks a lot in advance, Hans. -- http://mail.python.org/mailman/listinfo/python-list

Re: Anoying unicode / str conversion problem

2009-01-26 Thread Hans Müller
code. Again, thanks for the hint! Greetings Hans -- http://mail.python.org/mailman/listinfo/python-list

[issue4840] Compile dbm in Ubuntu

2009-01-04 Thread Charles Hans
New submission from Charles Hans cwh...@gmail.com: I tried and failed in compile python 3.0 in ubuntu 8.10. Then I found the scripts in setup.py use gdbm/ndbm.h while in ubuntu 8.10 it should be gdbm-ndbm.h. So I made the following change which make the compiling ok: setup.py 787c787

Eleganz way to get rid of \n

2008-09-01 Thread Hans Müller
, but it works fine. Has someone a better solution ? Thanks Hans -- http://mail.python.org/mailman/listinfo/python-list

[issue1309567] linecache module returns wrong results

2008-08-05 Thread Hans Ulrich Niedermann
Hans Ulrich Niedermann [EMAIL PROTECTED] added the comment: Unless someone has fixed it since 2008-07-05, it is still relevant. I'll have to take a look at the current code first, though, to confirm in either way. There has been some discussion on this issue over at http://bugs.python.org

[issue2275] urllib2 header capitalization

2008-07-11 Thread Hans-Peter Jansen
Hans-Peter Jansen [EMAIL PROTECTED] added the comment: Facundo, first of all: *really* nice work, thanks a lot. While I don't fully understand the issues raised lately here, especially what broke (user code). I can see, that it completely solves my original problem, which is great. While

Smal question

2008-07-10 Thread Hans Müller
to share in a project. Is there any idea to do this ? Thanks a lot Hans -- http://mail.python.org/mailman/listinfo/python-list

Re: Smal question

2008-07-10 Thread Hans Müller
Thanks a lot, you made my day. As often in python, it's really simple and useful ! Greetings Hans -- http://mail.python.org/mailman/listinfo/python-list

[issue1754483] linecache package handling

2008-07-05 Thread Hans Ulrich Niedermann
Hans Ulrich Niedermann [EMAIL PROTECTED] added the comment: Even with that patch, I'm still getting backtraces similar to this: Traceback (most recent call last): File /home/user/foo/src/foo, line 83, in module foomain(sys.argv) File /home/uli/foo/src/foo, line 79, in foomain

[issue1754483] linecache package handling

2008-06-30 Thread Hans Ulrich Niedermann
Hans Ulrich Niedermann [EMAIL PROTECTED] added the comment: The patch does not fix the underlying problem which is not limited to files named '__init__.py'. -- nosy: +ndim ___ Python tracker [EMAIL PROTECTED] http://bugs.python.org/issue1754483

[issue1068477] linecache.py::updatecache strips directory info from files

2008-06-30 Thread Hans Ulrich Niedermann
Hans Ulrich Niedermann [EMAIL PROTECTED] added the comment: The following issues appear to be the same bug to me: http://bugs.python.org/issue1068477 http://bugs.python.org/issue1309567 http://bugs.python.org/issue1754483 and are, as of 2008-06-30, unfixed in both rel25-maint

[issue1309567] linecache module returns wrong results

2008-06-30 Thread Hans Ulrich Niedermann
Hans Ulrich Niedermann [EMAIL PROTECTED] added the comment: The following issues appear to be the same bug to me: http://bugs.python.org/issue1068477 http://bugs.python.org/issue1309567 http://bugs.python.org/issue1754483 and are, as of 2008-06-30, unfixed in both rel25-maint

[issue1754483] linecache package handling

2008-06-30 Thread Hans Ulrich Niedermann
Hans Ulrich Niedermann [EMAIL PROTECTED] added the comment: The following issues appear to be the same bug to me: http://bugs.python.org/issue1068477 http://bugs.python.org/issue1309567 http://bugs.python.org/issue1754483 and are, as of 2008-06-30, unfixed in both rel25-maint

[issue1309567] linecache module returns wrong results

2008-06-30 Thread Hans Ulrich Niedermann
Changes by Hans Ulrich Niedermann [EMAIL PROTECTED]: -- components: +Library (Lib) -None versions: +Python 2.3, Python 2.4, Python 2.5, Python 2.6, Python 2.7 ___ Python tracker [EMAIL PROTECTED] http://bugs.python.org/issue1309567

Re: Hamming Distance

2008-06-27 Thread Hans Terlouw
methods. Hans -- http://mail.python.org/mailman/listinfo/python-list

Re: Do I need self and other?

2008-06-27 Thread Hans Nowak
' and 'other' are used for clarity. In this case, they indicate the vector that is operated on (self) and another vector (other). Using 'x' and 'y' would be less clear here. -- Hans Nowak (zephyrfalcon at gmail dot com) http://4.flowsnake.org/ -- http://mail.python.org/mailman/listinfo/python-list

[issue3213] pydoc -p should listen to [::] if IPv6 is supported

2008-06-26 Thread Hans Ulrich Niedermann
New submission from Hans Ulrich Niedermann [EMAIL PROTECTED]: According to pydoc --help, pydoc -p port Start an HTTP server on the given port on the local machine. The IP address pydoc binds to is not specified, thus I would expect it to either bind to the local address or to the wildcard

Re: How do I create user-defined warnings?

2008-06-17 Thread Hans Nowak
...: In [3]: warnings.warn(MyWarning(bah humbug)) /Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/site-packages/IPython/FakeModule.py:1: MyWarning: bah humbug # -*- coding: utf-8 -*- -- Hans Nowak (zephyrfalcon at gmail dot com) http://4.flowsnake.org/ -- http://mail.python.org

Re: Simple and safe evaluator

2008-06-12 Thread Hans Nowak
eval(s) File string, line 1 (2)...() ^ SyntaxError: invalid syntax ...It's primitive, but it might work for your purposes. -- Hans Nowak (zephyrfalcon at gmail dot com) http://4.flowsnake.org/ -- http://mail.python.org/mailman/listinfo/python-list

Re: Dynamically naming objects.

2008-06-07 Thread Hans Nowak
Kalibr wrote: On Jun 7, 1:20 pm, Hans Nowak [EMAIL PROTECTED] wrote: Kalibr wrote: I've been developing a small script to fiddle with classes, and came accross the following problem. Assuming I get some user input asking for a number, how would I spawn 'n' objects from a class? i.e. I have

Re: Newbie question, list comprehension

2008-06-06 Thread Hans Nowak
: fmttime = %04d-%02d-%02d %02d:%02d:%02d % localtime[:6] Hope this helps! ^_^ -- Hans Nowak (zephyrfalcon at gmail dot com) http://4.flowsnake.org/ -- http://mail.python.org/mailman/listinfo/python-list

Re: Dynamically naming objects.

2008-06-06 Thread Hans Nowak
. Any ideas? Sure. This will give you a list of n instances of user: [user() for i in range(n)] Of course, you could also use a good old for loop: for i in range(n): u = user() ...do something with u... Hope this helps! -- Hans Nowak (zephyrfalcon at gmail dot com) http://4

Re: Python and Harry Potter?

2008-06-05 Thread Hans Nowak
the alt.fan.harry-potter archives carefully, you will find at least one well-known Python core developer. :-) -- Hans Nowak (zephyrfalcon at gmail dot com) http://4.flowsnake.org/ -- http://mail.python.org/mailman/listinfo/python-list

Re: Why does python not have a mechanism for data hiding?

2008-06-04 Thread Hans Nowak
that the attributes exist, will not stop them from finding out. -- Hans Nowak (zephyrfalcon at gmail dot com) http://4.flowsnake.org/ -- http://mail.python.org/mailman/listinfo/python-list

Re: accumulator generators

2008-05-30 Thread Hans Nowak
) would not be OK. Also see: http://zephyrfalcon.org/labs/python_pitfalls.html (pitfall #6). -- Hans Nowak (zephyrfalcon at gmail dot com) http://4.flowsnake.org/ -- http://mail.python.org/mailman/listinfo/python-list

Re: Code execution in imported modules

2008-05-29 Thread Hans Nowak
when you import the module. -- Hans Nowak (zephyrfalcon at gmail dot com) http://4.flowsnake.org/ -- http://mail.python.org/mailman/listinfo/python-list

Problem with subprocess and mkstemp

2008-05-28 Thread Hans Larsen
using temporary files because a pipe hangs out with large output, such as this one. Thanks a lot, Hans Larsen -- My definition of an expert in any field is a person who knows enough about what's really going on to be scared. P. J. Plauger Computer Language, March 1983 -- http://mail.python.org

[issue2987] RFC2732 support for urlparse (e.g. http://[::1]:80/)

2008-05-27 Thread Hans Ulrich Niedermann
New submission from Hans Ulrich Niedermann [EMAIL PROTECTED]: The urlparse module's ways of splitting the location into hostname and port breaks with RFC2732 style URIs with IPv6 addresses in them: import urlparse urlparse.urlparse('http://[::1]:80/').hostname '[' urlparse.urlparse('http

[issue2987] RFC2732 support for urlparse (e.g. http://[::1]:80/)

2008-05-27 Thread Hans Ulrich Niedermann
Changes by Hans Ulrich Niedermann [EMAIL PROTECTED]: Added file: http://bugs.python.org/file10452/python-urlparse-rfc2732-rfc-list.patch __ Tracker [EMAIL PROTECTED] http://bugs.python.org/issue2987

[issue2987] RFC2732 support for urlparse (e.g. http://[::1]:80/)

2008-05-27 Thread Hans Ulrich Niedermann
Changes by Hans Ulrich Niedermann [EMAIL PROTECTED]: Added file: http://bugs.python.org/file10453/python-urlparse-rfc2732-test.patch __ Tracker [EMAIL PROTECTED] http://bugs.python.org/issue2987

[issue2987] RFC2732 support for urlparse (e.g. http://[::1]:80/)

2008-05-27 Thread Hans Ulrich Niedermann
Hans Ulrich Niedermann [EMAIL PROTECTED] added the comment: I have written this patch because urlparse could not retrieve the hostname or port components of URIs such as http://[:::192.168.13.37]/ or http://[dead:beef::1]:/ This problem happens with Python 2.5.1 in Fedora 9, and I have

Re: 2 different versions of python compiling files.

2008-05-22 Thread Hans Nowak
foo Traceback (most recent call last): File stdin, line 1, in ? ImportError: Bad magic number in foo.pyc I'm not sure what would happen if multiple Pythons try to write a .pyc file at the same time, though... -- Hans Nowak (zephyrfalcon at gmail dot org) http://4.flowsnake.org/ -- http

Re: Classmethods are evil

2008-05-17 Thread Hans Nowak
before they came along in 2.2). Personally, I don't use them... but some people like them. Different strokes, and all that... --Hans -- http://mail.python.org/mailman/listinfo/python-list

Re: save dictionary for later use?

2008-05-16 Thread Hans Nowak
() # restore it later g = open(out, rb) e = pickle.load(g) g.close() e {'this': 42, 'other': 17, 'that': 101} Also see http://docs.python.org/lib/pickle-example.html. Hope this helps! --Hans -- http://mail.python.org/mailman/listinfo/python-list

Re: can't delete from a dictionary in a loop

2008-05-16 Thread Hans Nowak
of processes... I'll leave it others, presumably more knowledgable, to comment on that. :-) But I can tell you how to solve the immediate problem: for pid in procs_dict.keys(): ... Hope this helps! --Hans -- http://mail.python.org/mailman/listinfo/python-list

Re: can't delete from a dictionary in a loop

2008-05-16 Thread Hans Nowak
[EMAIL PROTECTED] wrote: On 16 mai, 23:34, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: On 16 mai, 23:28, Hans Nowak [EMAIL PROTECTED] wrote: Dan Upton wrote: for pid in procs_dict: (snip) for pid in procs_dict.keys(): I'm afraid this will do the same exact thing. A for loop on a dict

Re: SImple python print question

2008-05-16 Thread Hans Nowak
(because it's held in the buffer). To force the output to be displayed, use flush(): print -#- executing: %s % section, sys.stdout.flush() ...tests here... Hope this helps! --Hans -- http://mail.python.org/mailman/listinfo/python-list

[issue2275] urllib2 header capitalization

2008-03-30 Thread Hans-Peter Jansen
Hans-Peter Jansen [EMAIL PROTECTED] added the comment: But should not this patch be handled in a way wherein. key.capitalize() is just replaced by key.upper()? Hmm, are you sure? hello.upper() 'HELLO' but the issue is with values containing dashes: 'accept-charset'.capitalize() 'Accept

[issue2275] urllib2 header capitalization

2008-03-30 Thread Hans-Peter Jansen
Hans-Peter Jansen [EMAIL PROTECTED] added the comment: Hi Senthil, that looks promising, and the title() trick is nice, as it fixes my issue.. Thanks, Pete __ Tracker [EMAIL PROTECTED] http://bugs.python.org/issue2275

Problem with format string and unicode

2008-03-28 Thread Hans Martin
Hi, this is probably a trivial problem, but a google search for python and unicode and format string gives too many hits: If I specify e.g. %20s in a format string and the string value contains UTF-8 stuff (differing number of bytes per character), the length of the resulting string (in

Re: Get actual call signature?

2008-03-19 Thread Hans Georg Krauthäuser
') c.fun(5, 'something') a=c.fun a(4) Best Regards Hans Georg -- http://mail.python.org/mailman/listinfo/python-list

Re: keyboard interrupt

2008-03-19 Thread Hans Georg Krauthäuser
with the 0x00FF charCodeMask; this # number is converted to an ASCII character with chr() and # returned # (what,msg,when,where,mod)=Carbon.Evt.GetNextEvent(0x0008) [1] return chr(msg 0x00FF) Best regards Hans Georg -- http://mail.python.org

Re: Speaking Text

2008-03-19 Thread Hans Georg Krauthäuser
in Windows and/or Linux? (If it's there in Linux presumably it only works if there happens to be a speech engine available...) David C. Ullrich In Windows - pyTTS http://www.mindtrove.info/articles/pytts.html Regards Hans Georg -- http://mail.python.org/mailman/listinfo/python-list

[issue2275] urllib2 header capitalization

2008-03-11 Thread Hans-Peter Jansen
New submission from Hans-Peter Jansen [EMAIL PROTECTED]: The urllib2 behavior related to headers is - hmm - improvable. It simply capitalize() the key, which leads to funny results like: Accept-charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7 while this is seemingly conforming to the specs, it's simply

Re: at what complexity, a comparison fails ?

2007-12-31 Thread Hans Nowak
expect. I'm not sure what ndarray and color are, but check their comparison methods (you know, __cmp__, __lt__, __eq__, etc). (If that isn't clear, please see http://effbot.org/pyref/__lt__.htm.) --Hans -- http://mail.python.org/mailman/listinfo/python-list

Re: How to read a binary file into a mysql table

2007-12-18 Thread Hans Müller
Sorry, I found the mistake: There is more than one blob type, blob as a default stores only 64k of data. LONGBLOB has a 4G limit which is Ok for my purposes. Happy Christmas to all, Hans -- http://mail.python.org/mailman/listinfo/python-list

Re: How to read a binary file into a mysql table

2007-12-18 Thread Hans Müller
to solve this ? Greetings Hans -- http://mail.python.org/mailman/listinfo/python-list

How to read a binary file into a mysql table

2007-12-14 Thread Hans Müller
a working idea how to get binary file into a blob using MySQLdb and python ?! System is SuSE 10.0 Linux with python 2.5.1, current MySQLdb version, MySQL is: 5.0.26 Thanks a lot! Greetings Hans -- http://mail.python.org/mailman/listinfo/python-list

DBApi Question with MySQL

2007-12-12 Thread Hans Müller
all changes, so all changes become visible here and only here. Thanks a lot, Greetings Hans -- http://mail.python.org/mailman/listinfo/python-list

Version 0.6.0 of CodeInvestigator

2007-11-08 Thread Hans Moleman
CodeInvestigator version 0.6.0 was released on November 8. This version adds support for input() and raw_input() functions. The main changes: * The 'Details' button on the file selection screen gives access to statistics, stdin and stdout for the running program. Control Z

Dr. Wallach...

2007-10-27 Thread Hans Peter Tkany
Im Tierfutter sind 41 wichtige Nährstoffe... In der Babynahrung sind nur 11 der wichtigen Nährstoffe... Unsere Nahrung im Supermarkt enthält noch weniger lebenswichtige Mineralien und Vitamine... Erfahren Sie kostenlos die schockierende Wahrheit in Das Geheimniss der 91 essentiellen

Re: win32event.WaitForInputIdle() returns too soon

2007-06-30 Thread Hans
[EMAIL PROTECTED] schreef in bericht news:[EMAIL PROTECTED] On Jun 29, 3:03 pm, Hans [EMAIL PROTECTED] wrote: Gabriel Genellina [EMAIL PROTECTED] schreef in berichtnews:[EMAIL PROTECTED] En Thu, 28 Jun 2007 19:15:40 -0300, Hans [EMAIL PROTECTED] escribió: I'm sending keyboard

Re: win32event.WaitForInputIdle() returns too soon

2007-06-30 Thread Hans
Gabriel Genellina [EMAIL PROTECTED] schreef in bericht news:[EMAIL PROTECTED] En Thu, 28 Jun 2007 19:15:40 -0300, Hans [EMAIL PROTECTED] escribió: I'm sending keyboard and mouse events to a seperate windows application. I use win32event.WaitForInputIdle() before calling e.g

Re: win32event.WaitForInputIdle() returns too soon

2007-06-29 Thread Hans
Gabriel Genellina [EMAIL PROTECTED] schreef in bericht news:[EMAIL PROTECTED] En Thu, 28 Jun 2007 19:15:40 -0300, Hans [EMAIL PROTECTED] escribió: I'm sending keyboard and mouse events to a seperate windows application. I use win32event.WaitForInputIdle() before calling e.g

win32event.WaitForInputIdle() returns too soon

2007-06-28 Thread Hans
() which calls the one in win32event() and adds an extra sleep(0.1). As expected, this isn't robust. Is this a known issue of win32event.WaitForInputIdle() ? Is it a Windows issue? Is more involved (but not documented in the Python docs)? Any ideas? Thanks Hans -- http://mail.python.org

Pyrex: problem with blanks in string

2007-06-04 Thread Hans Terlouw
): pass When I substitute the blanks in the string for something else, then the problem disappears: class Axis: axtype = unknown_type_of_axis def __init__(self): pass Does anybody have an idea? Hans Terlouw -- http://mail.python.org/mailman/listinfo/python-list

trouble with generators

2007-05-10 Thread Hans-Peter Jansen
Hi Pythonistas, I'm stuck in a maze of new style classes and generators. While I love the concepts, I obviously didn't grok them throughout. I'm trying to generate a bunch of similar classes, where some are contained in list attributes of others, e.g.: class A: def __init__(self):

Re: trouble with generators

2007-05-10 Thread Hans-Peter Jansen
Hi Diez, first, thanks for your comprehensive answer. Diez B. Roggisch wrote: Hans-Peter Jansen schrieb: I'm trying to generate a bunch of similar classes, where some are contained in list attributes of others, e.g.: All your code below shows that you don't create classes

Re: trouble with generators

2007-05-10 Thread Hans-Peter Jansen
Marc 'BlackJack' Rintsch wrote: In [EMAIL PROTECTED], Hans-Peter Jansen wrote: class Gen(object): def records(self, cls): for i in range(3): setattr(cls, id, %s%s % (cls.__doc__, i)) yield cls […] class GenA(Gen): def __init__(self

How to print the variable?

2007-02-14 Thread Hans Schwaebli
Hi, am am a Python beginner with Java knowledge background. Infact I need to use Jython. My first beginner question is how to determine of what type a variable is? In program which supports Jython there is a variable called rc available. I can use the methods on that variable

Downloading images with python

2006-10-20 Thread Hans Olav Hygen
On 23. of October last year a the follwing was posted to this group: htmlSource=urllib.urlopen(http://www.godandscience.org/images/nebula.jpg;) # Read from the object, storing the page's contents in 's'. s = htmlSource.read() htmlSource.close() myfile = open(myfile.jpg, w) myfile.write(s)

Re: Wax: problem subclassing TextBox

2006-10-18 Thread Hans Nowak
these; this will probably be solved in the next release. -- Hans Nowak http://zephyrfalcon.org/ -- http://mail.python.org/mailman/listinfo/python-list

Re: Is it possible to save a running program and reload next time ?

2006-09-22 Thread Hans Georg Krauthaeuser
[EMAIL PROTECTED] wrote: Hans Georg Krauthaeuser wrote: [EMAIL PROTECTED] wrote: Can objects be saved and reloaded by Pickle ? I have tried but no success. Yes, that's the intended use of pickle/cPickle. There are examples in the docs: http://docs.python.org/lib/module

Re: Is it possible to save a running program and reload next time ?

2006-09-21 Thread Hans Georg Krauthaeuser
[EMAIL PROTECTED] wrote: Can objects be saved and reloaded by Pickle ? I have tried but no success. Yes, that's the intended use of pickle/cPickle. There are examples in the docs: http://docs.python.org/lib/module-pickle.html What have you tried and what didn't work? Hans Georg -- http

Defining constant strings

2006-08-27 Thread Hans
Hi, I want to define a couple of constant strings, like in C: #define mystring "This is my string" or using a const char construction. Is this really not possible in Python? Hans -- http://mail.python.org/mailman/listinfo/python-list

How to force a thread to stop

2006-07-22 Thread Hans
) ? if thread.isAlive(): # thread has probably encountered a problem and hangs # What should be here to stop thread ?? Note that I don't want to change the target (too much), as many possible targets exist, together thousands of lines of code. Thanks, Hans -- http://mail.python.org/mailman/listinfo

Re: pickling multiple dictionaries

2006-05-24 Thread Hans Georg Krauthaeuser
]:d1 Out[12]:{'a': 1} In [13]:d2=pickle.load(pfile) In [14]:d2 Out[14]:{'b': 2} If your data is *really* large, have a look to PyTables (http://www.pytables.org/moin). Regards, Hans Georg -- http://mail.python.org/mailman/listinfo/python-list

Re: How to determine if a line of python code is a continuation of the line above it

2006-04-09 Thread Hans Georg Krauthaeuser
, c) Regards Hans Georg -- http://mail.python.org/mailman/listinfo/python-list

Re: FIR filtering

2006-03-15 Thread Hans Georg Krauthaeuser
LabWINC wrote: Hi all, i'm looking for a module to implement a digital FIR filter! Can anyone help me? Thanks, Vincent gnuradio? Hans Georg -- http://mail.python.org/mailman/listinfo/python-list

Re: FIR filtering

2006-03-15 Thread Hans Georg Krauthaeuser
LabWINC wrote: What's gnuradio? http://www.gnu.org/software/gnuradio/ It's a c++ lib with a python wrapper. BTW, thats the first hit in google ... Hans Georg -- http://mail.python.org/mailman/listinfo/python-list

Re: FIR filtering

2006-03-15 Thread Hans Georg Krauthaeuser
LabWINC wrote: I can't understand how gnuradio can help me... I find scipy is the only way to implement a good FIR. Well, then do it with scipy... gnuradio has a module for FIR. I never used it. I just wanted to share that information. Hans Georg -- http://mail.python.org/mailman/listinfo

Re: RPy / R

2006-02-07 Thread Hans Georg Krauthaeuser
... Hans Georg -- http://mail.python.org/mailman/listinfo/python-list

Re: [OT] no goto (WAS: Python code written in 1998...)

2006-01-20 Thread Hans Georg Krauthaeuser
/spass/vatical/vatical.html It's in German only and I'm not aware of a English translation. Please be aware that content of that page is not political correct and may offend your religious sensibilities. Hans Georg -- http://mail.python.org/mailman/listinfo/python-list

Re: Arithmetic sequences in Python

2006-01-19 Thread Hans Nowak
... but in reality that seems to be a matter of taste and priorities. Pascal, for example, has a set literal, but no list literal; in fact, it doesn't even have a built-in list type. -- Hans Nowak http://zephyrfalcon.org/ -- http://mail.python.org/mailman/listinfo/python-list

Re: Spelling mistakes!

2006-01-11 Thread Hans Nowak
it is true that unit tests might not find the misspelling *directly* (i.e. you rarely test if you have misspelled something), your tests should definitely show unexpected behavior and results, if that attribute is of any importance. Otherwise there's a loophole in your tests. :-) -- Hans Nowak

Re: - E04 - Leadership! Google, Guido van Rossum, PSF

2006-01-09 Thread Hans Nowak
people have problems entering that same environment and privileged conditions as yourself. This attitude is very common and needs only some kind Blair-alike kind of selfhypnosis in order to effectively not being aware of lying. Tony Blair, or the Blair Witch project? -- Hans Nowak http

<    1   2   3   4   5   6   7   >