Looks good. I'll give it a try.
Konstantin Veretennicov wrote:
> On 6/24/05, Lowell Kirsh <[EMAIL PROTECTED]> wrote:
>
>>Is there a module or library anyone knows of that will print html code
>>indented?
>
>
> Depends on whether you have to deal with xht
Thanks. At a glance, that looks like it's what I'm looking for.
Lowell
TechBookReport wrote:
> Lowell Kirsh wrote:
>
>> Is there a module or library anyone knows of that will print html code
>> indented? What I'd like would be for a function or class which work
Check out lisp macros. Other languages have macro systems but none
compare in power to lisp's. They are so powerful in lisp because lisp is
the only language where the source code closely resembles its parse tree
(created within the compiler/interpreter).
Lowell
Joseph Garvin wrote:
> As someo
Is there a module or library anyone knows of that will print html code
indented? What I'd like would be for a function or class which works
like this:
htmlIndent(sys.stdout, 'foobar...')
and will print somethinkg like this to stdout:
foobar
...
My current way of doing this ki
Hi,
Skip Montanaro wrote:
> Also, since it's clear you have already imported dbtest and util, there's no
> need to check in sys.modules:
>
> import dbtest, util
> reload(dbtest)
> reload(util)
Won't this load the modules twice on the first run? I only want to load
the modules once e
I have a driver module as well as several other modules. I am running
the driver interactively from emacs - that is, I don't restart python on
each run. I want to work it such that every time a modify the source for
one of the non-driver modules and re-run the driver, the other modules
will be
It looks pretty good, but I'll have to take a better look later. Out of
curiosity, why did you convert the first spaces to pipes rather than add
the code as an attachment?
Lowell
Christos TZOTZIOY Georgiou wrote:
On Wed, 23 Feb 2005 01:56:02 -0800, rumours say that Lowell Kirsh
&l
Thanks for the advice. There are definitely some performance issues I
hadn't thought of before. I guess it's time to go lengthen, not shorten,
the script.
Lowell
John Machin wrote:
Lowell Kirsh wrote:
I have a script which I use to find all duplicates of files within a
given directo
Good idea about hashing part of the file before comparing entire files.
It will make the script longer but the speed increase will most likely
make it worth it.
Lowell
Christos TZOTZIOY Georgiou wrote:
On Tue, 22 Feb 2005 00:34:39 -0800, rumours say that Lowell Kirsh
<[EMAIL PROTECTED]>
I have a script which I use to find all duplicates of files within a
given directory and all its subdirectories. It seems like it's longer
than it needs to be but I can't figure out how to shorten it. Perhaps
there are some python features or libraries I'm not taking advantage of.
The way it wo
I'm not sure I get it. What's the purpose of using a delegate rather
than having the object itself supply the return value?
Alex Martelli wrote:
Lowell Kirsh <[EMAIL PROTECTED]> wrote:
What might these exceptions be?
It's HIGHLY advisable to have your __getattr__ methods
What might these exceptions be?
It's HIGHLY advisable to have your __getattr__ methods raise
AttributeError for any requested name that starts and ends with double
underscores, possibly with some specific and specifically designed
exceptions.
Alex
--
http://mail.python.org/mailman/listinfo/python-l
How come you reverse the list twice? And why does this preserve stability?
Raymond Hettinger wrote:
"Lowell Kirsh"
I'm trying to emulate the sorted() method introduced in python 2.4. The
only difference is that it takes a sequence as one of its arguments
rather than being a method
I want to create a class called DefaultAttr which returns a default
value for all attributes which haven't been given values yet. It will
work like this:
>> x = DefaultAttr(99)
>> print x.foo
99
>> print x.bar
99
>> x.foo = 7
>> print x.foo
7
I already have a similar class called DefaultDict whi
I'm trying to emulate the sorted() method introduced in python 2.4. The
only difference is that it takes a sequence as one of its arguments
rather than being a method of the sequence class. Does my method do the
same as the sorted()? The obvious difference is that my method is called
as sort(se
D'oh I should've caught that myself.
Thanks.
Fredrik Lundh wrote:
Lowell Kirsh wrote:
On a webpage (see link below) I read that the following 2 forms are not the same and that the
second should be avoided. They look the same to me. What's the difference?
def functionF(argString
On a webpage (see link below) I read that the following 2 forms are not
the same and that the second should be avoided. They look the same to
me. What's the difference?
Lowell
def functionF(argString="abc", argList = None):
if argList is None: argList = []
...
def functionF(
17 matches
Mail list logo