A comp.lang.python code snippet archive?

chris patti cpatti at atg.com
Thu Mar 2 08:38:48 EST 2000


"Hans Nowak" <hnowak at cuci.nl> writes:

> On 28 Feb 00, at 19:44, Michael Hudson wrote:
> 
> [snippets site questions]
> > > I would like to know:
> > > * if it's still worthwile to continue this site
> > > * what kind of improvements I could make (a search engine would be cool
> > > but I don't know much about CGI)
> > > 
> > > Ideas, anyone?
> > 
> > I'd think it was worth continuing.  I'd also think it could be made
> > easier, however - I use gnus to read my mail, and I'd be damned if it
> > wasn't possible to rig things so that I could go 'M-x snippet' when I was
> > reading a suitable article and have it appear in the archive.
> 
> Yes, but almost every snippet is edited before it is added... if only to 
> add some headers. But I also like to test snippets if possible, before they 
> are actually uploaded. So automating this process won't be easy. I intend 
> it to be more than just an archive of messages with code.

Hi Michael thanks for chiming in..

I think your website is _definitely_ worth continuing - I just think
more people need to get actively involved in testing and submitting
snippets.  I can think of several recent posts that, if I still have
them in my spool would make great snippets (the memoization and tail
recursion posts come to mind) if I can find time I'll grab them, test
them, maybe figure out what your criteria for submission are and start
submitting the 'best of' c.l.p to your archive.

It might also be nice as a gesture to the community if when people
*post* such things they take a moment to also mail them to Michael -
but anyway..

This is actually a separate thread from what we're discussing here..

I think as a separate issue, the automated extraction of any/all code
snippets posted on the newsgroup/mailing list would be a useful thing
to have readily accessible on a website somewhere - that way nothing's
lost in the tide of zillions of new news articles coming every day..

I wonder if I could key off the use of 'import' ?  I suppose there are
useful snippets that don't use import, though.

I wonder what I could use (algorithmically) to find arbitrary Python
code embedded in a blob of text?

-Chris
(I do have some web space at my disposal - if I could write the
'grabber' I could subscribe to python-list and have procmail invoke it
or somesuch..)
-- 
--------------------------------------------------------------------
Chris Patti \ Art Technology Group \ 617-386-1649 \ cpatti at atg.com
--------------------------------------------------------------------



More information about the Python-list mailing list