At Tuesday 5/9/2006 10:49, Gardner Pomper wrote:
I am writing a specialized xml serialization function, and I would
like to be able to serialize the value of a simple object with the
object name as the tag. For example:
first_name = 'Fred'
sXML = my_xml_serializer(first_name)
should re
At Tuesday 5/9/2006 13:05, Tim Chase wrote:
> And receiving hotmail (or any outher webmail) using scraping
> techniques is a daunting task, to say the least - you should
> forget about that IMHO.
There's a perl project called "gotmail" that will do the scraping
Freepops does that (and a lot m
[Licheng Fang]
> ...
> I want to know if there is some way to make Python RE behave like grep
> does,
Not in general, no. The matching strategies couldn't be more
different, and that's both deep and intentional. See Friedl's book
for details:
http://regex.info/
> or do I have to change to
I am looking for something like the caller() routine in Perl:
http://perldoc.perl.org/functions/caller.html
I am writing a script which needs to be allocated an object containing
a set of paths that it will use for reading and writing during it's
execution:
import os.path
class logic:
def
metaperl <[EMAIL PROTECTED]> wrote:
> I am looking for something like the caller() routine in Perl:
>http://perldoc.perl.org/functions/caller.html
Look at the inspect module in Python's standard library.
Alex
--
http://mail.python.org/mailman/listinfo/python-list
In article <[EMAIL PROTECTED]>,
Steve Holden <[EMAIL PROTECTED]> wrote:
> Ron Garret wrote:
> > In article <[EMAIL PROTECTED]>,
> > Steve Holden <[EMAIL PROTECTED]> wrote:
> >
> >
> >>But basically, you aren't providing a CGI environment, and that's why
> >>cgi.parse() isn't working.
> >
> >
In article <[EMAIL PROTECTED]>,
Kent Johnson <[EMAIL PROTECTED]> wrote:
> Steve Holden wrote:
> > Ron Garret wrote:
> >> In article <[EMAIL PROTECTED]>,
> >> Steve Holden <[EMAIL PROTECTED]> wrote:
> >>
> >>
> >>> But basically, you aren't providing a CGI environment, and that's why
> >>> cgi.p
In article <[EMAIL PROTECTED]>,
Damjan <[EMAIL PROTECTED]> wrote:
> >> But basically, you aren't providing a CGI environment, and that's why
> >> cgi.parse() isn't working.
> >
> > Clearly. So what should I be doing?
>
> Probably you'll need to read the source of cgi.parse_qs (like Steve did)
At Tuesday 5/9/2006 16:23, [EMAIL PROTECTED] wrote:
I would be surprised if they had never used ANY database. A little
thing like dynamic field typing will simply make it impossible to
migrate your Sqlite data to a *real* database.
Why not? Because it breaks the relational model rules? That mo
MonkeeSage wrote:
> So, it seems they are all broken, or python is correct as well.
Aha, sorry about that Licheng (re: Tim's post). I guess "broken"
depends on if you are expecting perl-compatible behavior or otherwise.
I have my own scripts I use to do (f)grep and sed-like operations, so I
almost
Oh, please do have a look at the second link I've posted. There's a
table comparing the regexp engines. The engines you've tested probably
all use an NFA implementation.
MonkeeSage wrote:
> Licheng Fang wrote:
> > Hi, according to these regexp engine discussions, it's NOT a behavior
> > true to an
Il Sun, 10 Sep 2006 19:15:40 +0200, David ha scritto:
> The problem is that, when sizer2 containig hidden controls collapses to
> zero dimensions, the panel resizes, but sizer1 and sizer0 don't!
> Consequently the frame does not want to autoresize.
>
> You con dowload the code here:
> http://www.
Licheng Fang wrote:
> Oh, please do have a look at the second link I've posted. There's a
> table comparing the regexp engines. The engines you've tested probably
> all use an NFA implementation.
Sorry! *blush* I admit I skipped over your links. I'll have a look now.
BTW, just an idea that may or
Thank you very much, Tim and Monkee.
In fact, what I'm doing is handle a lot of regular expressions. I
wanted to build VERY LONG regexps part by part and put them all into a
file for easy modification and maintenance. The idea is like this:
(*INT) = \d+
(*DECIMAL) = (*INT)\.(*INT)
(*FACTION) = (*
Or mabye something like this is better:
def matcher(string, pattern):
out = ''
for match in re.findall(r'\S*%s\S*' % pattern, string):
if (len(match) >= len(out)):
out = match
return out
p1 = 'dodad donkeykong dolittle dodaday'
p2 = 'oneself self-serving selfsufficient oneselfsuff
In <[EMAIL PROTECTED]>, metaperl wrote:
> # Of course I could cheat and pass it, but I don't want to:
>
> directories = data.storage.logic(__file__)
Why do you consider a plain and simple solution cheating?
Ciao,
Marc 'BlackJack' Rintsch
--
http://mail.python.org/mailman/listinfo/pytho
Gabriel Genellina wrote:
> At Tuesday 5/9/2006 16:23, [EMAIL PROTECTED] wrote:
>
> >I would be surprised if they had never used ANY database. A little
> >thing like dynamic field typing will simply make it impossible to
> >migrate your Sqlite data to a *real* database.
>
> Why not? Because it brea
> > I am looking for something like the caller() routine in Perl:
> >http://perldoc.perl.org/functions/caller.html
>
> Look at the inspect module in Python's standard library.
Or is you're feeling lazy, have a look at the "here" function found in
http://www.unixreview.com/documents/s=9133/ur040
[Licheng Fang[
> ...
> In fact, what I'm doing is handle a lot of regular expressions. I
> wanted to build VERY LONG regexps part by part and put them all into a
> file for easy modification and maintenance. The idea is like this:
>
> (*INT) = \d+
> (*DECIMAL) = (*INT)\.(*INT)
> (*FACTION) = (*DECI
Licheng Fang wrote:
> Oh, please do have a look at the second link I've posted. There's a
> table comparing the regexp engines. The engines you've tested probably
> all use an NFA implementation.
Unfortunately, the stuff about NFA's is wrong. Friedl's awful
book was the first time I saw this confu
201 - 220 of 220 matches
Mail list logo