Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

Non-ascii feed titles #12

Open
wants to merge 10 commits into from
This page is out of date. Refresh to see the latest.
2  docs/etiquette.html
View
@@ -35,7 +35,7 @@
<dd><p><code>&lt;feed xmlns:indexing="<a href="http://community.livejournal.com/lj_dev/696793.html">urn:atom-extension:indexing</a>" indexing:index="no"&gt;</code></p>
<p><code>&lt;access:restriction xmlns:access="<a href="http://www.bloglines.com/about/specs/fac-1.0">http://www.bloglines.com/about/specs/fac-1.0</a>" relationship="deny"/&gt;</code></p></dd>
</dl></p></blockquote>
-<li><p>Ensure that all <a href="http://nightly.feedparser.org/docs/reference-entry-source.html#reference.entry.source.rights">copyright</a> and <a href="http://nightly.feedparser.org/docs/reference-entry-license.html">licensing</a> information is propagated to the
+<li><p>Ensure that all <a href="http://pythonhosted.org/feedparser/reference-entry-source.html#reference.entry.source.rights">copyright</a> and <a href="http://pythonhosted.org/feedparser/reference-entry-source.html#reference.entry.source.rights/reference-entry-license.html">licensing</a> information is propagated to the
combined feed(s) that you produce.</p></li>
<li><p>Add no advertising. Consider filtering out ads, lest you
2  docs/filters.html
View
@@ -96,7 +96,7 @@
means that plugins are limited to Python and are run in-process. Plugins
therefore have direct access to planet internals like configuration and
logging facitilies, as well as access to the bundled libraries like the
-<a href="http://feedparser.org/docs/">Universal Feed Parser</a> and
+<a href="http://pythonhosted.org/feedparser/">Universal Feed Parser</a> and
<a href="http://code.google.com/p/html5lib/">html5lib</a>; but it also
means that functions like <code>os.abort()</code> can't be recovered
from.</li>
2  docs/index.html
View
@@ -35,7 +35,7 @@
<li>Reference
<ul>
<li><a href="http://www.planetplanet.org/">Planet</a></li>
-<li><a href="http://feedparser.org/docs/">Universal Feed Parser</a></li>
+<li><a href="http://pythonhosted.org/feedparser">Universal Feed Parser</a></li>
<li><a href="http://code.google.com/p/html5lib/">html5lib</a></li>
<li><a href="http://htmltmpl.sourceforge.net/">htmltmpl</a></li>
<li><a href="http://bitworking.org/projects/httplib2/">httplib2</a></li>
30 docs/normalization.html
View
@@ -10,7 +10,7 @@
<body>
<h2>Normalization</h2>
<p>Venus builds on, and extends, the <a
-href="http://www.feedparser.org/">Universal Feed Parser</a> and <a
+href="http://pythonhosted.org/feedparser/">Universal Feed Parser</a> and <a
href="http://code.google.com/p/html5lib/">html5lib</a> to
convert all feeds into Atom 1.0, with well formed XHTML, and encoded as UTF-8,
meaning that you don't have to worry about funky feeds, tag soup, or character
@@ -40,11 +40,11 @@
<h3>HTML</h3>
<p>A number of different normalizations of HTML are performed. For starters,
the HTML is
-<a href="http://www.feedparser.org/docs/html-sanitization.html">sanitized</a>,
+<a href="http://pythonhosted.org/feedparser/html-sanitization.html">sanitized</a>,
meaning that HTML tags and attributes that could introduce javascript or
other security risks are removed.</p>
<p>Then,
-<a href="http://www.feedparser.org/docs/resolving-relative-links.html">relative
+<a href="http://pythonhosted.org/feedparser/resolving-relative-links.html">relative
links are resolved</a> within the HTML. This is also done for links
in other areas in the feed too.</p>
<p>Finally, unmatched tags are closed. This is done with a
@@ -55,20 +55,20 @@
is also supported.</p>
<h3>Atom 1.0</h3>
<p>The Universal Feed Parser also
-<a href="http://www.feedparser.org/docs/content-normalization.html">normalizes the content of feeds</a>. This involves a
-<a href="http://www.feedparser.org/docs/reference.html">large number of elements</a>; the best place to start is to look at
-<a href="http://www.feedparser.org/docs/annotated-examples.html">annotated examples</a>. Among other things a wide variety of
-<a href="http://www.feedparser.org/docs/date-parsing.html">date formats</a>
+<a href="http://pythonhosted.org/feedparser/content-normalization.html">normalizes the content of feeds</a>. This involves a
+<a href="http://pythonhosted.org/feedparser/reference.html">large number of elements</a>; the best place to start is to look at
+<a href="http://pythonhosted.org/feedparser/annotated-examples.html">annotated examples</a>. Among other things a wide variety of
+<a href="http://pythonhosted.org/feedparser/date-parsing.html">date formats</a>
are converted into
<a href="http://www.ietf.org/rfc/rfc3339.txt">RFC 3339</a> formatted dates.</p>
-<p>If no <a href="http://www.feedparser.org/docs/reference-entry-id.html">ids</a> are found in entries, attempts are made to synthesize one using (in order):</p>
+<p>If no <a href="http://pythonhosted.org/feedparser/reference-entry-id.html">ids</a> are found in entries, attempts are made to synthesize one using (in order):</p>
<ul>
-<li><a href="http://www.feedparser.org/docs/reference-entry-link.html">link</a></li>
-<li><a href="http://www.feedparser.org/docs/reference-entry-title.html">title</a></li>
-<li><a href="http://www.feedparser.org/docs/reference-entry-summary.html">summary</a></li>
-<li><a href="http://www.feedparser.org/docs/reference-entry-content.html">content</a></li>
+<li><a href="http://pythonhosted.org/feedparser/reference-entry-link.html">link</a></li>
+<li><a href="http://pythonhosted.org/feedparser/reference-entry-title.html">title</a></li>
+<li><a href="http://pythonhosted.org/feedparser/reference-entry-summary.html">summary</a></li>
+<li><a href="http://pythonhosted.org/feedparser/reference-entry-content.html">content</a></li>
</ul>
-<p>If no <a href="http://www.feedparser.org/docs/reference-feed-
+<p>If no <a href="http://pythonhosted.org/feedparser/reference-feed-
updated.html">updated</a> dates are found in an entry, the updated date from
the feed is used. If no updated date is found in either the feed or
the entry, the current time is substituted.</p>
@@ -84,10 +84,10 @@ <h3 id="overrides">Overrides</h3>
<code>updated</code> or <code>xml:lang</code> values can't be trusted.</li>
<li><code>title_type</code>, <code>summary_type</code>,
<code>content_type</code> allow you to override the
-<a href="http://www.feedparser.org/docs/reference-entry-title_detail.html#reference.entry.title_detail.type"><code>type</code></a>
+<a href="http://pythonhosted.org/feedparser/reference-entry-title_detail.html#reference.entry.title_detail.type"><code>type</code></a>
attributes on these elements.</li>
<li><code>name_type</code> does something similar for
-<a href="http://www.feedparser.org/docs/reference-entry-author_detail.html#reference.entry.author_detail.name">author names</a></li>
+<a href="http://pythonhosted.org/feedparser/reference-entry-author_detail.html#reference.entry.author_detail.name">author names</a></li>
<li><code>future_dates</code> allows you to specify how to deal with dates which are in the future.
<ul style="margin:0">
<li><code>ignore_date</code> will cause the date to be ignored (and will therefore default to the time the entry was first seen) until the feed is updated and the time indicated is past, at which point the entry will be updated with the new date.</li>
98 docs/templates.html
View
@@ -33,22 +33,22 @@
<blockquote>
<table border="1" cellpadding="5" cellspacing="0">
<tr><th>VAR</th><th>type</th><th>source</th></tr>
-<tr><td>author</td><td>String</td><td><a href="http://feedparser.org/docs/reference-feed-author.html">author</a></td></tr>
-<tr><td>author_name</td><td>String</td><td><a href="http://feedparser.org/docs/reference-feed-author_detail.html#reference.feed.author_detail.name">author_detail.name</a></td></tr>
-<tr><td>generator</td><td>String</td><td><a href="http://feedparser.org/docs/reference-feed-generator.html">generator</a></td></tr>
-<tr><td>id</td><td>String</td><td><a href="http://feedparser.org/docs/reference-feed-id.html">id</a></td></tr>
-<tr><td>icon</td><td>String</td><td><a href="http://feedparser.org/docs/reference-feed-icon.html">icon</a></td></tr>
-<tr><td>last_updated_822</td><td>Rfc822</td><td><a href="http://feedparser.org/docs/reference-feed-icon.html">updated_parsed</a></td></tr>
-<tr><td>last_updated_iso</td><td>Rfc3399</td><td><a href="http://feedparser.org/docs/reference-feed-icon.html">updated_parsed</a></td></tr>
-<tr><td>last_updated</td><td>PlanetDate</td><td><a href="http://feedparser.org/docs/reference-feed-icon.html">updated_parsed</a></td></tr>
-<tr><td>link</td><td>String</td><td><a href="http://feedparser.org/docs/reference-feed-link.html">link</a></td></tr>
-<tr><td>logo</td><td>String</td><td><a href="http://feedparser.org/docs/reference-feed-logo.html">logo</a></td></tr>
-<tr><td>rights</td><td>String</td><td><a href="http://feedparser.org/docs/reference-feed-rights_detail.html#reference.feed.rights_detail.value">rights_detail.value</a></td></tr>
-<tr><td>subtitle</td><td>String</td><td><a href="http://feedparser.org/docs/reference-feed-subtitle_detail.html#reference.feed.subtitle_detail.value">subtitle_detail.value</a></td></tr>
-<tr><td>title</td><td>String</td><td><a href="http://feedparser.org/docs/reference-feed-title_detail.html#reference.feed.title_detail.value">title_detail.value</a></td></tr>
-<tr><td>title_plain</td><td>Plain</td><td><a href="http://feedparser.org/docs/reference-feed-title_detail.html#reference.feed.title_detail.value">title_detail.value</a></td></tr>
-<tr><td rowspan="2">url</td><td rowspan="2">String</td><td><a href="http://feedparser.org/docs/reference-feed-links.html#reference.feed.links.href">links[rel='self'].href</a></td></tr>
-<tr><td><a href="http://feedparser.org/docs/reference-headers.html">headers['location']</a></td></tr>
+<tr><td>author</td><td>String</td><td><a href="http://pythonhosted.org/feedparser/reference-feed-author.html">author</a></td></tr>
+<tr><td>author_name</td><td>String</td><td><a href="http://pythonhosted.org/feedparser/reference-feed-author_detail.html#reference.feed.author_detail.name">author_detail.name</a></td></tr>
+<tr><td>generator</td><td>String</td><td><a href="http://pythonhosted.org/feedparser/reference-feed-generator.html">generator</a></td></tr>
+<tr><td>id</td><td>String</td><td><a href="http://pythonhosted.org/feedparser/reference-feed-id.html">id</a></td></tr>
+<tr><td>icon</td><td>String</td><td><a href="http://pythonhosted.org/feedparser/reference-feed-icon.html">icon</a></td></tr>
+<tr><td>last_updated_822</td><td>Rfc822</td><td><a href="http://pythonhosted.org/feedparser/reference-feed-icon.html">updated_parsed</a></td></tr>
+<tr><td>last_updated_iso</td><td>Rfc3399</td><td><a href="http://pythonhosted.org/feedparser/reference-feed-icon.html">updated_parsed</a></td></tr>
+<tr><td>last_updated</td><td>PlanetDate</td><td><a href="http://pythonhosted.org/feedparser/reference-feed-icon.html">updated_parsed</a></td></tr>
+<tr><td>link</td><td>String</td><td><a href="http://pythonhosted.org/feedparser/reference-feed-link.html">link</a></td></tr>
+<tr><td>logo</td><td>String</td><td><a href="http://pythonhosted.org/feedparser/reference-feed-logo.html">logo</a></td></tr>
+<tr><td>rights</td><td>String</td><td><a href="http://pythonhosted.org/feedparser/reference-feed-rights_detail.html#reference.feed.rights_detail.value">rights_detail.value</a></td></tr>
+<tr><td>subtitle</td><td>String</td><td><a href="http://pythonhosted.org/feedparser/reference-feed-subtitle_detail.html#reference.feed.subtitle_detail.value">subtitle_detail.value</a></td></tr>
+<tr><td>title</td><td>String</td><td><a href="http://pythonhosted.org/feedparser/reference-feed-title_detail.html#reference.feed.title_detail.value">title_detail.value</a></td></tr>
+<tr><td>title_plain</td><td>Plain</td><td><a href="http://pythonhosted.org/feedparser/reference-feed-title_detail.html#reference.feed.title_detail.value">title_detail.value</a></td></tr>
+<tr><td rowspan="2">url</td><td rowspan="2">String</td><td><a href="http://pythonhosted.org/feedparser/reference-feed-links.html#reference.feed.links.href">links[rel='self'].href</a></td></tr>
+<tr><td><a href="http://pythonhosted.org/feedparser/reference-headers.html">headers['location']</a></td></tr>
</table>
</blockquote>
@@ -62,39 +62,39 @@
<blockquote>
<table border="1" cellpadding="5" cellspacing="0">
<tr><th>VAR</th><th>type</th><th>source</th></tr>
-<tr><td>author</td><td>String</td><td><a href="http://feedparser.org/docs/reference-entry-author.html">author</a></td></tr>
-<tr><td>author_email</td><td>String</td><td><a href="http://feedparser.org/docs/reference-entry-author_detail.html#reference.entry.author_detail.email">author_detail.email</a></td></tr>
-<tr><td>author_name</td><td>String</td><td><a href="http://feedparser.org/docs/reference-entry-author_detail.html#reference.entry.author_detail.name">author_detail.name</a></td></tr>
-<tr><td>author_uri</td><td>String</td><td><a href="http://feedparser.org/docs/reference-entry-author_detail.html#reference.entry.author_detail.href">author_detail.href</a></td></tr>
-<tr><td>content_language</td><td>String</td><td><a href="http://feedparser.org/docs/reference-entry-content.html#reference.entry.content.language">content[0].language</a></td></tr>
-<tr><td rowspan="2">content</td><td rowspan="2">String</td><td><a href="http://feedparser.org/docs/reference-entry-summary_detail.html#reference.entry.summary_detail.value">summary_detail.value</a></td></tr>
-<tr><td><a href="http://feedparser.org/docs/reference-entry-content.html#reference.entry.content.value">content[0].value</a></td></tr>
-<tr><td rowspan="2">date</td><td rowspan="2">PlanetDate</td><td><a href="http://feedparser.org/docs/reference-entry-published_parsed.html">published_parsed</a></td></tr>
-<tr><td><a href="http://feedparser.org/docs/reference-entry-updated_parsed.html">updated_parsed</a></td></tr>
-<tr><td rowspan="2">date_822</td><td rowspan="2">Rfc822</td><td><a href="http://feedparser.org/docs/reference-entry-published_parsed.html">published_parsed</a></td></tr>
-<tr><td><a href="http://feedparser.org/docs/reference-entry-updated_parsed.html">updated_parsed</a></td></tr>
-<tr><td rowspan="2">date_iso</td><td rowspan="2">Rfc3399</td><td><a href="http://feedparser.org/docs/reference-entry-published_parsed.html">published_parsed</a></td></tr>
-<tr><td><a href="http://feedparser.org/docs/reference-entry-updated_parsed.html">updated_parsed</a></td></tr>
-<tr><td><ins>enclosure_href</ins></td><td>String</td><td><a href="http://feedparser.org/docs/reference-entry-enclosures.html#reference.entry.enclosures.href">enclosures[0].href</a></td></tr>
-<tr><td><ins>enclosure_length</ins></td><td>String</td><td><a href="http://feedparser.org/docs/reference-entry-enclosures.html#reference.entry.enclosures.length">enclosures[0].length</a></td></tr>
-<tr><td><ins>enclosure_type</ins></td><td>String</td><td><a href="http://feedparser.org/docs/reference-entry-enclosures.html#reference.entry.enclosures.type">enclosures[0].type</a></td></tr>
+<tr><td>author</td><td>String</td><td><a href="http://pythonhosted.org/feedparser/reference-entry-author.html">author</a></td></tr>
+<tr><td>author_email</td><td>String</td><td><a href="http://pythonhosted.org/feedparser/reference-entry-author_detail.html#reference.entry.author_detail.email">author_detail.email</a></td></tr>
+<tr><td>author_name</td><td>String</td><td><a href="http://pythonhosted.org/feedparser/reference-entry-author_detail.html#reference.entry.author_detail.name">author_detail.name</a></td></tr>
+<tr><td>author_uri</td><td>String</td><td><a href="http://pythonhosted.org/feedparser/reference-entry-author_detail.html#reference.entry.author_detail.href">author_detail.href</a></td></tr>
+<tr><td>content_language</td><td>String</td><td><a href="http://pythonhosted.org/feedparser/reference-entry-content.html#reference.entry.content.language">content[0].language</a></td></tr>
+<tr><td rowspan="2">content</td><td rowspan="2">String</td><td><a href="http://pythonhosted.org/feedparser/reference-entry-summary_detail.html#reference.entry.summary_detail.value">summary_detail.value</a></td></tr>
+<tr><td><a href="http://pythonhosted.org/feedparser/reference-entry-content.html#reference.entry.content.value">content[0].value</a></td></tr>
+<tr><td rowspan="2">date</td><td rowspan="2">PlanetDate</td><td><a href="http://pythonhosted.org/feedparser/reference-entry-published_parsed.html">published_parsed</a></td></tr>
+<tr><td><a href="http://pythonhosted.org/feedparser/reference-entry-updated_parsed.html">updated_parsed</a></td></tr>
+<tr><td rowspan="2">date_822</td><td rowspan="2">Rfc822</td><td><a href="http://pythonhosted.org/feedparser/reference-entry-published_parsed.html">published_parsed</a></td></tr>
+<tr><td><a href="http://pythonhosted.org/feedparser/reference-entry-updated_parsed.html">updated_parsed</a></td></tr>
+<tr><td rowspan="2">date_iso</td><td rowspan="2">Rfc3399</td><td><a href="http://pythonhosted.org/feedparser/reference-entry-published_parsed.html">published_parsed</a></td></tr>
+<tr><td><a href="http://pythonhosted.org/feedparser/reference-entry-updated_parsed.html">updated_parsed</a></td></tr>
+<tr><td><ins>enclosure_href</ins></td><td>String</td><td><a href="http://pythonhosted.org/feedparser/reference-entry-enclosures.html#reference.entry.enclosures.href">enclosures[0].href</a></td></tr>
+<tr><td><ins>enclosure_length</ins></td><td>String</td><td><a href="http://pythonhosted.org/feedparser/reference-entry-enclosures.html#reference.entry.enclosures.length">enclosures[0].length</a></td></tr>
+<tr><td><ins>enclosure_type</ins></td><td>String</td><td><a href="http://pythonhosted.org/feedparser/reference-entry-enclosures.html#reference.entry.enclosures.type">enclosures[0].type</a></td></tr>
<tr><td><ins>guid_isPermaLink</ins></td><td>String</td><td><a href="http://blogs.law.harvard.edu/tech/rss#ltguidgtSubelementOfLtitemgt">isPermaLink</a></td></tr>
-<tr><td>id</td><td>String</td><td><a href="http://feedparser.org/docs/reference-entry-id.html">id</a></td></tr>
-<tr><td>link</td><td>String</td><td><a href="http://feedparser.org/docs/reference-entry-links.html#reference.entry.links.href">links[rel='alternate'].href</a></td></tr>
-<tr><td>new_channel</td><td>String</td><td><a href="http://feedparser.org/docs/reference-entry-id.html">id</a></td></tr>
-<tr><td rowspan="2">new_date</td><td rowspan="2">NewDate</td><td><a href="http://feedparser.org/docs/reference-entry-published_parsed.html">published_parsed</a></td></tr>
-<tr><td><a href="http://feedparser.org/docs/reference-entry-updated_parsed.html">updated_parsed</a></td></tr>
-<tr><td>rights</td><td>String</td><td><a href="http://feedparser.org/docs/reference-entry-rights_detail.html#reference.entry.rights_detail.value">rights_detail.value</a></td></tr>
-<tr><td>title_language</td><td>String</td><td><a href="http://feedparser.org/docs/reference-entry-title_detail.html#reference.entry.title_detail.language">title_detail.language</a></td></tr>
-<tr><td>title_plain</td><td>Plain</td><td><a href="http://feedparser.org/docs/reference-entry-title_detail.html#reference.entry.title_detail.value">title_detail.value</a></td></tr>
-<tr><td>title</td><td>String</td><td><a href="http://feedparser.org/docs/reference-entry-title_detail.html#reference.entry.title_detail.value">title_detail.value</a></td></tr>
-<tr><td>summary_language</td><td>String</td><td><a href="http://feedparser.org/docs/reference-entry-summary_detail.html#reference.entry.summary_detail.language">summary_detail.language</a></td></tr>
-<tr><td>updated</td><td>PlanetDate</td><td><a href="http://feedparser.org/docs/reference-entry-updated_parsed.html">updated_parsed</a></td></tr>
-<tr><td>updated_822</td><td>Rfc822</td><td><a href="http://feedparser.org/docs/reference-entry-updated_parsed.html">updated_parsed</a></td></tr>
-<tr><td>updated_iso</td><td>Rfc3399</td><td><a href="http://feedparser.org/docs/reference-entry-updated_parsed.html">updated_parsed</a></td></tr>
-<tr><td>published</td><td>PlanetDate</td><td><a href="http://feedparser.org/docs/reference-entry-published_parsed.html">published_parsed</a></td></tr>
-<tr><td>published_822</td><td>Rfc822</td><td><a href="http://feedparser.org/docs/reference-entry-published_parsed.html">published_parsed</a></td></tr>
-<tr><td>published_iso</td><td>Rfc3399</td><td><a href="http://feedparser.org/docs/reference-entry-published_parsed.html">published_parsed</a></td></tr>
+<tr><td>id</td><td>String</td><td><a href="http://pythonhosted.org/feedparser/reference-entry-id.html">id</a></td></tr>
+<tr><td>link</td><td>String</td><td><a href="http://pythonhosted.org/feedparser/reference-entry-links.html#reference.entry.links.href">links[rel='alternate'].href</a></td></tr>
+<tr><td>new_channel</td><td>String</td><td><a href="http://pythonhosted.org/feedparser/reference-entry-id.html">id</a></td></tr>
+<tr><td rowspan="2">new_date</td><td rowspan="2">NewDate</td><td><a href="http://pythonhosted.org/feedparser/reference-entry-published_parsed.html">published_parsed</a></td></tr>
+<tr><td><a href="http://pythonhosted.org/feedparser/reference-entry-updated_parsed.html">updated_parsed</a></td></tr>
+<tr><td>rights</td><td>String</td><td><a href="http://pythonhosted.org/feedparser/reference-entry-rights_detail.html#reference.entry.rights_detail.value">rights_detail.value</a></td></tr>
+<tr><td>title_language</td><td>String</td><td><a href="http://pythonhosted.org/feedparser/reference-entry-title_detail.html#reference.entry.title_detail.language">title_detail.language</a></td></tr>
+<tr><td>title_plain</td><td>Plain</td><td><a href="http://pythonhosted.org/feedparser/reference-entry-title_detail.html#reference.entry.title_detail.value">title_detail.value</a></td></tr>
+<tr><td>title</td><td>String</td><td><a href="http://pythonhosted.org/feedparser/reference-entry-title_detail.html#reference.entry.title_detail.value">title_detail.value</a></td></tr>
+<tr><td>summary_language</td><td>String</td><td><a href="http://pythonhosted.org/feedparser/reference-entry-summary_detail.html#reference.entry.summary_detail.language">summary_detail.language</a></td></tr>
+<tr><td>updated</td><td>PlanetDate</td><td><a href="http://pythonhosted.org/feedparser/reference-entry-updated_parsed.html">updated_parsed</a></td></tr>
+<tr><td>updated_822</td><td>Rfc822</td><td><a href="http://pythonhosted.org/feedparser/reference-entry-updated_parsed.html">updated_parsed</a></td></tr>
+<tr><td>updated_iso</td><td>Rfc3399</td><td><a href="http://pythonhosted.org/feedparser/reference-entry-updated_parsed.html">updated_parsed</a></td></tr>
+<tr><td>published</td><td>PlanetDate</td><td><a href="http://pythonhosted.org/feedparser/reference-entry-published_parsed.html">published_parsed</a></td></tr>
+<tr><td>published_822</td><td>Rfc822</td><td><a href="http://pythonhosted.org/feedparser/reference-entry-published_parsed.html">published_parsed</a></td></tr>
+<tr><td>published_iso</td><td>Rfc3399</td><td><a href="http://pythonhosted.org/feedparser/reference-entry-published_parsed.html">published_parsed</a></td></tr>
</table>
</blockquote>
<p>Note: variables above which start with
@@ -177,7 +177,7 @@
<h3>genshi</h3>
<p>Genshi approaches the power of XSLT, but with a syntax that many Python
programmers find more natural, succinct and expressive. Genshi templates
-have access to the full range of <a href="http://feedparser.org/docs/reference.html">feedparser</a> values, with the following additions:</p>
+have access to the full range of <a href="http://pythonhosted.org/feedparser/reference.html">feedparser</a> values, with the following additions:</p>
<ul>
<li>In addition to a <code>feed</code> element which describes the feed
for your planet, there is also a <code>feeds</code> element which contains
2  planet/reconstitute.py
View
@@ -75,7 +75,7 @@ def id(xentry, entry):
entry_id = entry.link
elif entry.has_key("title") and entry.title:
entry_id = (entry.title_detail.base + "/" +
- md5(entry.title).hexdigest())
+ md5(entry.title.encode('utf-8')).hexdigest())
elif entry.has_key("summary") and entry.summary:
entry_id = (entry.summary_detail.base + "/" +
md5(entry.summary).hexdigest())
8 planet/spider.py
View
@@ -45,10 +45,10 @@ def filename(directory, filename):
filename = re_final_cruft.sub("", filename)
# limit length of filename
- if len(filename)>250:
+ if len(filename)>230:
parts=filename.split(',')
for i in range(len(parts),0,-1):
- if len(','.join(parts[:i])) < 220:
+ if len(','.join(parts[:i])) < 200:
filename = ','.join(parts[:i]) + ',' + \
md5(','.join(parts[i:])).hexdigest()
break
@@ -226,7 +226,7 @@ def writeCache(feed_uri, feed_info, data):
# apply any filters
xdoc = reconstitute.reconstitute(data, entry)
- output = xdoc.toxml().encode('utf-8')
+ output = xdoc.toxml("utf-8")
xdoc.unlink()
for filter in config.filters(feed_uri):
output = shell.run(filter, output, mode="filter")
@@ -287,7 +287,7 @@ def writeCache(feed_uri, feed_info, data):
xdoc=minidom.parseString('''<feed xmlns:planet="%s"
xmlns="http://www.w3.org/2005/Atom"/>\n''' % planet.xmlns)
reconstitute.source(xdoc.documentElement,data.feed,data.bozo,data.version)
- write(xdoc.toxml().encode('utf-8'), filename(sources, feed_uri))
+ write(xdoc.toxml("utf-8"), filename(sources, feed_uri))
xdoc.unlink()
def httpThread(thread_index, input_queue, output_queue, log):
10 tests/data/reconstitute/title_nonascii.xml
View
@@ -0,0 +1,10 @@
+<!--
+Description: title value
+Expect: title_detail.language == 'en-us'
+-->
+
+<feed xmns="http://www.w3.org/2005/Atom">
+ <entry>
+ <title xml:lang="en-us">foo æøå. French: êèé </title>
+ </entry>
+</feed>
Something went wrong with that request. Please try again.