Re: Python to use a non open source bug tracker?

2006-10-07 Thread James Graham
Steve Holden wrote:
> Giovanni Bajo wrote:
> [...]
>>
>> I understand your concerns, but I have to remember you that most bug 
>> reports
>> submitted by users go totally ignored for several years, or, better, 
>> forever. I
>> do not have a correct statistic for this, but I'm confident that at 
>> least 80%
>> of the RFE or patches filed every week is totally ignored, and 
>> probably at
>> least 50% of the bugs too. I think there is a much bigger problem here 
>> wrt QOS.
>>
>> So, you might prefer 6-10 people to activate a new tracker account 
>> faster than
>> light. I'd rather have 3-days delay in administrative issues because 
>> our single
>> administrator is sleeping or whatever, and then have 2-3 people doing 
>> regular
>> bug processing.
> 
> ... and if wishes were horses then beggars would ride.

FWIW, this situation (few administrators compared to the number of 
community members involved in triage) is basically the situation for the 
Mozilla project's bug database (which is a bugzilla install, of course), 
This was the case even before the corporation was founded so it's not a 
funding issue. My impression has always been that people who kept the 
bug database clean (moving things to the right component, hunting out 
duplicates, verifying fixes, and so on) are seen as vital and accorded 
appropriate respect by the Mozilla development community.

I don't think I have any specific point to make except, perhaps, that by 
making the right noises, it is quite possible to get a useful number of 
people helping with bug processing work.
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: RSS aggregator with curses and feedparser

2006-09-24 Thread James Graham
Roberto Bechtlufft wrote:
> And another thing: feedparser returns the result entries as
> dictionaries. What's the best approach to create my cache file? I see
> that the cache file in liferea is an xml file. Should I try to create
> my own xml file based on the results from feedparser?

Well you could do, using elementtree or whatever but there's no 
particular reason to use XML over anything else. It's semi-human 
readable which is nice but, if you're just serializing dicts some json 
library (e.g. [1]) might do all you need out of the box. Alternatively, 
if you don't care about the local format being human-readable, you could 
simply use the built-in pickle module to save your state.

> Thanks for your help.

(note that people tend to dislike top posting because, as you can see, 
it tends to screw up the order of replies).

> Roberto Bechtlufft wrote:
>
>> A question: how do I tell my program that a certain entry was/wasn't
>> downloaded yet? Should I use the date or link tag of the entry?
> 
Assuming the feed is atom, you want to look at the entry's GUID to 
determine whether you have already downloaded it. That may also work for 
RSS feeds although I'm not sure how well RSS feeds in the wild stick to 
the "Globally Unique" part of GUID... but this is more of a feed 
handling question than a python one.

[1] http://cheeseshop.python.org/pypi/python-json/
-- 
http://mail.python.org/mailman/listinfo/python-list


[ANN] html5lib 0.2

2007-01-09 Thread James Graham
DESCRIPTION

HTML parsing library based on the WHATWG Web Applications 1.0 "HTML5"
specification[1]. The parser is designed to work with all existing 
flavors of HTML and implements well-defined error recovery that has been 
specified though analysis of the behavior of modern desktop web browsers.

html5lib currently allows parsing to both a custom "simpletree" format 
and to an ElementTree, if available. Future releases will include 
support for at least one DOM implementation, and it is possible to 
implement custom treebuilders although the API should not yet be 
considered stable.

DOWNLOAD

http://html5lib.googlecode.com/files/html5lib-0.2.zip

BUGS

This is the first release of html5lib and it is considered alpha quality 
software. However, it ships with over 230 passing unit tests covering 
most of the specified behavior. Bugs should be reported on the issue 
tracker [2]

KNOWN ISSUES

Error handling does not yet conform to the specification; not all errors 
are reported and the error messages are not informative.

PROJECT PAGE

More information about the project including documentation and 
information on getting involved is available on the project page:
http://code.google.com/p/html5lib/

[1] http://whatwg.org/specs/web-apps/current-work/
[2] http://code.google.com/p/html5lib/issues/list
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: How *extract* data from XHTML Transitional web pages? got xml.dom.minidom troubles..

2007-03-02 Thread James Graham
[EMAIL PROTECTED] wrote:
> I'm trying to extract some data from an XHTML Transitional web page.
> 
> What is best way to do this?

May I suggest html5lib [1]? It's based on the parsing section of the 
WHATWG "HTML5" spec [2] which is in turn based on the behavior of major 
web browsers so it should parse more or less* any invalid markup you 
throw at it. Despite the name "html5lib" it works with any (X)HTML 
document. By default, you have the option of producing a minidom tree, 
an ElementTree, or a "simpletree" - a lightweight DOM-like 
html5lib-specific tree.

If you are happy to pull from SVN I recommend that version; it has a few 
bug fixes over the 0.2 release as well as improved features including 
better error reporting and detection of encoding from  elements 
(the next release is imminent).

[1] http://code.google.com/p/html5lib/
[2] http://whatwg.org/specs/web-apps/current-work/#parsing

* There might be a problem if e.g. the document uses a character 
encoding that python does not support, otherwise it should parse anything.
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Plotting package?

2006-04-26 Thread James Graham
Andrew Koenig wrote:
> This may be a foolish question, but what's the most straightforward way to 
> plot a bunch of data in Python?
> 
> That is, I want to write a program that does some number crunching, and then 
> I want to change some parameters and watch how the changes affect the 
> results.  I could produce a file to hand to gnuplot, but that's a bit of a 
> pain; so I'm wondering if there is a widely used package to which I can give 
> my x-y pairs and have it produce a graph for me with axes, scaling, etc.
> 
> 
In addition to the other (excellent) suggestions, you could have a look 
at Veusz [1]. It has a GUI which, in your case, you could use to create 
all the boilerplate code (axes, labels, etc.) interactively and then use 
the scripting interface to feed in different datasets as required. The 
major limitation is that it requires Qt/PyQt 3 so I don't know how easy 
it is to get working under Windows.

[1] http://home.gna.org/veusz/
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: python and xulrunner

2006-05-01 Thread James Graham
[EMAIL PROTECTED] wrote:

> I've been trying to get xulrunner compiled with python (in windows) but
> have been unsuccessful.  I've been following this:
> .

I haven't tried it, but do the instructions at developer.mozilla.org[1] 
help? XULrunner in particular has changed quite a bit recently.

[1] http://developer.mozilla.org/en/docs/Building_PyXPCOM

-- 
http://mail.python.org/mailman/listinfo/python-list