Re: What's so funny? WAS Re: rotor replacement

2005-01-25 Thread Fredrik Lundh
<[EMAIL PROTECTED]> wrote: > The likely-best-known Python application in the world (probably more > people have heard of it than have heard of Python) originally had > crypto and what Python application is that? I can think of quite a few applications written in Python that are widely known, but

Re: Classical FP problem in python : Hamming problem

2005-01-25 Thread Michael Spencer
Francis Girard wrote: The following implementation is even more speaking as it makes self-evident and almost mechanical how to translate algorithms that run after their tail from recursion to "tee" usage : Thanks, Francis and Jeff for raising a fascinating topic. I've enjoyed trying to get my

Re: error

2005-01-25 Thread Fredrik Lundh
"me" <[EMAIL PROTECTED]> wrote: > whenever i try and run my Python GUI, my computer thinks for a sec, then > drops the process, without ever displaying the window. the command prompt > window seems to work fine, but the IDLE GUI won't start. > > i'm running Windows 2K professional and python 2.4,

Re: Help on project, anyone?

2005-01-25 Thread Fuzzyman
Miki Tebeka wrote: > Hello Fuzzyman, > > > 3) Simple Version Control program for single programmer. A very simple > > way of doing version control/releases for small projects with only a > > single programmer. [3] > Subversion (and CVS) are dead simple to install and use. I've heard *lots* of peo

Re: is there better 32 clock() timing?

2005-01-25 Thread Tim Roberts
Ray Schumacher <[EMAIL PROTECTED]> wrote: > >I have a need for a time.clock() with >0.16 second (16us) accuracy. >The sleep() (on Python 2.3, Win32, at least) has a .001s limit. > >Are they lower/better on other's platforms? You need to be careful about describing what you're seeing here. It

Re: Retrieving modification time of file class was declared in

2005-01-25 Thread Bengt Richter
On 24 Jan 2005 20:39:11 -0800, [EMAIL PROTECTED] wrote: >Assume I am using a class Foo. I want to find out the modification time >of the file that that class was defined in. How would I go about this? > >If I could find out the name of the file that Foo was defined in then >it is easy, I could use

Re: Why can't use cursor.nextset() in adodbapi package?

2005-01-25 Thread Tim Roberts
nightmarch <[EMAIL PROTECTED]> wrote: >Thank you Dennis! > >You mean I should execute many select statement like this " rec = >crsr.fetchall() " ? No, you misunderstand. nextset() is used when you issue several SELECT statements in a single request. The first fetchall() gets the results of the

Re: Open Folder in Desktop

2005-01-25 Thread Dennis Benzinger
Kamilche wrote: > Is there a command you can execute in Python that will open a window on > the desktop, such as 'My Documents'? Kind of like 'system', but for > folder names, not just programs. I'm running on Windows 2000. > Here are some commands you can use (tested on WinXP, so YMMV): 1. The

Re: Open Folder in Desktop

2005-01-25 Thread Ulf Göransson
Kamilche wrote: Is there a command you can execute in Python that will open a window on the desktop, such as 'My Documents'? Kind of like 'system', but for folder names, not just programs. I'm running on Windows 2000. Maybe this is good enough? os.system("explorer " + folder_path) /ug -- http://mai

RE: Open Folder in Desktop

2005-01-25 Thread Jimmy Retzlaff
Kamilche wrote: > Is there a command you can execute in Python that will open a window on > the desktop, such as 'My Documents'? Kind of like 'system', but for > folder names, not just programs. I'm running on Windows 2000. There are two issues here. The first is how to open a folder and the secon

Re: Classical FP problem in python : Hamming problem

2005-01-25 Thread Nick Craig-Wood
Francis Girard <[EMAIL PROTECTED]> wrote: > def hamming(): >def _hamming(): > yield 1 > hamming2 = hammingGenerators[0] > hamming3 = hammingGenerators[1] > hamming5 = hammingGenerators[2] > for n in imerge(imap(lambda h: 2*h, iter(hamming2)), > ime

Re: how to call python code from C#

2005-01-25 Thread just starting
Thanks for all your kind information. I haven't used COM objects so far.I think now I have to learn it.Anyway thanks a lot again. paritosh. On Mon, 24 Jan 2005 12:43:50 -0700, Dave Brueck <[EMAIL PROTECTED]> wrote: > Peter Hansen wrote: > > paritosh mahana wrote: > > > >> How can I call python co

Re: Another scripting language implemented into Python itself?

2005-01-25 Thread Ola Natvig
Roy Smith wrote: In article <[EMAIL PROTECTED]>, Quest Master <[EMAIL PROTECTED]> wrote: I am interested in developing an application where the user has an ample amount of power to customize the application to their needs, and I feel this would best be accomplished if a scripting language was ava

ANN: LJ pyGTK clien Zapys-0.3 released

2005-01-25 Thread Timothy Babytch
Usable simple app for posting messages to LiveJournal. Easy extandable. Main feature: character substitution. I mean (tm) to â, (c) to Â, quote to matching pairs and so on. The list can be easily extended with your own regexps. submit on Ctrl+Enter. Edit/delete last entry. screenshot: http://img

RE: how to ncurses on win32 platform

2005-01-25 Thread Tim Golden
[Jorgen Grahn] | [Alan Gauld ] | > You can use ncurses via cygwin. | > There are DOS ports too but I couldn't get any of them to | > work on my XP box, YMMV... | | Or, as Alex Martelli wrote in "Python in a nutshell": | |"The curses package works only on Unix-like platforms | (there are per

Re: Another scripting language implemented into Python itself?

2005-01-25 Thread Fuzzyman
An implementation of the core language semantics - without any modules or file operations would be dead useful. It could replace some of the function of the long dead rexec modules as well as support projects like this. Regards, Fuzzy http://www.voidspace.org.uk/python/index.shtml -- http://ma

Re: how to call python code from C#

2005-01-25 Thread Ryan Paul
On Tue, 25 Jan 2005 00:35:04 +0530, paritosh mahana wrote: > Hi all, > How can I call python code from my C# code. One thing is to make an > .exe file of the python program and then try to call it from my C# > code. But I don't like that idea. Is there any other way to do this. > Like making a .d

Re: specifying constants for a function (WAS: generator expressions: performance anomaly?)

2005-01-25 Thread Bengt Richter
On Mon, 24 Jan 2005 20:35:09 GMT, [EMAIL PROTECTED] (Bengt Richter) wrote: >On Mon, 24 Jan 2005 00:31:17 -0700, Steven Bethard <[EMAIL PROTECTED]> wrote: > >>Bengt Richter wrote: >>> So, e.g., for >>> >>> >>> presets = dict(a=1, b=2, deftime=__import__('time').ctime()) >>> >>> in the decorator

Re: What's so funny? WAS Re: rotor replacement

2005-01-25 Thread Robert Kern
Fredrik Lundh wrote: <[EMAIL PROTECTED]> wrote: The likely-best-known Python application in the world (probably more people have heard of it than have heard of Python) originally had crypto and what Python application is that? I can think of quite a few applications written in Python that are wi

Re: how to ncurses on win32 platform

2005-01-25 Thread Fuzzyman
Tim Golden wrote: > [Jorgen Grahn] > | [Alan Gauld ] > | > You can use ncurses via cygwin. > | > There are DOS ports too but I couldn't get any of them to > | > work on my XP box, YMMV... > | > | Or, as Alex Martelli wrote in "Python in a nutshell": > | > |"The curses package works only on Uni

Re: Help with Threading

2005-01-25 Thread Philip Smith
<[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] >I use threading.Thread as outlined in this recipe: > http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/65448 >Thanks -- http://mail.python.org/mailman/listinfo/python-list

Re: is there better 32 clock() timing?

2005-01-25 Thread Bengt Richter
On Tue, 25 Jan 2005 00:18:44 -0800, Tim Roberts <[EMAIL PROTECTED]> wrote: >Ray Schumacher <[EMAIL PROTECTED]> wrote: >> >>I have a need for a time.clock() with >0.16 second (16us) accuracy. >>The sleep() (on Python 2.3, Win32, at least) has a .001s limit. >> >>Are they lower/better on other's

Re: Classical FP problem in python : Hamming problem

2005-01-25 Thread Bengt Richter
On 25 Jan 2005 08:30:03 GMT, Nick Craig-Wood <[EMAIL PROTECTED]> wrote: >Francis Girard <[EMAIL PROTECTED]> wrote: >> def hamming(): >>def _hamming(): >> yield 1 >> hamming2 = hammingGenerators[0] >> hamming3 = hammingGenerators[1] >> hamming5 = hammingGenerators[2] >>

Re: Weakref.ref callbacks and eliminating __del__ methods

2005-01-25 Thread Richie Hindle
[Tim] > there's no 100% guarantee that a __del__ method will ever get called Can anyone point me to any definitive documentation on why this is the case? I was under the impression that __del__ would always be called: 1. for objects not in cycles and with no references 2. for objects whose o

Re: "private" variables a.k.a. name mangling (WAS: What is print? A function?)

2005-01-25 Thread Simon Brunning
On Mon, 24 Jan 2005 12:17:13 -0600, Philippe C. Martin <[EMAIL PROTECTED]> wrote: > > I use "__"for private variables because I must have read on net it was > the way to do so - yet this seems to have changed - thanks: > > http://www.network-theory.co.uk/docs/pytut/tut_77.html Nope, that's still

Re: "private" variables a.k.a. name mangling (WAS: What is print? A function?)

2005-01-25 Thread michele . simionato
>Name mangling is there to keep you from accidentally hiding such an >attribute in a subclass, but how often is this really a danger? Can >someone give me an example of where __-mangling really solved a problem >for them, where a simple leading underscore wouldn't have solved the >same problem? Lo

Re: is there better 32 clock() timing?

2005-01-25 Thread Stephen Kellett
that time.clock() is inaccurate. The problem is that the "time.clock()" statement takes several hundred microseconds to execute. The statement is incorrect. clock() itself isn't slow, but it is accessing a resource, the accuracy of which is no better than 1ms. There are various timers available,

Re: Right place for third party modules (here: fixedpoint)

2005-01-25 Thread Sibylle Koczian
Fredrik Lundh schrieb: ah, forget what I said. you need to put the fixedpoint.py *file* under site-packages, not the entire directory. as that "python -v -v" would have told you: Thank you (and Steve Holden), that did it. more out ... # trying C:\python24\lib\site-packages\fixedpoint.pyd # tryi

Re: What YAML engine do you use?

2005-01-25 Thread Sion Arrowsmith
Fredrik Lundh <[EMAIL PROTECTED]> wrote: >Sion Arrowsmith wrote: >> I'm probably not thinking deviously enough here, but how are you >> going to exploit an eval() which has very tightly controlled >> globals and locals (eg. eval(x, {"__builtins__": None}, {}) ? >try this: > >eval("'*'*100*2

Re: Classical FP problem in python : Hamming problem

2005-01-25 Thread Nick Craig-Wood
Francis Girard <[EMAIL PROTECTED]> wrote: > The following implementation is even more speaking as it makes self-evident > and almost mechanical how to translate algorithms that run after their tail > from recursion to "tee" usage : > > *** BEGIN SNAP > from itertools import tee, imap > imp

Re: "private" variables a.k.a. name mangling (WAS: What is print? A function?)

2005-01-25 Thread Richie Hindle
[Steven] > Can someone give me an example of where __-mangling really solved a problem > for them, where a simple leading underscore wouldn't have solved the > same problem? http://cvs.sourceforge.net/viewcvs.py/spambayes/spambayes/spambayes/Dibbler.py?r1=1.13&r2=1.13.4.1 That's a bugfix to Sp

Re: is there better 32 clock() timing?

2005-01-25 Thread Bengt Richter
On Tue, 25 Jan 2005 11:42:35 +, Stephen Kellett <[EMAIL PROTECTED]> wrote: >>>that time.clock() is inaccurate. The problem is that the "time.clock()" >>>statement takes several hundred microseconds to execute. > >The statement is incorrect. clock() itself isn't slow, but it is >accessing a r

Re: Another scripting language implemented into Python itself?

2005-01-25 Thread Arthur
On Mon, 24 Jan 2005 19:40:31 -0500, Roy Smith <[EMAIL PROTECTED]> wrote: >In article <[EMAIL PROTECTED]>, > Quest Master <[EMAIL PROTECTED]> wrote: > > >Python *is* a scripting language. Why not just let your users write >Python modules which you them import and execute via some defined API? Th

Re: "private" variables a.k.a. name mangling (WAS: What is print? A function?)

2005-01-25 Thread Toby Dickenson
On Tuesday 25 January 2005 12:40, Richie Hindle wrote: > > [Steven] > > Can someone give me an example of where __-mangling really solved a problem > > for them, where a simple leading underscore wouldn't have solved the > > same problem? > > http://cvs.sourceforge.net/viewcvs.py/spambayes/sp

snakespell and myspell

2005-01-25 Thread Fuzzyman
I'm looking to implement a plugin spell checker. I'm probably going to go with PyEnchant, as it looks to be the most promising currently maintained spell checker. I just wondered if anyone knew what happened to snakespell and myspell. Both seem to have dissapeared from the net. People have report

threading.py Condition wait overflow error

2005-01-25 Thread Mark English
Every once in a while since I moved to Python 2.4 I've been seeing the following exception in threading.py Condition: File "mctest3.py", line 1598, in WaitForMessages self.condResponses.wait(1.0) File "C:\Program Files\Python24\lib\threading.py", line 221, in wait delay = min(delay * 2

Re: Another scripting language implemented into Python itself?

2005-01-25 Thread Roy Smith
"Carl Banks" <[EMAIL PROTECTED]> wrote: > > Imbed > EMBED. My apologies for being sloppy. And with an initial capital, so it just jumps off the page at you :-) > > Python, or Perl, or TCL, or Ruby, or PHP, > > Not PHP. PHP is one of the better (meaning less terrible) examples of > what happ

Re: tkinter socket client ?

2005-01-25 Thread Tonino
Hi, thanks for this info - I had to abandon the createfilehandler() method as it is not supported in windows and the GUI "might" be used there at some time ... So - I went the threading route - works well - for now - so I will stick to it ... BUT - the next question: In the Text() widget - why -

Re: RE:"private" variables a.k.a. name mangling (WAS: What is print? A function?)

2005-01-25 Thread Sion Arrowsmith
Jeremy Bowers <[EMAIL PROTECTED]> wrote: > [ ... ] the Python community, and in general the dynamic language >community, has become increasingly confident that private variables don't >solve *real* problems. Years of writing and maintaining others' C++ and Java code (plus one year of maintaining

Re: tkinter socket client ?

2005-01-25 Thread Martin Franklin
Tonino wrote: Hi, thanks for this info - I had to abandon the createfilehandler() method as it is not supported in windows and the GUI "might" be used there at some time ... So - I went the threading route - works well - for now - so I will stick to it ... BUT - the next question: In the Text() wid

Re: DevX: "Processing EDI Documents into XML with Python"

2005-01-25 Thread Satchidanand Haridas
There has already been some work in this area - although for X12 transactions for the healthcare industry. Its on sourceforge already and best of all the development language is Python: http://sourceforge.net/projects/pyx12/ thanks, Satchit Satchidanand Haridas (sharidas at zeomega dot com)

Re: delay and force in Python

2005-01-25 Thread Nick Coghlan
Peter Otten wrote: Nick Coghlan wrote: Py> print islice((x for x in xrange(1, 996) if x % 2 == 0), 1, 2).next() 4 Wouldn't it be nice if this could be spelt: print (x for x in xrange(1, 996) if x % 2 == 0)[2] Well, I just put a patch on SF to enable exactly that: http://www.python.org/sf/1108272

Re: Instances of class object not modifiable?

2005-01-25 Thread Nick Coghlan
Steven Bethard wrote: Open Issues === What should the type be named? Some suggestions include 'Bunch', 'Record' and 'Struct'. Add 'namespace' to the list of name suggestions :) Cheers, Nick. The name came up in some thread a few weeks back. . . -- Nick Coghlan | [EMAIL PROTECTED] |

Re: What's so funny? WAS Re: rotor replacement

2005-01-25 Thread Fuzzyman
I've already downloaded p3 - thanks :-) I wonder how long it took (in reality) an average hacker to break the algorithm used by rotor ? Regards, Fuzzy http://www.voidspace.org.uk/python/index.shtml -- http://mail.python.org/mailman/listinfo/python-list

Browsing text ; Python the right tool?

2005-01-25 Thread Paul Kooistra
I need a tool to browse text files with a size of 10-20 Mb. These files have a fixed record length of 800 bytes (CR/LF), and containt records used to create printed pages by an external company. Each line (record) contains an 2-character identifier, like 'A0' or 'C1'. The identifier identifies the

Re: Tuple slices

2005-01-25 Thread Nick Coghlan
George Sakkis wrote: You're probably right about the allocation time, but my main concern is the memory required for each slice, which can be O(n) wrt the length of the whole tuple. I would like this to be constant (at least if there was a way around to the problem of deleting the underlying seq

Re: Another scripting language implemented into Python itself?

2005-01-25 Thread Nick Coghlan
Fuzzyman wrote: An implementation of the core language semantics - without any modules or file operations would be dead useful. It could replace some of the function of the long dead rexec modules as well as support projects like this. Securing a custom build of the CPython interpreter would probab

Re: "private" variables a.k.a. name mangling (WAS: What is print? A function?)

2005-01-25 Thread Philippe C. Martin
Well I _was_ a bit slow on that one ! So I will happily stick to the double underscore. Regards, Philippe Le mardi 25 janvier 2005 Ã 10:28 +, Simon Brunning a Ãcrit : > On Mon, 24 Jan 2005 12:17:13 -0600, Philippe C. Martin > <[EMAIL PROTECTED]> wrote: > > > > I use "__"for private varia

Re: Memory Usage

2005-01-25 Thread Nick Coghlan
Stuart McGarrity wrote: Do you have a page file? The Mem column should be RAM usage and not total working set. Some of it could be swapped to the page file. A free tool like process explorer can give you better informaton than the task manager. As Tim pointed out, "View->Select Columns" and activ

Re: Installer made with bdist_wininst segfaulting...

2005-01-25 Thread Thomas Heller
Fernando Perez <[EMAIL PROTECTED]> writes: > Hi all, > > I am seeking advice/help from those with more win32 experience than myself. I > am trying to build a proper win32 installer for IPython, after a user did most > of the hard work. For the most part, it's working very well, but I am running

*IMPORTANT* Message for Google Group users!

2005-01-25 Thread google_groups_001
Good News! Do you know how simple it is to go to Heaven after this life has ended? Some people believe that belonging to a local church, temple, mosque or synagogue will get them to Heaven. Others believe that water baptism, obeying the ten commandments or just being a good person will get them

Re: Help on project, anyone?

2005-01-25 Thread Captain Dondo
On Sun, 23 Jan 2005 21:11:32 +0100, Georg Brandl wrote: > Hello, > > to train my Python skills I am looking for some project I can contribute > to. I learned Python about one year ago, and had already some > programming background behind (I contributed to SharpDevelop for > instance), so I'm not

Re: Tuple slices

2005-01-25 Thread gsakkis
Terry Reedy wrote: > "George Sakkis" <[EMAIL PROTECTED]> wrote in message > news:[EMAIL PROTECTED] > > Actually my initial motivation was not a huge tuple I had to slice many > > times. It was something much > > less extraordinarily unlikely, a recursive function with a sequence > > parameter: >

Re:Crypto in Python: (Was: What's so funny? WAS Re: rotor replacement)

2005-01-25 Thread Philippe C. Martin
>Now what if acipher and this class could be made from part of the core >distro? Any application could have the option of encryption with only a >few lines of code: Just a bit of info on the subject (which you might already have) I do not know in which country the python.msi is compiled (Deuch

Re: is there better 32 clock() timing?

2005-01-25 Thread Stephen Kellett
In message <[EMAIL PROTECTED]>, Bengt Richter <[EMAIL PROTECTED]> writes I believe that is quite wrong as a general statement. Actually my initial statement should have been written "accessing a resource, the accuracy of which is no better than 10ms.". I was thinking of the 1ms multimedia timer b

Re: Another scripting language implemented into Python itself?

2005-01-25 Thread Fuzzyman
Nick Coghlan wrote: > Fuzzyman wrote: > > An implementation of the core language semantics - without any modules > > or file operations would be dead useful. > > > > It could replace some of the function of the long dead rexec modules as > > well as support projects like this. > > Securing a custo

Re: Another scripting language implemented into Python itself?

2005-01-25 Thread Cameron Laird
In article <[EMAIL PROTECTED]>, Orlando Vazquez <[EMAIL PROTECTED]> wrote: >Jeff Shannon wrote: > >snip > >> Because you cannot make Python secure against a malicious (or ignorant) >> user -- there's too much flexibility to be able to guard against every >> possible way in which user-code could

Re: Tuple slices

2005-01-25 Thread George Sakkis
An iterator is perfectly ok if all you want is to iterate over the elements of a view, but as you noted, iterators are less flexible than the underlying sequence. The view should be (or at least appear) identical in functionality (i.e. public methods) with its underlying sequence. George -- http

Re: pylibpcap and multiple threads

2005-01-25 Thread Örjan Gustavsson
Hi Carlos, I looked in the source code for pylibpcap, and it does not release the GIL, hence my problem. I found a solution though, the pcap object has a fileno member so I could use select to wait for a packet, then call loop without blocking. Problem solved! :) And since it is only a thin wr

[perl-python] 20050125 standard modules

2005-01-25 Thread Xah Lee
# -*- coding: utf-8 -*- # Python # some venture into standard modules import os # print all names exported by the module print dir(os) # print the module's online manual print help(os) # the above is also available in # interactive mode in Python terminal # example of using a function print 'c

Skype and Python

2005-01-25 Thread python
Does anyone played with Skype (http://www.skype.com/ free Internet telephony ) by using Python? Lad. -- http://mail.python.org/mailman/listinfo/python-list

Re: Another scripting language implemented into Python itself?

2005-01-25 Thread Roy Smith
Cameron Laird <[EMAIL PROTECTED]> wrote: >It's also one that brings Tcl, mentioned several >times in this thread, back into focus. Tcl presents >the notion of "safe interpreter", that is, a sub- >ordinate virtual machine which can interpret only >specific commands. It's a thrillingly powerful and

Re: Classical FP problem in python : Hamming problem

2005-01-25 Thread Steven Bethard
Nick Craig-Wood wrote: Thinking about this some more leads me to believe a general purpose imerge taking any number of arguments will look neater, eg def imerge(*generators): values = [ g.next() for g in generators ] while True: x = min(values) yield x for i in range

Re: Another scripting language implemented into Python itself?

2005-01-25 Thread Cameron Laird
In article <[EMAIL PROTECTED]>, Carl Banks <[EMAIL PROTECTED]> wrote: . . . >> Python, or Perl, or TCL, or Ruby, or PHP, > >Not PHP. PHP is one of the better (meaning less terrible) examples of >what happens when you do this s

Re: "private" variables a.k.a. name mangling (WAS: What is print? A function?)

2005-01-25 Thread Richie Hindle
[Toby] > The problem occured because the double-underscore mangling uses the class > name, but ignores module names. A related project already had a class named C > derived from B (same name - different module). Yikes! A pretty bizarre case, but nasty when it hits. I guess the double-undersc

Re: [perl-python] 20050125 standard modules

2005-01-25 Thread Dan Perl
I sent the following feedback message to Yahoo! Groups about this abusive use of their service. Feel free to also report this as an abuse of the Yahoo! Groups service until the problem is resolved. Dan --- As the owner of the perl-python group, p0lyglut (aka Xah Lee), has added two ne

Re: smtplib bug with Windows XP

2005-01-25 Thread [EMAIL PROTECTED]
thank Peter, elbert, for the suggestions. I hadn't thought of using telnet to try to connect to the SMTP server. and when I do try, telnet can't connect either, at least on port 25. On port 110, it has no problem. So, perhaps the IT people have made some configuration changes; I'll have a chat

Re: Another scripting language implemented into Python itself?

2005-01-25 Thread Fuzzyman
Cameron Laird wrote: [snip..] > This is a serious issue. > > It's also one that brings Tcl, mentioned several > times in this thread, back into focus. Tcl presents > the notion of "safe interpreter", that is, a sub- > ordinate virtual machine which can interpret only > specific commands. It's a

Re: Installer made with bdist_wininst segfaulting...

2005-01-25 Thread Fernando Perez
Hi Thomas, Thomas Heller wrote: > Fernando Perez <[EMAIL PROTECTED]> writes: >> Here is a brief summary: if the installer file is run from a windows drive >> which is different from the one where python resides (and hence where >> ipython will >> end up), the installer segfaults. No traceback,

Re: Another scripting language implemented into Python itself?

2005-01-25 Thread Carl Banks
Roy Smith wrote: > "Carl Banks" <[EMAIL PROTECTED]> wrote: > > > > Imbed > > EMBED. > > My apologies for being sloppy. And with an initial capital, so it just > jumps off the page at you :-) Ok. Prescriptive language isn't normally my cup of tea, but there's always something. And usually it's

ANN: matplotlib-0.71

2005-01-25 Thread John Hunter
matplotlib is a 2D graphics package that produces plots from python scripts, the python shell, or embeds them in your favorite python GUI -- wx, gtk, tk, fltk currently supported with qt in the works. Unlike many python plotting alternatives is written in python, so it is easy to extend. matplotli

Re: Browsing text ; Python the right tool?

2005-01-25 Thread beliavsky
Here is an elementary suggestion. It would not be difficult to write a Python script to make a csv file from your text files, adding commas at the appropriate places to separate fields. Then the csv file can be browsed in Excel (or some other spreadsheet). A0 and C1 records could be written to sepa

Re: Installer made with bdist_wininst segfaulting...

2005-01-25 Thread Fernando Perez
Thomas Heller wrote: > There are a couple of known bugs in bdist_wininst, and you just reported > another one. All these bugs are related to using the > post_install_script, and show up when either (thats what I currently > remember): > > - the installer is run from a readonly location, > - the

module for 'po' files

2005-01-25 Thread Sara Fwd
Hi all Is there a module for processing & handling '.po' files in python? __ Do you Yahoo!? Read only the mail you want - Yahoo! Mail SpamGuard. http://promotions.yahoo.com/new_mail -- http://mail.python.org/mailman/listinfo/python-list

Re: [perl-python] 20050125 standard modules

2005-01-25 Thread Dan Perl
I was wrong. He is just crossposting to the newsgroups without having them as members of the group. I wish there was a good way like that to stop these daily postings! Dan "Dan Perl" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] >I sent the following feedback message to Yahoo! G

Help! Host is reluctant to install Python

2005-01-25 Thread Daniel Bickett
I've been trying to convince my host to install python/mod_python on his server for a while now, however there are a number of reasons he is reluctant to do so, which I will outline here: 1. His major reason is optimization. He uses Zend's optimization of PHP as an example, and he has stated that

__deepcopy__ without recursive copies?

2005-01-25 Thread Bernie
#!/usr/bin/env python import sys import copy ''' How to define __deepcopy__ with out causing recursive calls to copies of self? Bernie Day 01/25/05 I was using deepcopy on DeviceManager and this worked well. When I defined __deepcopy__, so I could have a handle to the children of the Master dev

Re: module for 'po' files

2005-01-25 Thread Dennis Benzinger
Sara Fwd wrote: > Hi all > Is there a module for processing & handling '.po' > files in python? > [...] I don't know if there is a module for processing them, but Python comes with msgfmt.py (in Tools/i18n) which creates .mo files out of your .po files. So read the source and see if there's som

RE: I want update one record using ADO,but I can't ,why?

2005-01-25 Thread Robert Brewer
nightmarch wrote: > I want update one record ,but I can't ,why? > > code like following: > > ##- > import win32com.client as wc > > def main(): > conn = wc.Dispatch(r'ADODB.Connection') > rs = wc.Dispatch(r'ADODB.Recordset') > c

Re: [perl-python] 20050125 standard modules

2005-01-25 Thread Peter Nuttall
On Tuesday 25 Jan 2005 17:50, Dan Perl wrote: > I was wrong. He is just crossposting to the newsgroups without having > them as members of the group. > > I wish there was a good way like that to stop these daily postings! > You can just filter on [perl-python] Pete -- http://mail.python.org/mai

Re: tkinter socket client ?

2005-01-25 Thread Russell E. Owen
In article <[EMAIL PROTECTED]>, "Tonino" <[EMAIL PROTECTED]> wrote: >thanks for this info - I had to abandon the createfilehandler() method >as it is not supported in windows and the GUI "might" be used there at >some time ... > >So - I went the threading route - works well - for now - so I will

Re: Classical FP problem in python : Hamming problem

2005-01-25 Thread Nick Craig-Wood
Steven Bethard <[EMAIL PROTECTED]> wrote: > Nick Craig-Wood wrote: > > Thinking about this some more leads me to believe a general purpose > > imerge taking any number of arguments will look neater, eg > > > > def imerge(*generators): > > values = [ g.next() for g in generators ] > > whil

Re: [perl-python] 20050125 standard modules

2005-01-25 Thread Paul Lalli
"Xah Lee" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] -- > in perl, i don't think there is one way to > list available modules. > I'm torn between knowing that I shouldn't feed trolls, and my hatred of leaving faulty information about Perl unchecked, where

Dr. Dobb's Python-URL! - weekly Python news and links (Jan 23)

2005-01-25 Thread Josiah Carlson
QOTW: "XML with elementtree is what makes me never have [to] think about XML again." -- Istvan Albert "'Plays well with others' was a strong motivator for Python's design, and that often means playing by others' rules." -- Tim Peters Type mutability, and why some types are immutable. T

Re: Classical FP problem in python : Hamming problem

2005-01-25 Thread Steven Bethard
Nick Craig-Wood wrote: Steven Bethard <[EMAIL PROTECTED]> wrote: Nick Craig-Wood wrote: Thinking about this some more leads me to believe a general purpose imerge taking any number of arguments will look neater, eg def imerge(*generators): values = [ g.next() for g in generators ] while True:

Re: specifying constants for a function (WAS: generator expressions: performance anomaly?)

2005-01-25 Thread Steven Bethard
Bengt Richter wrote: On Mon, 24 Jan 2005 20:35:09 GMT, [EMAIL PROTECTED] (Bengt Richter) wrote: from presets import presets, curry @presets(verbose=True, a=1, b=2, deftime=__import__('time').ctime()) ... def foo(): ...print (a, b) ...print deftime ... presets: -- "name(?)" means name may be

Re: Import from database

2005-01-25 Thread Steve Holden
Kartic wrote: Steve, I believe you have to put ntpath, macpath and posixpath in the module database for os.path to work. I tried it with zipimporter builtin and I got the same traceback till I added ntpath.py to my zip file. (Of course, I renamed the original ntpath to _ntpath so that the original

Re: Classical FP problem in python : Hamming problem

2005-01-25 Thread Michael Spencer
Nick Craig-Wood wrote: Steven Bethard <[EMAIL PROTECTED]> wrote: Nick Craig-Wood wrote: Thinking about this some more leads me to believe a general purpose imerge taking any number of arguments will look neater, eg def imerge(*generators): values = [ g.next() for g in generators ] while True:

Re: "private" variables a.k.a. name mangling (WAS: What is print? A function?)

2005-01-25 Thread Steven Bethard
Toby Dickenson wrote: I have a counterexample. Consider refactoring a class from class B(A): etc into class C(A): etc class B(C): etc Usage of some double-undescore attributes moved from B to the new intermediate base class C. Unit tests on B still passed, so that change is

Re: Help! Host is reluctant to install Python

2005-01-25 Thread fuzzylollipop
find a new host, if they can't handle simple tasks like this or simple security tasks like limiting permissions, how can you be sure anything else they do is secure or correct? -- http://mail.python.org/mailman/listinfo/python-list

limited python virtual machine (WAS: Another scripting language implemented into Python itself?)

2005-01-25 Thread Steven Bethard
Fuzzyman wrote: > Cameron Laird wrote: > [snip..] > >>This is a serious issue. >> >>It's also one that brings Tcl, mentioned several >>times in this thread, back into focus. Tcl presents >>the notion of "safe interpreter", that is, a sub- >>ordinate virtual machine which can interpret only >>speci

Re: module for 'po' files

2005-01-25 Thread vincent wehren
Sara Fwd wrote: Hi all Is there a module for processing & handling '.po' files in python? Don't know exactly what you mean by "processing & handling". What do you want to do? -- Vincent Wehren __ Do you Yahoo!? Read only the mail you want - Yahoo! Mail Sp

Re: add indexes on the fly to lists

2005-01-25 Thread Do Re Mi chel La Si Do
Hi ! If you want only "search and found" element, look dictionnary ; if you want also to have the order, see the module set. Good night -- Michel Claveau -- http://mail.python.org/mailman/listinfo/python-list

Re: Help! Host is reluctant to install Python

2005-01-25 Thread Thomas Bartkus
"Daniel Bickett" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > I've been trying to convince my host to install python/mod_python on > his server for a while now, however there are a number of reasons he > is reluctant to do so, which I will outline here: I'll second what you are a

How to input one char at a time from stdin?

2005-01-25 Thread Brent W. Hughes
I'd like to get a character from stdin, perform some action, get another character, etc. If I just use stdin.read(1), it waits until I finish typing a whole line before I can get the first character. How do I deal with this? Brent -- http://mail.python.org/mailman/listinfo/python-list

Re: Classical FP problem in python : Hamming problem

2005-01-25 Thread Jeff Shannon
Bengt Richter wrote: On 25 Jan 2005 08:30:03 GMT, Nick Craig-Wood <[EMAIL PROTECTED]> wrote: If you are after readability, you might prefer this... def hamming(): def _hamming(): yield 1 for n in imerge(imap(lambda h: 2*h, iter(hamming2)), imerge(imap(lambda h: 3*h, iter(hammi

Re: How to input one char at a time from stdin?

2005-01-25 Thread Swaroop C H
On Tue, 25 Jan 2005 12:38:13 -0700, Brent W. Hughes <[EMAIL PROTECTED]> wrote: > I'd like to get a character from stdin, perform some action, get another > character, etc. If I just use stdin.read(1), it waits until I finish typing > a whole line before I can get the first character. How do I dea

Re: Another scripting language implemented into Python itself?

2005-01-25 Thread Rocco Moretti
Bob Smith wrote: Rocco Moretti wrote: Python's also dangerous. Every time you do an "import module", you put your system at risk of crashing, having the hard-drive wiped Have you been drinking again? No, not really. The "every time" comment should be viewed in the same light as "Every time you st

Re: Another scripting language implemented into Python itself?

2005-01-25 Thread Rocco Moretti
Orlando Vazquez wrote: Jeff Shannon wrote: Because you cannot make Python secure against a malicious (or ignorant) user -- there's too much flexibility to be able to guard against every possible way in which user-code could harm the system. Parsing your own (limited) scripting language allows mu

Re: Another scripting language implemented into Python itself?

2005-01-25 Thread Terry Reedy
"Cameron Laird" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > The original poster wants to work in Python. That's > fine. Several of us have suggested he further > expose Python itself to his end-users as an extension > language. That certainly is feasible. He needn't > explai

  1   2   3   >