diff -Nru deskbar-applet-2.22.3/ChangeLog deskbar-applet-2.22.3.1/ChangeLog --- deskbar-applet-2.22.3/ChangeLog 2008-06-30 16:56:46.000000000 +0200 +++ deskbar-applet-2.22.3.1/ChangeLog 2008-08-03 15:34:56.000000000 +0200 @@ -1,3 +1,22 @@ +========== Version 2.22.3.1 released 2008-08-03 ========== + +2008-08-03 Sebastian Pölsterl + + * NEWS: + Added release notes + +2008-08-03 Sebastian Pölsterl + + * deskbar/handlers/desklicious.py: + Adjusted url to RSS feeds. Check if content is + formatted properly before parsing it. + Fixes bug #544645 + +2008-08-03 Sebastian Pölsterl + + * configure.ac: + Post release version bump to 2.22.3.1 + ========== Version 2.22.3 released 2008-06-30 ========== 2008-06-30 Sebastian Pölsterl diff -Nru /tmp/gv4QearROr/deskbar-applet-2.22.3/configure /tmp/2oRAIoSIXO/deskbar-applet-2.22.3.1/configure --- deskbar-applet-2.22.3/configure 2008-06-30 16:57:00.000000000 +0200 +++ deskbar-applet-2.22.3.1/configure 2008-08-03 15:35:05.000000000 +0200 @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.61 for deskbar-applet 2.22.3. +# Generated by GNU Autoconf 2.61 for deskbar-applet 2.22.3.1. # # Report bugs to . # @@ -728,8 +728,8 @@ # Identity of this package. PACKAGE_NAME='deskbar-applet' PACKAGE_TARNAME='deskbar-applet' -PACKAGE_VERSION='2.22.3' -PACKAGE_STRING='deskbar-applet 2.22.3' +PACKAGE_VERSION='2.22.3.1' +PACKAGE_STRING='deskbar-applet 2.22.3.1' PACKAGE_BUGREPORT='rslinckx@gnome.org' ac_unique_file="deskbar/__init__.py" @@ -1480,7 +1480,7 @@ # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures deskbar-applet 2.22.3 to adapt to many kinds of systems. +\`configure' configures deskbar-applet 2.22.3.1 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1550,7 +1550,7 @@ if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of deskbar-applet 2.22.3:";; + short | recursive ) echo "Configuration of deskbar-applet 2.22.3.1:";; esac cat <<\_ACEOF @@ -1672,7 +1672,7 @@ test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -deskbar-applet configure 2.22.3 +deskbar-applet configure 2.22.3.1 generated by GNU Autoconf 2.61 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, @@ -1686,7 +1686,7 @@ This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by deskbar-applet $as_me 2.22.3, which was +It was created by deskbar-applet $as_me 2.22.3.1, which was generated by GNU Autoconf 2.61. Invocation command line was $ $0 $@ @@ -2361,7 +2361,7 @@ # Define the identity of the package. PACKAGE='deskbar-applet' - VERSION='2.22.3' + VERSION='2.22.3.1' cat >>confdefs.h <<_ACEOF @@ -24336,7 +24336,7 @@ # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by deskbar-applet $as_me 2.22.3, which was +This file was extended by deskbar-applet $as_me 2.22.3.1, which was generated by GNU Autoconf 2.61. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -24389,7 +24389,7 @@ _ACEOF cat >>$CONFIG_STATUS <<_ACEOF ac_cs_version="\\ -deskbar-applet config.status 2.22.3 +deskbar-applet config.status 2.22.3.1 configured by $0, generated by GNU Autoconf 2.61, with options \\"`echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\" diff -Nru /tmp/gv4QearROr/deskbar-applet-2.22.3/configure.ac /tmp/2oRAIoSIXO/deskbar-applet-2.22.3.1/configure.ac --- deskbar-applet-2.22.3/configure.ac 2008-06-30 16:56:46.000000000 +0200 +++ deskbar-applet-2.22.3.1/configure.ac 2008-08-03 15:34:56.000000000 +0200 @@ -1,4 +1,4 @@ -AC_INIT(deskbar-applet, 2.22.3, rslinckx@gnome.org) +AC_INIT(deskbar-applet, 2.22.3.1, rslinckx@gnome.org) AC_CONFIG_SRCDIR(deskbar/__init__.py) AC_CONFIG_HEADERS(config.h) AC_CONFIG_MACRO_DIR([m4]) diff -Nru /tmp/gv4QearROr/deskbar-applet-2.22.3/debian/changelog /tmp/2oRAIoSIXO/deskbar-applet-2.22.3.1/debian/changelog --- deskbar-applet-2.22.3/debian/changelog 2008-08-08 11:26:29.000000000 +0200 +++ deskbar-applet-2.22.3.1/debian/changelog 2008-08-08 11:26:29.000000000 +0200 @@ -1,3 +1,11 @@ +deskbar-applet (2.22.3.1-0ubuntu1) hardy-proposed; urgency=low + + * New upstream version (lp: #255998): + - Adjusted url to RSS feeds. Check if content is formatted properly + before parsing it + + -- Sebastien Bacher Fri, 08 Aug 2008 11:14:00 +0200 + deskbar-applet (2.22.3-0ubuntu1) hardy-proposed; urgency=low * New upstream version (lp: #244588) diff -Nru /tmp/gv4QearROr/deskbar-applet-2.22.3/deskbar/defs.py /tmp/2oRAIoSIXO/deskbar-applet-2.22.3.1/deskbar/defs.py --- deskbar-applet-2.22.3/deskbar/defs.py 2008-06-30 16:57:19.000000000 +0200 +++ deskbar-applet-2.22.3.1/deskbar/defs.py 2008-08-03 15:35:25.000000000 +0200 @@ -1,5 +1,5 @@ DATA_DIR = "/usr/local/share" LIB_DIR = "/usr/local/lib" -VERSION = "2.22.3" +VERSION = "2.22.3.1" PACKAGE = "deskbar-applet" PYTHONDIR = "/usr/local/lib/python2.5/site-packages" diff -Nru /tmp/gv4QearROr/deskbar-applet-2.22.3/deskbar/handlers/desklicious.py /tmp/2oRAIoSIXO/deskbar-applet-2.22.3.1/deskbar/handlers/desklicious.py --- deskbar-applet-2.22.3/deskbar/handlers/desklicious.py 2008-06-30 16:56:43.000000000 +0200 +++ deskbar-applet-2.22.3.1/deskbar/handlers/desklicious.py 2008-08-03 15:34:56.000000000 +0200 @@ -19,8 +19,8 @@ GCONF_DELICIOUS_USER = GconfStore.GCONF_DIR+"/desklicious/user" -DEFAULT_QUERY_TAG = 'http://del.icio.us/rss/%s/%s' -QUERY_DELAY = 1 +DEFAULT_QUERY_TAG = 'http://feeds.delicious.com/rss/%s/%s' + HANDLERS = ["DeliciousHandler"] class DeliciousAction(ShowUrlAction): @@ -69,8 +69,6 @@ LOGGER.info( "Asking del.icio.us tags for %s" % tag ) posts = self._delicious.get_posts_by_tag(tag) - # TODO: Missing - #self.check_query_changed (timeout=QUERY_DELAY) LOGGER.info('Returning del.icio.us result') self.set_priority_for_matches( posts ) self._emit_query_ready(tag, posts ) @@ -135,45 +133,63 @@ if self._user == None: return [] - posts=[] + posts = [] #Get the info from del.icio.us and parse url = DEFAULT_QUERY_TAG % (urllib.quote_plus(self._user), urllib.quote_plus(tag)) LOGGER.debug("Opening URL %s", url) stream = None try: - try: - stream = urllib.urlopen(url, proxies=deskbar.core.Utils.get_proxy()) - dom = xml.dom.minidom.parse(stream) - except IOError, msg: - LOGGER.error("Could not open URL %s: %s, %s", url, msg[0], msg[1]) - except ExpatError, e: - LOGGER.exception(e) - finally: - if stream != None: - stream.close() + stream = urllib.urlopen(url, proxies=deskbar.core.Utils.get_proxy()) + except IOError, msg: + LOGGER.error("Could not open URL %s: %s, %s", url, msg[0], msg[1]) + return [] + + try: + dom = xml.dom.minidom.parse(stream) + except ExpatError, e: + LOGGER.exception(e) + return [] + + if stream != None: + stream.close() #And return the results try: try: for item in dom.getElementsByTagName("item"): - title_node = item.getElementsByTagName("title")[0] - url_node = item.getElementsByTagName("link")[0] - subject_node = item.getElementsByTagName("dc:subject")[0] - creator_node = item.getElementsByTagName("dc:creator")[0] + title_nodes = item.getElementsByTagName("title") + url_nodes = item.getElementsByTagName("link") + + # Check if we have expected content at all + if len(title_nodes) == 0 or len(url_nodes) == 0: + return [] + + item_title = title_nodes[0].firstChild.nodeValue + item_url = url_nodes[0].firstChild.nodeValue + + # by default we have no tags + tags = [] + subject_nodes = item.getElementsByTagName("dc:subject") + if len(subject_nodes) > 0: + subject_node = subject_nodes[0] + # There might be no tags + if (subject_node.hasChildNodes()): + tags = subject_node.firstChild.nodeValue.split(" ") - # There might be no tags - if (subject_node.hasChildNodes()): - tags = subject_node.firstChild.nodeValue.split(" ") + creator_nodes = item.getElementsByTagName("dc:creator") + if len(creator_nodes) > 0: + creator_node = creator_nodes[0] + creator = creator_node.firstChild.nodeValue else: - tags = [] + creator = self._user posts.append( DeliciousMatch( - name=title_node.firstChild.nodeValue, - url=url_node.firstChild.nodeValue, + name=item_title, + url=item_url, tags=tags, - author=creator_node.firstChild.nodeValue, + author=creator, category="web")) except DOMException, e: LOGGER.exception(e) diff -Nru /tmp/gv4QearROr/deskbar-applet-2.22.3/NEWS /tmp/2oRAIoSIXO/deskbar-applet-2.22.3.1/NEWS --- deskbar-applet-2.22.3/NEWS 2008-06-30 16:56:46.000000000 +0200 +++ deskbar-applet-2.22.3.1/NEWS 2008-08-03 15:34:56.000000000 +0200 @@ -1,3 +1,15 @@ +======================= +deskbar-applet 2.22.3.1 +======================= + +This release fixes a bug that appeared +because of the new version of delicious.com. + +Changes: + * Adjusted url to RSS feeds. Check if content is formatted properly before parsing it. Fixes bug #544645 + +Contributors to this release: Sebastian Pölsterl + ===================== deskbar-applet 2.22.3 =====================