Re: C-API: Extract information from function object

2010-03-25 Thread Stefan Behnel
Gabriel Genellina, 24.03.2010 17:49: En Wed, 24 Mar 2010 12:09:27 -0300, moerchendiser2k3 escribió: I have a reference to a function and would like to know how to extract information from a function object. Information I am looking for: line and file where this function is from. PyObject_Call

Re: sum for sequences?

2010-03-25 Thread Steven D'Aprano
On Wed, 24 Mar 2010 23:50:23 -0700, TomF wrote: > On 2010-03-24 14:07:24 -0700, Steven D'Aprano > said: >> On Wed, 24 Mar 2010 15:29:07 +, kj wrote: >> >>> Is there a sequence-oriented equivalent to the sum built-in? E.g.: >>> >>> seq_sum(((1, 2), (5, 6))) --> (1, 2) + (5, 6) --> (1, 2, 5,

Saving a page loaded using the webbrowser library?

2010-03-25 Thread Dr. Benjamin David Clarke
Does anyone know of a way to save the a loaded web page to file after opening it with a webbrowser.open() call? Specifically, what I want to do is get the raw HTML from a web page. This web page uses Javascript. I need the resulting HTML after the Javascript has been run. I've seen a lot about try

Re: Is there any library for indexing binary data?

2010-03-25 Thread Irmen de Jong
On 3/25/10 4:28 AM, 甜瓜 wrote: Howdy, Recently, I am finding a good library for build index on binary data. Xapian& Lucene for python binding focus on text digestion rather than binary data. Could anyone give me some recommendation? Is there any library for indexing binary data no matter whether

Re: Saving a page loaded using the webbrowser library?

2010-03-25 Thread Irmen de Jong
On 3/25/10 8:41 AM, Dr. Benjamin David Clarke wrote: Does anyone know of a way to save the a loaded web page to file after opening it with a webbrowser.open() call? Specifically, what I want to do is get the raw HTML from a web page. This web page uses Javascript. I need the resulting HTML after

Re: Is there any library for indexing binary data?

2010-03-25 Thread Paul Rubin
甜瓜 writes: > Well, Database is not proper because 1. the table is very big (~10^9 > rows) 2. we should support very fast *simple* query that is to get > value corresponding to single key (~10^7 queries / second). Just one numeric key/value pair in each row? What's wrong with universal hashing?

how to display variables down a stackdump when an exception occurred

2010-03-25 Thread News123
Hi, I captured a piece of code with a try except statement: In the except part I display a stackdump try: domyxmlrpcstuff() except Exception as e: import traceback ex_type,ex_value,e_b = sys.exc_info() tbstring = traceback.format_exc() print '%s%s:%s:%s' % \ (msg

xpat error in xmlrp client. How to inspect data.

2010-03-25 Thread News123
Hi, I'm havign a small xmlrpc client, which works normally fine. (xmlrpc via https) Sometimes however I receive an Exception about an expat error. The output, that I receive is: File "C:\mycode\myrpcclient.py", line 63, in upload_chunk rslt = myrpcclient.call() File "C:\Python26\lib\xml

Re: Is there any library for indexing binary data?

2010-03-25 Thread 甜瓜
Thank you Rubin! Let me have a look at Judy. It seems good at first glance. -- ShenLei 2010/3/25 Paul Rubin : > 甜瓜 writes: >> Well, Database is not proper because 1. the table is very big (~10^9 >> rows) 2. we should support very fast *simple* query that is to get >> value corresponding to singl

Re: Is it possible to use re2 from Python?

2010-03-25 Thread Tim Wintle
On Wed, 2010-03-24 at 10:44 -0700, _wolf wrote: > yes we can! http://github.com/facebook/pyre2 I had made a thin wrapper experiment with here - looks like the version he's shipped is relatively complete and compatible with the re module though. I'll be interested in seeing how well it performs -

Re: Is there any library for indexing binary data?

2010-03-25 Thread 甜瓜
Thank you irmen. I will take a look at pytable. FYI, let me explain the case clearly. Originally, my big data table is simply array of Item: struct Item { long id;// used as key BYTE payload[LEN]; // corresponding value with fixed length }; All items are stored in one file by using

Re: threads (specifically timers) and releasing resources

2010-03-25 Thread Tim Golden
On 25/03/2010 02:31, Alex Hall wrote: Okay, I have my program and it has three different modes (there will be more than that). Each mode will have a timer attached to it. If the mode remains active and the timer runs out, a function specific to that mode is called. If that mode is switched away f

from import and __init__.py

2010-03-25 Thread egbert
When I do 'from some_package import some_module' the __init__.py of some_package will be run. However, there will not be anything like a package-module, and the effects of __init__.py seem all to be lost. Is that true ? Or can I still do something useful with __init__.py ? e -- Egbert Bouwman

Re: the Python Foundation

2010-03-25 Thread Rami Chowdhury
On 2010-03-24 16:22, Paul Rubin wrote: > "Steve Holden, Chairman, PSF" writes: > > We have also registered the trademark "Python" for use in reference to > > computer programming languages, thereby ensuring that we can take action > > should some ill-advised individual or organization decide to pr

Re: from import and __init__.py

2010-03-25 Thread Steve Holden
egbert wrote: > When I do 'from some_package import some_module' > the __init__.py of some_package will be run. > However, there will not be anything like a package-module, > and the effects of __init__.py seem all to be lost. Is that true ? > Or can I still do something useful with __init__.py ?

Re: chroot fails with mount point passed to subprocess.Popen?

2010-03-25 Thread newton10471
Hi Alf, After doing some more research, including the character-by-character comparison you suggested (thank you!), I was able to get things working the way I wanted using the following: def getInstalledKernelVersion(mountPoint): linuxFsRoot = mountPoint + "/root" installedKernelVersionRe

Re: chroot fails with mount point passed to subprocess.Popen?

2010-03-25 Thread newton10471
Hi Alf, After doing some more research, including the character-by-character comparison you suggested (thank you!), I was able to get things working the way I wanted using the following: def getInstalledKernelVersion(mountPoint): linuxFsRoot = mountPoint + "/root" installedKernelVersionRe

Re: cxfreeze on ubuntu 9.10

2010-03-25 Thread Sandy
I used cxFreeze without any problem on Ubuntu 9.10 32 bit version. I tried it on a wxPython gui script and it works fine though I did'n use any setup file. Just try cxFreeze executable (should be in /usr/bin/) instead of setup file. $/usr/bin/cxFreeze my_script.py --target-dir=/what_ever_dir/ wha

Advanced Python Programming Oxford Lectures [was: Re: *Advanced* Python book?]

2010-03-25 Thread Ethan Furman
Michele Simionato wrote: On Jan 16, 9:27 pm, mk wrote: Hello everyone, I looked for it I swear, but just can't find it. Most Python books seem to focus on examples of how to call functions from standard library. I don't need that, I have online Python documentation for that. I mean really a

Re: sum for sequences?

2010-03-25 Thread Neil Cerutti
On 2010-03-25, Steven D'Aprano wrote: >> You might not want to be so glib. The sum doc sure doesn't >> sound like it should work on lists. >> >> Returns the sum of a sequence of numbers (NOT strings) plus the >> value of parameter 'start' (which defaults to 0). > > What part of that sugg

Re: sum for sequences?

2010-03-25 Thread Stefan Behnel
Neil Cerutti, 25.03.2010 13:37: On 2010-03-25, Steven D'Aprano wrote: You might not want to be so glib. The sum doc sure doesn't sound like it should work on lists. Returns the sum of a sequence of numbers (NOT strings) plus the value of parameter 'start' (which defaults to 0). Wha

Does a tiny Python distribution exist?

2010-03-25 Thread Johny
Does anyone know if there is a tiny Python distribution available running in a Linux environment? -- http://mail.python.org/mailman/listinfo/python-list

Re: sum for sequences?

2010-03-25 Thread Alf P. Steinbach
* Neil Cerutti: On 2010-03-25, Steven D'Aprano wrote: You might not want to be so glib. The sum doc sure doesn't sound like it should work on lists. Returns the sum of a sequence of numbers (NOT strings) plus the value of parameter 'start' (which defaults to 0). What part of that sugg

Re: Advice needed on parallel processing in python

2010-03-25 Thread bobicanprogram
On Mar 24, 1:13 pm, Jon Clements wrote: > On 24 Mar, 15:27, Glazner wrote: > > > > > Hi! > > > I need to replace an app that does number crunching over a local > > network. > > it have about 50 computers as slaves > > each computer needs to run COM that will do the "job" > > right now the system

Re: Python is cool!!

2010-03-25 Thread bobicanprogram
On Mar 23, 11:55 am, Jose Manuel wrote: > I have been learning Python, and it is amazing I am using the > tutorial that comes with the official distribution. > > At the end my goal is to develop applied mathematic in engineering > applications to be published on the Web, specially on app. ori

Re: Advanced Python Programming Oxford Lectures [was: Re: *Advanced* Python book?]

2010-03-25 Thread Michele Simionato
On Mar 25, 1:28 pm, Ethan Furman wrote: > > Michele, > > Was wondering if you'd had a chance to re-post your lectures -- just did > a search for them and came up empty, and I would love to read them! > > Many thanks in advance! Oops, I forgot! I will try to make them available soon. -- http://ma

Re: Advice Criticism on Python App

2010-03-25 Thread Bruno Desthuilliers
Steven D'Aprano a écrit : On Wed, 24 Mar 2010 21:14:23 -0700, Tim Roberts wrote: Jimbo wrote: class stock: code = "" purchasePrice= 0 purchaseQuantity = 0 price= [] # list of recent prices recentBid= [] # list of recent bids for stock

Re: threads (specifically timers) and releasing resources

2010-03-25 Thread Alex Hall
Thanks, this should work. On 3/25/10, Tim Golden wrote: > On 25/03/2010 02:31, Alex Hall wrote: >> Okay, I have my program and it has three different modes (there will >> be more than that). Each mode will have a timer attached to it. If the >> mode remains active and the timer runs out, a functi

Re: Python is cool!!

2010-03-25 Thread Bruno Desthuilliers
Jose Manuel a écrit : I have been learning Python, and it is amazing I am using the tutorial that comes with the official distribution. At the end my goal is to develop applied mathematic in engineering applications to be published on the Web, specially on app. oriented to simulations and c

Re: Does a tiny Python distribution exist?

2010-03-25 Thread cassiope
On Mar 25, 5:45 am, Johny wrote: > Does anyone know if there is a tiny Python distribution available > running in a Linux environment? Debian has a package: "python-minimal". HTH... -- http://mail.python.org/mailman/listinfo/python-list

nested threading

2010-03-25 Thread Omer Ihsan
is there anything as "nested threading"that is, call a thread from within a thread. in this case how will thread locking take place. for example initially there were two functions that were called using threading.Thread. these wont get unlocked unless both of them are done with whatever they n

Re: Does a tiny Python distribution exist?

2010-03-25 Thread Tim Golden
On 25/03/2010 15:10, cassiope wrote: On Mar 25, 5:45 am, Johny wrote: Does anyone know if there is a tiny Python distribution available running in a Linux environment? Debian has a package: "python-minimal". HTH... tinypy? http://www.tinypy.org/ TJG -- http://mail.python.org/mailman/list

Represent object type as

2010-03-25 Thread Jason
Hi, I want to send objects (new style) over DBUS. DBUS can only send fairly primitive types[1] so I turn my objects into dicts and send that. I'm reusing the __getstate__ function I wrote for pickling like so: def __getstate__(self): attrs = self.__dict__.copy() return attrs

Re: Represent object type as

2010-03-25 Thread Bruno Desthuilliers
Jason a écrit : Hi, I want to send objects (new style) over DBUS. DBUS can only send fairly primitive types[1] so I turn my objects into dicts and send that. I'm reusing the __getstate__ function I wrote for pickling like so: def __getstate__(self): attrs = self.__dict__.copy()

ANN: Pymazon 0.1.1 Released

2010-03-25 Thread Chris Colbert
I'm happy to announce the release of Pymazon 0.1.1! This release brings a big enhancement in the form of PyGtk support in addition to the PyQt4 and Command line interfaces already available. A special thanks to Ray Meyers for his gtk commits! Pymazon Changelog 0.1.1 - - Added support for com

Re: from import and __init__.py

2010-03-25 Thread Terry Reedy
On 3/25/2010 6:16 AM, egbert wrote: When I do 'from some_package import some_module' the __init__.py of some_package will be run. However, there will not be anything like a package-module, and the effects of __init__.py seem all to be lost. Is that true ? No. If you do from sys import modules

ANN: ActivePython 2.6.5.12 and 3.1.2.3 are now available

2010-03-25 Thread Sridhar Ratnakumar
We are pleased to announce the availability of both ActivePython 2.6.5.12 and ActivePython 3.1.2.3. http://www.activestate.com/activepython/ Here is what you should know about these two releases: PyWin32: PyWin32 is now included in the 64-bit & Python3 builds! Since we recently updated ou

Repetition of work in Jython

2010-03-25 Thread Andrey Fedorov
Hi all, So from what I understand, Jython translates Python code into JVM byte code. Does anyone know why this was chosen instead of translating Python bytecode to JVM bytecode directly? It seems that it would be a lot easier to get Jython up-to-speed if there could be some "shared components" bet

Re: Castrated traceback in sys.exc_info()

2010-03-25 Thread Andreas Löscher
> As you see, the traceback only starts from function c, which handles the > exception. > It doesn't show main(), a() and b(), which might however be (and are, in > my case) critical to diagnose the severity of the problem (since many > different paths would lead to calling c()). This results

Re: Repetition of work in Jython

2010-03-25 Thread Steve Holden
Andrey Fedorov wrote: > Hi all, > > So from what I understand, Jython translates Python code into JVM byte > code. Does anyone know why this was chosen instead of translating Python > bytecode to JVM bytecode directly? It seems that it would be a lot > easier to get Jython up-to-speed if there cou

Re: Possible? Python 2.6.x and PythonWin on 64-bit Windows 7

2010-03-25 Thread Sridhar Ratnakumar
On 2010-02-09, at 2:49 PM, Sridhar Ratnakumar wrote: > > On 2010-02-07, at 5:02 PM, escalation746 wrote: > >> Andrej Mitrovic wrote: >> >>> Perhaps you've accidentally downloaded the wrong version of PythonWin? >> >> Erk, yes, my bad. >> >> Thanks for the quick help! Though I still wonder wh

Re: Is there any library for indexing binary data?

2010-03-25 Thread Irmen de Jong
On 25-3-2010 10:55, 甜瓜 wrote: > Thank you irmen. I will take a look at pytable. > FYI, let me explain the case clearly. > > Originally, my big data table is simply array of Item: > struct Item > { > long id;// used as key > BYTE payload[LEN]; // corresponding value with fixed lengt

Improved timedelta attributes/methods

2010-03-25 Thread Christian Ştefănescu
Hello dear Python-wielding developers! I generally like date/time handling in Python very much, especially how date operations result in Timedelta objects. But I find it somewhat impractical, that you can only get days, seconds and mi

Re: RELEASED Python 2.6.5

2010-03-25 Thread Peter
On Wed, 24 Mar 2010 23:22:01 +0100, Martin v. Loewis wrote: >> Is anyone else having trouble with the 2.6.5 Windows x86 installer? > > Not me. Run > > msiexec /i py...msi /l*v py.log > > and inspect py.log for errors (post it to bugs.python.org if you can't > determine the cause of the problems

Re: sum for sequences?

2010-03-25 Thread Steven D'Aprano
On Thu, 25 Mar 2010 14:02:05 +0100, Alf P. Steinbach wrote: > * Neil Cerutti: >> On 2010-03-25, Steven D'Aprano >> wrote: You might not want to be so glib. The sum doc sure doesn't sound like it should work on lists. Returns the sum of a sequence of numbers (NOT strings)

Revisiting Generators and Subgenerators

2010-03-25 Thread Winston
I have been reading PEP 380 because I am writing a video game/ simulation in Jython and I need cooperative multitasking. PEP 380 hits on my problem, but does not quite solve it for me. I have the following proposal as an alternative to PEP380. I don't know if this is the right way for me to introdu

Revisiting Generators and Subgenerators

2010-03-25 Thread Winston
Here's my proposal again, but hopefully with better formatting so you can read it easier. -Winston - Proposal for a new Generator Syntax in Python 3K-- A Baton object for generators to allow subfunction to yield, and to make them symetric. Abstract Generators can be

Create a class at run-time

2010-03-25 Thread Michel
Hi everyone, I'm trying to dynamically create a class. What I need is to define a class, add methods to it and later instantiate this class. Methods need to be bound to the instance though, and that's my problem. Here is what I have so far: method_template = "def test_foo(self):\ #actual test

XPCOM/hulahop: waiting for JavaScript finished?

2010-03-25 Thread John Bokma
I am playing a bit with hulahop/xpcom using the code found at http://www.advogato.org/article/1014.html but have no idea how to check if some JavaScript has finised running. The _loaded method of Browser is called after the document has finished loading, but as far as I can tell this doesn't mea

Re: Create a class at run-time

2010-03-25 Thread Michiel Overtoom
On 2010-03-25 23:00, Michel wrote: I'm trying to dynamically create a class. What I need is to define a class, add methods to it and later instantiate this class. Methods need to be bound to the instance though, and that's my problem. Maybe this snippet is of any help? import functools class

Re: from import and __init__.py

2010-03-25 Thread egbert
On Thu, Mar 25, 2010 at 12:43:13PM -0400, Terry Reedy wrote: > On 3/25/2010 6:16 AM, egbert wrote: > >When I do 'from some_package import some_module' > >the __init__.py of some_package will be run. > >However, there will not be anything like a package-module, > >and the effects of __init__.py see

Re: Create a class at run-time

2010-03-25 Thread Patrick Maupin
On Mar 25, 5:00 pm, Michel wrote: > Hi everyone, > > I'm trying to dynamically create a class. What I need is to define a > class, add methods to it and later instantiate this class. Methods > need to be bound to the instance though, and that's my problem. Here > is what I have so far: Well, you

Python database of plain text editable by notepad or vi

2010-03-25 Thread James Harris
I am looking to store named pieces of text in a form that can be edited by a standard editor such as notepad (under Windows) or vi (under Unix) and then pulled into Python as needed. The usual record locking and transactions of databases are not required. Another way to look at it is to treat the

Re: Python database of plain text editable by notepad or vi

2010-03-25 Thread jkn
Kirbybase is one possibility. http://pypi.python.org/pypi/KirbyBase/1.9 J^n -- http://mail.python.org/mailman/listinfo/python-list

Re: Python database of plain text editable by notepad or vi

2010-03-25 Thread Jon Clements
On 25 Mar, 22:40, James Harris wrote: > I am looking to store named pieces of text in a form that can be > edited by a standard editor such as notepad (under Windows) or vi > (under Unix) and then pulled into Python as needed. The usual record > locking and transactions of databases are not requir

Re: nested threading

2010-03-25 Thread Chris Colbert
Spawning a thread from within a thread works just fine. Calling thread.start() is a non-blocking function and returns immediately. On Thu, Mar 25, 2010 at 11:23 AM, Omer Ihsan wrote: > is there anything as "nested threading"that is, call a thread from > within a thread. > in this case how wi

Re: Sniffing encoding type by looking at file BOM header

2010-03-25 Thread Lawrence D'Oliveiro
In message , pyt...@bdurham.com wrote: > BOM_UTF8 = '\xef\xbb\xbf' Since when does UTF-8 need a BOM? -- http://mail.python.org/mailman/listinfo/python-list

Re: Sniffing encoding type by looking at file BOM header

2010-03-25 Thread Irmen de Jong
On 26-3-2010 0:16, Lawrence D'Oliveiro wrote: In message, pyt...@bdurham.com wrote: BOM_UTF8 = '\xef\xbb\xbf' Since when does UTF-8 need a BOM? It doesn't, but it is allowed. Not recommended though. Unfortunately several tools, such as notepad.exe, have a tendency of silently adding it

Don't understand behavior; instance form a class in another class' instance

2010-03-25 Thread Martin P. Hellwig
Hi all, When I run the following snippet (drastically simplified, to just show what I mean): >> import platform, sys class One(object): def __init__(self): self.one = True def change(self): self.one = False class Two(object): def __init__(self): self._inst

Re: Don't understand behavior; instance form a class in another class' instance

2010-03-25 Thread Christian Heimes
Martin P. Hellwig schrieb: > What I don't understand why in the second test, the last boolean is True > instead of (what I expect) False. > Could somebody enlighten me please as this has bitten me before and I am > confused by this behavior. Hint: TEST2.one is not a reference to TEST2.__instance

Re: Don't understand behavior; instance form a class in another class' instance

2010-03-25 Thread Martin P. Hellwig
On 03/25/10 23:41, Christian Heimes wrote: Martin P. Hellwig schrieb: What I don't understand why in the second test, the last boolean is True instead of (what I expect) False. Could somebody enlighten me please as this has bitten me before and I am confused by this behavior. Hint: TEST2.one i

python logging writes an empty file

2010-03-25 Thread Ovidiu Deac
Hi, I have the following situation: My application uses nosetests to discover&run the unittests. I pass the log configuration file as --logging-config=logging.conf Everything works just fine, the logs are printed as required by the configuration file which makes me happy. I take this as a sign th

Re: Revisiting Generators and Subgenerators

2010-03-25 Thread Cameron Simpson
On 25Mar2010 14:39, Winston wrote: | Here's my proposal again, but hopefully with better formatting so you | can read it easier. Having quickly read the Abstract and Motivation, why is this any better than a pair of threads and a pair of Queue objects? (Aside from co-routines being more lightweig

Traversing through Dir()

2010-03-25 Thread Andrej Mitrovic
I would like to traverse through the entire structure of dir(), and write it to a file. Now, if I try to write the contents of dir() to a file (via pickle), I only get the top layer. So even if there are lists within the returned list from dir(), they get written as a list of strings to the file.

Re: Revisiting Generators and Subgenerators

2010-03-25 Thread Winston Wolff
Coroutines achieve very similar things to threads, but avoid problems resulting from the pre-emptive nature of threads. Specifically, a coroutine indicates where it will yield to the other coroutine. This avoids lots of problems related to synchronization. Also the lightweight aspect is apparent

Re: Represent object type as

2010-03-25 Thread Jason
On Mar 26, 12:00 am, Bruno Desthuilliers wrote: >            attrs['type'] = type(self) > > Do the same thing with less work !-) Ah, silly me :P >      attrs['__typename__'] = type(self).__name__ That's exactly what I needed — I was not aware of the "__name__" attribute. > Warning: won't be ve

Re: Traversing through Dir()

2010-03-25 Thread Shashwat Anand
have you tried os.walk() ? On Fri, Mar 26, 2010 at 5:55 AM, Andrej Mitrovic wrote: > I would like to traverse through the entire structure of dir(), and > write it to a file. > > Now, if I try to write the contents of dir() to a file (via pickle), I > only get the top layer. So even if there are

Automatic import ?

2010-03-25 Thread C. B.
Hi everyone, I'm currently coding a C library which provides several modules and objects. Let's say that some of these objects are classes called AAA and BBB. The constructor of AAA needs to get BBB as argument. So I can run the following code : from mymodule import AAA from mymodule import BBB

Re: Don't understand behavior; instance form a class in another class' instance

2010-03-25 Thread Rhodri James
On Fri, 26 Mar 2010 00:06:06 -, Martin P. Hellwig wrote: On 03/25/10 23:41, Christian Heimes wrote: Martin P. Hellwig schrieb: What I don't understand why in the second test, the last boolean is True instead of (what I expect) False. Could somebody enlighten me please as this has bitt

Re: Is there any library for indexing binary data?

2010-03-25 Thread 甜瓜
Many thanks for your kind reply. As you mentioned, a sparse array may be the best choice. Storing offset rather than payload itself can greatly save memory space. 1e7 queries per second is my ideal aim. But 1e6 must be achieved. Currently I have implemented 5e6 on one PC (without incremental index

Re: Create a class at run-time

2010-03-25 Thread I V
On Thu, 25 Mar 2010 15:00:35 -0700, Michel wrote: > I'm trying to dynamically create a class. What I need is to define a > class, add methods to it and later instantiate this class. Methods need > to be bound to the instance though, and that's my problem. Here is what > I have so far: I'm not enti

Re: Don't understand behavior; instance form a class in another class' instance

2010-03-25 Thread Martin P. Hellwig
On 03/26/10 01:10, Rhodri James wrote: Pretty much. In the sense that you're thinking of, every assignment works that way, even the initial "TEST1 = One()". Assignment binds names to objects, though you have to be aware that names can be such exotic things as "t", "a[15]" or "TEST2.__instance_o

Re: Is there any library for indexing binary data?

2010-03-25 Thread John Nagle
甜瓜 wrote: > Well, Database is not proper because 1. the table is very big (~10^9 > rows) 2. we should support very fast *simple* query that is to get > value corresponding to single key (~10^7 queries / second). Ah, crypto rainbow tables. John Nagle --

Re: Revisiting Generators and Subgenerators

2010-03-25 Thread Patrick Maupin
On Mar 25, 7:31 pm, Winston Wolff wrote: (a bunch of stuff about coroutines) There have been proposals in the past for more full-featured generators, that would work as general purpose coroutines. Among other things, there were issues with exception propagation, and the design was deliberately

Re: Automatic import ?

2010-03-25 Thread Steven D'Aprano
On Thu, 25 Mar 2010 18:03:58 -0700, C. B. wrote: > Hi everyone, > > I'm currently coding a C library which provides several modules and > objects. > > Let's say that some of these objects are classes called AAA and BBB. The > constructor of AAA needs to get BBB as argument. > > So I can run the

Re: Revisiting Generators and Subgenerators

2010-03-25 Thread Stefan Behnel
Patrick Maupin, 26.03.2010 04:30: ... and then re-post your document. ... preferably to the python-ideas mailing list. Although it seems to me that this is something that could be explored as a library first - which usually means that people will tell you exactly that on python-ideas and ask

Question regarding curses and text-input methods

2010-03-25 Thread Harishankar
I am trying to use Python curses.textpad to get (preferably UTF-8 but not needed) input from the user in a python curses application, but I realize that it is extremely limited and doesn't allow me to specify an existing text to edit. Also it doesn't seem to provide scrolling abilities on the windo