--- aptdaemon-0.11+bzr345.orig/.pc/.version
+++ aptdaemon-0.11+bzr345/.pc/.version
@@ -0,0 +1 @@
+2
--- aptdaemon-0.11+bzr345.orig/.pc/.quilt_patches
+++ aptdaemon-0.11+bzr345/.pc/.quilt_patches
@@ -0,0 +1 @@
+debian/patches
--- aptdaemon-0.11+bzr345.orig/.pc/.quilt_series
+++ aptdaemon-0.11+bzr345/.pc/.quilt_series
@@ -0,0 +1 @@
+series
--- aptdaemon-0.11+bzr345.orig/debian/changelog
+++ aptdaemon-0.11+bzr345/debian/changelog
@@ -0,0 +1,292 @@
+aptdaemon (0.11+bzr345-0ubuntu4common0hedley1) lucid; urgency=low
+
+  * 10_backport_mav_defer_py.patch: Grab maverick's defer.py as its
+    inline_callbacks is needed by maverick's language-selector (which we are
+    grabbing to fix LP: #656632)
+  * debian/control: Change Vcs-Bzr to lp:~hedley-team/hedley/aptdaemon
+
+ -- Debbie Beliveau <debbie.beliveau@canonical.com>  Thu, 14 Oct 2010 18:36:51 -0400
+
+aptdaemon (0.11+bzr345-0ubuntu4) lucid; urgency=low
+
+  * debian/patches/04_caution_is_good.patch
+      - cherry pick fix from trunk to prevent removal of essenial
+        or required packages (LP: #561018)
+  * debian/patches/05_conffile_not_exists.patch:
+    - Do not fail on not available files (LP: #563504)
+
+ -- Michael Vogt <michael.vogt@ubuntu.com>  Fri, 16 Apr 2010 22:09:03 +0200
+
+aptdaemon (0.11+bzr345-0ubuntu3) lucid; urgency=low
+
+  * debian/patches/03_auth_me_less.patch:
+    - require only a single authentication prompt when adding
+      a repository and installing immediately from it
+      (thanks to Sebastian Heinlein)
+
+ -- Michael Vogt <michael.vogt@ubuntu.com>  Thu, 01 Apr 2010 17:34:12 +0200
+
+aptdaemon (0.11+bzr345-0ubuntu2) lucid; urgency=low
+
+  * debian/patches/02_fix_errback.patch:
+    - fix error handling from policykit (LP: #530393)
+
+ -- Michael Vogt <michael.vogt@ubuntu.com>  Thu, 01 Apr 2010 08:52:21 +0200
+
+aptdaemon (0.11+bzr345-0ubuntu1) lucid; urgency=low
+
+  * New snapshot that fixes crashes in AddRepository and
+    DpkgRecovery
+
+ -- Michael Vogt <michael.vogt@ubuntu.com>  Wed, 31 Mar 2010 10:43:22 +0200
+
+aptdaemon (0.11+bzr342-0ubuntu2) lucid; urgency=low
+
+  * debian/patches/01_enable_component.patch:
+    - add missing EnableComponents call to fix bug when
+      components are referenced but not enabled
+
+ -- Michael Vogt <michael.vogt@ubuntu.com>  Tue, 30 Mar 2010 16:19:38 +0200
+
+aptdaemon (0.11+bzr342-0ubuntu1) lucid; urgency=low
+
+  * New snapshot release based on the stable branch
+    - fixes debconf race condition (LP: #455861)
+    - should fix freeze in software-center (LP: #544424)
+  * .bzr-builddeb/default.conf:
+    - updatd to point at the stable 0.2.x branch
+  * debian/patches/01_unused_removal.patch:
+    - removed, taken upstream
+  * debian/patches/02_fix-455861.patch:
+    - removed, taken upstream
+
+ -- Michael Vogt <michael.vogt@ubuntu.com>  Fri, 26 Mar 2010 10:15:37 +0100
+
+aptdaemon (0.11+bzr322-0ubuntu2) lucid; urgency=low
+
+  * debian/patches/02_fix-455861.patch:
+    - merge patch from james_w to fix race in debconf socket
+      code (many thanks) LP: #455861
+
+ -- Michael Vogt <michael.vogt@ubuntu.com>  Tue, 16 Mar 2010 17:17:53 +0100
+
+aptdaemon (0.11+bzr322-0ubuntu1) lucid; urgency=low
+
+  * New git snapshot
+  * debian/patches/series:
+    - add 01_unused_removal.patch to allow removal of no longer
+      used dependencies on removal
+
+ -- Michael Vogt <michael.vogt@ubuntu.com>  Mon, 04 Jan 2010 12:59:14 +0100
+
+aptdaemon (0.11+bzr319-0ubuntu1) lucid; urgency=low
+
+  * New git snapshot
+    - support generic meta-data for a transaction (LP: #493775)
+    - improvements to the gtk widgets
+    - bugfixes
+  * debian/control:
+    - add break on software-center
+
+ -- Michael Vogt <michael.vogt@ubuntu.com>  Mon, 14 Dec 2009 11:33:47 +0100
+
+aptdaemon (0.11+bzr297-0ubuntu1) lucid; urgency=low
+
+  * New git snapshot, API improvements
+  * debian/control:
+    - update Vcs-Bzr branch to point to "ubuntu-lucid"
+  * debian/patches/aptd-sbin.patch,
+    debian/patches/aptd_http_proxy.patch:
+    - removed, taken upstream
+
+ -- Michael Vogt <michael.vogt@ubuntu.com>  Mon, 07 Dec 2009 18:08:28 +0100
+
+aptdaemon (0.10+bzr264-0ubuntu1) karmic; urgency=low
+
+  [ Sebastian Heinlein ]
+  * Import translations from Launchpad - fixes LP #445603 
+  * If the cache refresh was cancelled do not show a download 
+    failed error - fixes LP #440941
+  
+  [ Michael Vogt ]
+  * fix install file to ensure the translations gets installed
+
+ -- Michael Vogt <michael.vogt@ubuntu.com>  Wed, 14 Oct 2009 18:19:12 +0200
+
+aptdaemon (0.10+bzr260-0ubuntu1) karmic; urgency=low
+
+  [ Sebastian Heinlein ]
+  * Merge fix for killing randomly user processes on hung dpkg 
+    operations - fixes LP: #446534 
+
+ -- Michael Vogt <michael.vogt@ubuntu.com>  Mon, 12 Oct 2009 17:20:15 +0200
+
+aptdaemon (0.10+bzr259-0ubuntu1) karmic; urgency=low
+
+  * debian/patches/aptd_http_proxy.patch:
+    - add basic http proxy proxy support (LP: #446069)
+  * dropped patches:
+    - debian/patches/aptd_locking_fixes.patch
+    - debian/patches/fix_syslog_crash.patch
+    Both got accepted upstream (no other changes in r259)
+
+ -- Michael Vogt <michael.vogt@ubuntu.com>  Fri, 09 Oct 2009 10:16:49 +0200
+
+aptdaemon (0.10+bzr258-0ubuntu1) karmic; urgency=low
+
+  * New upstream snapshot:
+    - fix hang in authentication dialog (LP: #426720)
+    - don't ask for authentication twice (LP: #437094)
+    - better handling for broken dependencies
+  * remove mvo-branch.patch, disallow-unauthenticated-branch.diff
+    both got merged upstream
+  * debian/patches/fix_syslog_crash.patch:
+    - fix crash if no syslogd is installed
+  * aptdaemon/worker.py:
+    - test lock of the apt download dir as well 
+
+ -- Michael Vogt <michael.vogt@ubuntu.com>  Tue, 06 Oct 2009 09:01:10 +0200
+
+aptdaemon (0.10+bzr242-0ubuntu3) karmic; urgency=low
+
+  * debian/patches/mvo-branch.patch:
+    - updated to include fix debconf race with multiple transactions 
+      in the queue (LP: #432607)
+
+ -- Michael Vogt <michael.vogt@ubuntu.com>  Fri, 02 Oct 2009 14:40:47 +0200
+
+aptdaemon (0.10+bzr242-0ubuntu2) karmic; urgency=low
+
+  * debian/patches/mvo-branch.patch:
+    - updated to include fix for gettext fiddling (LP: #438077)
+
+ -- Michael Vogt <michael.vogt@ubuntu.com>  Mon, 28 Sep 2009 18:54:35 +0200
+
+aptdaemon (0.10+bzr242-0ubuntu1) karmic; urgency=low
+
+  * aptdaemon/core.py:
+    - do not fail on a not running syslog daemon (LP: #428843)
+  * Include dpkg errors in the error output
+  * debian/rules:
+    - move to simple-patchsys (for now) to make maintaining the
+      patches simpler
+  * debian/patches/disallow-unauthenticated-branch.diff:
+    Patch generated from lp:~mvo/aptdaemon/allow-unauthenticated
+    to support controlling if unauthenticated packages are allowed
+    during a transaction. Default to "not allow unauthenticated"
+    (LP: #435313)
+  * debian/patches/mvo-branch.patch:
+    Patch generated from lp:~mvo/aptdaemon/mvo that fixes:
+    - aptdaemon/worker.py: check the apt download dir lock 
+      in _watch_lock to avoid possible race with apt-get LP: #437709
+    - aptdaemon/progress.py: fix crash in error handling (LP: #436808)
+    - aptdaemon/progress.py: fix crash in INSTALL_TIMEOUT handling 
+      (LP: #430860)
+    - aptdaemon/gtkwidgets.py: make the dialog resizable and add bigger 
+      default size (LP: #434937)
+    - aptdaemon/core.py: add _remove_from_connection_no_raise() that 
+      will discard errors if the object is not exported (LP: #422585)
+
+ -- Michael Vogt <michael.vogt@ubuntu.com>  Mon, 28 Sep 2009 09:39:34 +0200
+
+aptdaemon (0.10+bzr240-0ubuntu1) karmic; urgency=low
+
+  * New upstream snapshot version:
+    - Allow to cancel a running transaction in the console client 
+      (LP: #424436)
+    - fixes in config file handling code
+    - fixes in the error handling of the daemon
+    - better error reporting for dpkg failures
+
+ -- Michael Vogt <michael.vogt@ubuntu.com>  Tue, 22 Sep 2009 12:07:47 +0200
+
+aptdaemon (0.10+bzr234-0ubuntu1) karmic; urgency=low
+
+  * New upstream snapshot version:
+    - less verbose debug (LP: #432937)
+    - do not send dbus signal if dbus is not available (LP: #432310)
+    - bugfixes
+    - conffile handling
+    - fix in progress code (LP #428964)
+    - improvements in the logging
+
+ -- Michael Vogt <michael.vogt@ubuntu.com>  Mon, 21 Sep 2009 18:01:09 +0200
+
+aptdaemon (0.10+bzr226-0ubuntu1) karmic; urgency=low
+
+  * When the dpkg lock is taken, wait until its released and
+    emit a appropriate status (LP: #420980)
+  * setup correct TERM environment in the daemon
+
+ -- Michael Vogt <michael.vogt@ubuntu.com>  Tue, 01 Sep 2009 18:40:25 +0200
+
+aptdaemon (0.10+bzr223-0ubuntu1) karmic; urgency=low
+
+  * fix bug in repository adding code when a empty components
+    list is used
+
+ -- Michael Vogt <michael.vogt@ubuntu.com>  Thu, 27 Aug 2009 17:02:16 +0200
+
+aptdaemon (0.10+bzr222-0ubuntu1) karmic; urgency=low
+
+  * fix AttributeError (LP: #403467)
+  * add support for adding repositories
+
+ -- Michael Vogt <michael.vogt@ubuntu.com>  Thu, 27 Aug 2009 14:46:20 +0200
+
+aptdaemon (0.10+bzr220-0ubuntu1) karmic; urgency=low
+
+  * new version that includes a transaction cache and
+    bugfixes
+
+ -- Michael Vogt <michael.vogt@ubuntu.com>  Mon, 24 Aug 2009 17:33:22 +0200
+
+aptdaemon (0.10+bzr216-0ubuntu1) karmic; urgency=low
+
+  [ Sebastian Heinlein ]
+  * New snapshot release:
+    - API change: Use a D-Bus properties interface for setting terminal, locale
+      and debconf socket
+    - Use a simple async programming mechanism inspired by Twisted's deferreds
+    - Port to PolicyKit-1 
+    - Allow to manage APT gpg keys (thanks to Olof Kindgren)
+    - Fix progress calcualtion during installation
+  * debian/control:
+    - Replace dependency on policykit by policykit-1
+  * debian/aptdaemon.install: Adapt install location of PolicyKit-1 action files
+  * debian/python-aptdaemon.install: 
+    - Replaced policykit.py by policykit1.py
+    - Added loop.py and defer.py
+
+  [ Stephan Peijnik ]
+  * debian/control: Replaced build-dependency on python-all-dev with python.
+  * debian/aptdaemon.install: Removed misc.py
+  * debian/copyright: Fixed lintian warning about dh_make boilerplate.
+	
+ -- Michael Vogt <michael.vogt@ubuntu.com>  Mon, 17 Aug 2009 08:22:13 +0200
+
+aptdaemon (0.10+bzr208-0ubuntu1) karmic; urgency=low
+
+  * updated to current bzr
+
+ -- Michael Vogt <michael.vogt@ubuntu.com>  Fri, 10 Jul 2009 09:32:00 +0200
+
+aptdaemon (0.10+bzr185-0ubuntu1) karmic; urgency=low
+
+  * updated to current bzr
+  * fixd FTBFS
+  * adjust install files
+
+ -- Michael Vogt <michael.vogt@ubuntu.com>  Mon, 06 Jul 2009 09:56:53 +0200
+
+aptdaemon (0.10+bzr173.1-0ubuntu1) karmic; urgency=low
+
+  * fix incorrect setup.py from a unclean build env
+
+ -- Michael Vogt <michael.vogt@ubuntu.com>  Thu, 02 Jul 2009 11:09:28 +0200
+
+aptdaemon (0.10+bzr173-0ubuntu1) karmic; urgency=low
+
+  * Initial Release.
+
+ -- Sebastian Heinlein <devel@glatzor.de>  Tue, 30 Jun 2009 15:06:36 +0200
--- aptdaemon-0.11+bzr345.orig/debian/README.Debian
+++ aptdaemon-0.11+bzr345/debian/README.Debian
@@ -0,0 +1,9 @@
+This is the ubuntu version of aptdaemon.
+
+We carry the following patch that may not get upstream:
+03_auth_me_less.patch:
+ Its for the use case when adding a repository, doing a reload
+ and immediately installing a package from it. Upstream is fine
+ with the patch as a distro patch but it may not make it upstream
+
+ -- Michael Vogt <michael.vogt@ubuntu.com>, Thu,  1 Apr 2010 17:36:57 +0200
--- aptdaemon-0.11+bzr345.orig/debian/rules
+++ aptdaemon-0.11+bzr345/debian/rules
@@ -0,0 +1,11 @@
+#!/usr/bin/make -f
+
+DEB_PYTHON_SYSTEM=pycentral
+export DH_PYCENTRAL=include-links
+
+include /usr/share/cdbs/1/rules/debhelper.mk
+include /usr/share/cdbs/1/class/python-distutils.mk
+include /usr/share/cdbs/1/rules/simple-patchsys.mk
+
+binary-install/python-aptdaemon-gtk::
+	dh_icons -p$(cdbs_curpkg)
--- aptdaemon-0.11+bzr345.orig/debian/python-aptdaemon.install
+++ aptdaemon-0.11+bzr345/debian/python-aptdaemon.install
@@ -0,0 +1,12 @@
+usr/lib/python2.*/*-packages/aptdaemon/__init__.py
+usr/lib/python2.*/*-packages/aptdaemon/client.py
+usr/lib/python2.*/*-packages/aptdaemon/console.py
+usr/lib/python2.*/*-packages/aptdaemon/core.py
+usr/lib/python2.*/*-packages/aptdaemon/debconf.py
+usr/lib/python2.*/*-packages/aptdaemon/defer.py
+usr/lib/python2.*/*-packages/aptdaemon/enums.py
+usr/lib/python2.*/*-packages/aptdaemon/errors.py
+usr/lib/python2.*/*-packages/aptdaemon/loop.py
+usr/lib/python2.*/*-packages/aptdaemon/policykit1.py
+usr/lib/python2.*/*-packages/aptdaemon/progress.py
+usr/lib/python2.*/*-packages/aptdaemon/worker.py
--- aptdaemon-0.11+bzr345.orig/debian/python-aptdaemon-gtk.install
+++ aptdaemon-0.11+bzr345/debian/python-aptdaemon-gtk.install
@@ -0,0 +1,2 @@
+usr/lib/python2.*/*-packages/aptdaemon/gtkwidgets.py
+usr/share/icons/hicolor/*/*/aptdaemon*.png
--- aptdaemon-0.11+bzr345.orig/debian/control
+++ aptdaemon-0.11+bzr345/debian/control
@@ -0,0 +1,88 @@
+Source: aptdaemon
+Section: admin
+Priority: extra
+Maintainer: Ubuntu Core Developers <ubuntu-devel-discuss@lists.ubuntu.com>
+XSBC-Original-Maintainer: Sebastian Heinlein <devel@glatzor.de>
+Build-Depends: 
+	cdbs,
+	debhelper (>= 7),
+	quilt,
+	python,
+	python-central (>= 0.5),
+	python-setuptools,
+	python-distutils-extra
+Standards-Version: 3.8.2
+Homepage: https://launchpad.net/aptdaemon
+Vcs-Bzr: lp:~hedley-team/hedley/aptdaemon
+Vcs-Browser: https://code.launchpad.net/~aptdaemon-developers/aptdaemon/ubuntu-lucid
+XS-Python-Version: >= 2.6
+
+Package: aptdaemon
+Architecture: all
+Section: admin
+Depends:
+	${misc:Depends},
+	${python:Depends},
+	python-aptdaemon (= ${binary:Version})
+Breaks: software-center (<< 1.1.21)
+XB-Python-Version: ${python:Versions}
+Description: transaction based package management service
+ Aptdaemon allows normal users to perform package management tasks, e.g. 
+ refreshing the cache, upgrading the system, installing or removing software 
+ packages.
+ .
+ Currently it comes with the following main features:
+ .
+  - Programming language independent D-Bus interface, which allows to
+    write clients in several languages
+  - Runs only if required (D-Bus activation)
+  - Fine grained privilege management using PolicyKit, e.g. allowing all
+    desktop user to query for updates without entering a password
+  - Support for media changes during installation from DVD/CDROM
+  - Support for debconf (Debian's package configuration system)
+  - Support for attaching a terminal to the underlying dpkg call
+ .
+ This package contains the aptd script and all the data files required to run
+ the daemon. Moreover it contains the aptdcon script, which is a command
+ line client for aptdaemon.
+
+Package: python-aptdaemon
+Architecture: all
+Section: python
+Depends:
+	${shlibs:Depends}, 
+	${misc:Depends},
+	${python:Depends},
+	python-apt (>= 0.7.9),
+	python-gobject,
+	policykit-1
+Recommends: aptdaemon
+XB-Python-Version: ${python:Versions}
+Description: Python module for the server and client of aptdaemon
+ Aptdaemon is a transaction based package management service. It allows 
+ normal users to perform package management tasks, e.g. refreshing the 
+ cache, upgrading the system, installing or removing software packages.
+ .
+ This package provides the Python modules required to run aptdaemon
+ and to implement a client.
+
+Package: python-aptdaemon-gtk
+Architecture: all
+Section: python
+Depends:
+	${shlibs:Depends}, 
+	${misc:Depends},
+	${python:Depends},
+	python-aptdaemon (= ${binary:Version}),
+	python-gtk2,
+	python-vte
+XB-Python-Version: ${python:Versions}
+Description: Python GTK+ widgets to run an aptdaemon client
+ Aptdaemon is a transaction based package management daemon. It allows 
+ normal users to perform package management tasks, e.g. refreshing the 
+ cache, upgrading the system, installing or removing software packages.
+ .
+ This package provides the Python GTK+ widgets to implement a fully working
+ graphical client. The widgets can be used to initiate, to monitor and
+ to control a transaction.
+
--- aptdaemon-0.11+bzr345.orig/debian/aptdaemon.install
+++ aptdaemon-0.11+bzr345/debian/aptdaemon.install
@@ -0,0 +1,7 @@
+etc/apt/apt.conf.d/20dbus
+etc/dbus-1/system.d/org.debian.apt.conf
+usr/bin/aptd /usr/sbin
+usr/bin/aptdcon
+usr/share/dbus-1/system-services/org.debian.apt.service
+usr/share/polkit-1/actions/org.debian.apt.policy
+usr/share/locale
\ No newline at end of file
--- aptdaemon-0.11+bzr345.orig/debian/python-aptdaemon-gtk.examples
+++ aptdaemon-0.11+bzr345/debian/python-aptdaemon-gtk.examples
@@ -0,0 +1 @@
+gtk-demo.py
--- aptdaemon-0.11+bzr345.orig/debian/compat
+++ aptdaemon-0.11+bzr345/debian/compat
@@ -0,0 +1 @@
+7
--- aptdaemon-0.11+bzr345.orig/debian/copyright
+++ aptdaemon-0.11+bzr345/debian/copyright
@@ -0,0 +1,52 @@
+This package was debianized by Sebastian Heinlein <devel@glatzor.de> on
+Mon, 05 Jan 2009 00:03:58 +0100.
+
+It was downloaded from https://launchpad.net/aptdaemon
+
+Upstream Authors:
+
+    Sebastian Heinlein <devel@glatzor.de>
+    Michael Vogt <mvo@ubuntu.com>
+
+Copyright:
+
+    Copyright (C) 2008-2009 Sebastian Heinlein <devel@glatzor.de>
+
+License:
+
+    This package is free software; you can redistribute it and/or modify
+    it under the terms of the GNU General Public License as published by
+    the Free Software Foundation; either version 2 of the License, or
+    (at your option) any later version.
+
+    This package is distributed in the hope that it will be useful,
+    but WITHOUT ANY WARRANTY; without even the implied warranty of
+    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+    GNU General Public License for more details.
+
+    You should have received a copy of the GNU General Public License
+    along with this package; if not, write to the Free Software
+    Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301 USA
+
+On Debian systems, the complete text of the GNU General
+Public License can be found in `/usr/share/common-licenses/GPL'.
+
+The Debian packaging is (C) 2009, Sebastian Heinlein <devel@glatzor.de> and
+is licensed under the GPL, see above.
+
+The file aptdaemon/clients.py is
+
+    Copyright (C) 2008 Canonical Ltd.
+    Copyright (C) 2008 Aidan Skinner <aidan@skinner.me.uk>
+    Copyright (C) 2008 Martin Pitt <martin.pitt@ubuntu.com>
+    Copyright (C) 2008 Tim Lauridsen <timlau@fedoraproject.org>
+    Copyright (C) 2008 Sebastian Heinlein <devel@glatzor.de>
+
+and is licensed under the GPL, see above.
+
+The file aptdaemon/debconf.py is
+
+    Copyright (C) 2009 Sebastian Heinlein <devel@glatzor.de>
+    Copyright (C) 2009 Michael Vogt <mvo@ubuntu.com>
+
+and is licensed under the GPL, see above.
--- aptdaemon-0.11+bzr345.orig/debian/patches/02_fix_errback.patch
+++ aptdaemon-0.11+bzr345/debian/patches/02_fix_errback.patch
@@ -0,0 +1,22 @@
+=== modified file 'aptdaemon/client.py'
+--- aptdaemon/client.py	2010-02-21 11:54:16 +0000
++++ aptdaemon/client.py	2010-04-01 06:42:46 +0000
+@@ -830,6 +841,8 @@
+                 method = self.apt_control.get_dbus_method(method_name)
+                 method(reply_handler=set_locale, error_handler=error_handler,
+                        *args)
++            else:
++                error_handler(error)
+ 
+         async = reply_handler and error_handler
+         # Request a new transaction
+@@ -849,6 +862,8 @@
+                     self.apt_control = get_aptdaemon()
+                     method = self.apt_control.get_dbus_method(method_name)
+                     tid = method(*args)
++                else:
++                    raise error
+             return set_locale(tid)
+ 
+ 
+
--- aptdaemon-0.11+bzr345.orig/debian/patches/10_backport_mav_defer_py.patch
+++ aptdaemon-0.11+bzr345/debian/patches/10_backport_mav_defer_py.patch
@@ -0,0 +1,307 @@
+Index: aptdaemon/aptdaemon/defer.py
+===================================================================
+--- aptdaemon.orig/aptdaemon/defer.py	2010-10-14 16:01:23.000000000 -0400
++++ aptdaemon/aptdaemon/defer.py	2010-10-14 16:01:39.000000000 -0400
+@@ -1,29 +1,85 @@
+ #!/usr/bin/env python
+ # -*- coding: utf-8 -*-
+ """Simplified Twisted Deferreds."""
+-# Copyright (C) 2008-2009 Sebastian Heinlein <devel@glatzor.de>
++# Copyright (C) 2008-2010 Sebastian Heinlein <devel@glatzor.de>
++# Copyright (c) 2001-2010
++# Allen Short
++# Andy Gayton
++# Andrew Bennetts
++# Antoine Pitrou
++# Apple Computer, Inc.
++# Benjamin Bruheim
++# Bob Ippolito
++# Canonical Limited
++# Christopher Armstrong
++# David Reid
++# Donovan Preston
++# Eric Mangold
++# Eyal Lotem
++# Itamar Shtull-Trauring
++# James Knight
++# Jason A. Mobarak
++# Jean-Paul Calderone
++# Jessica McKellar
++# Jonathan Jacobs
++# Jonathan Lange
++# Jonathan D. Simms
++# Jürgen Hermann
++# Kevin Horn
++# Kevin Turner
++# Mary Gardiner
++# Matthew Lefkowitz
++# Massachusetts Institute of Technology
++# Moshe Zadka
++# Paul Swartz
++# Pavel Pergamenshchik
++# Ralph Meijer
++# Sean Riley
++# Software Freedom Conservancy
++# Travis B. Hartwell
++# Thijs Triemstra
++# Thomas Herve
++# Timothy Allen
+ #
+-# This program is free software; you can redistribute it and/or modify
+-# it under the terms of the GNU General Public License as published by
+-# the Free Software Foundation; either version 2 of the License, or
+-# any later version.
++# Permission is hereby granted, free of charge, to any person obtaining
++# a copy of this software and associated documentation files (the
++# "Software"), to deal in the Software without restriction, including
++# without limitation the rights to use, copy, modify, merge, publish,
++# distribute, sublicense, and/or sell copies of the Software, and to
++# permit persons to whom the Software is furnished to do so, subject to
++# the following conditions:
+ #
+-# This program is distributed in the hope that it will be useful,
+-# but WITHOUT ANY WARRANTY; without even the implied warranty of
+-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+-# GNU General Public License for more details.
++# The above copyright notice and this permission notice shall be
++# included in all copies or substantial portions of the Software.
+ #
+-# You should have received a copy of the GNU General Public License along
+-# with this program; if not, write to the Free Software Foundation, Inc.,
+-# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
++# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
++# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
++# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
++# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
++# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
++# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
++# THE SOFTWARE.
+ 
+ __author__  = "Sebastian Heinlein <devel@glatzor.de>"
+ 
++__all__ = ("Deferred", "AlreadyCalledDeferred", "DeferredException",
++           "defer", "dbus_deferred_method", "inline_callbacks", "return_value",
++           "deferable")
++
++import inspect
+ from functools import wraps
+ import sys
++import warnings
+ 
+ import dbus
+ 
++
++class _DefGen_Return(BaseException):
++    """Exception to return a result from an inline callback."""
++    def __init__(self, value):
++        self.value = value
++
++
+ class AlreadyCalledDeferred(Exception):
+     """The Deferred is already running a callback."""
+ 
+@@ -286,7 +342,9 @@
+         """
+         if self.called:
+             raise AlreadyCalledDeferred()
+-        if not isinstance(error, DeferredException):
++        if not error:
++            error = DeferredException()
++        elif not isinstance(error, DeferredException):
+             assert isinstance(error, Exception)
+             error = DeferredException(error.__class__, error, None)
+         self.called = True
+@@ -414,7 +472,193 @@
+         return wrapper
+     return decorator
+ 
++def deferable(func):
++    """Add a defer attribute to the decorated function and return a Deferred
++    object. The callback of the Deferred will be passed as reply_handler
++    argument and the errback as the error_handler argument to the decorated
++    function.
++
++    This decorator allows to easily make use of Deferreds in a DBus client.
++    """
++    @wraps(func)
++    def _deferable(*args, **kwargs):
++        def on_error(error, deferred):
++            # Make sure that we return a deferred exception
++            if isinstance(error, DeferredException):
++                deferred.errback(error)
++            else:
++                deferred.errback(DeferredException(error))
++
++        try:
++            # Check if the defer argument was specified
++            to_defer = kwargs.pop("defer")
++        except KeyError:
++            # Check if this function was called from an inline_callbacks
++            # decorated method
++            stack = inspect.stack()
++            try:
++                to_defer = stack[2][3] == "_inline_callbacks"
++            except IndexError:
++                to_defer = False
++
++        if to_defer:
++            deferred = Deferred()
++            kwargs["reply_handler"] = deferred.callback
++            kwargs["error_handler"] = lambda err: on_error(err, deferred)
++            func(*args, **kwargs)
++            return deferred
++        return func(*args, **kwargs)
++    return _deferable
++
+ def _passthrough(arg):
+     return arg
+ 
++def return_value(val):
++    """
++    Return val from a inline_callbacks generator.
++
++    Note: this is currently implemented by raising an exception
++    derived from BaseException.  You might want to change any
++    'except:' clauses to an 'except Exception:' clause so as not to
++    catch this exception.
++
++    Also: while this function currently will work when called from
++    within arbitrary functions called from within the generator, do
++    not rely upon this behavior.
++    """
++    raise _DefGen_Return(val)
++
++def _inline_callbacks(result, gen, deferred):
++    """
++    See inlineCallbacks.
++    """
++    # This function is complicated by the need to prevent unbounded recursion
++    # arising from repeatedly yielding immediately ready deferreds.  This while
++    # loop and the waiting variable solve that by manually unfolding the
++    # recursion.
++
++    waiting = [True, # waiting for result?
++               None] # result
++
++    while 1:
++        try:
++            # Send the last result back as the result of the yield expression.
++            is_failure = isinstance(result, DeferredException)
++            if is_failure:
++                result = gen.throw(result.type, result.value, result.traceback)
++            else:
++                result = gen.send(result)
++        except StopIteration:
++            # fell off the end, or "return" statement
++            deferred.callback(None)
++            return deferred
++        except _DefGen_Return, err:
++            # returnValue() was called; time to give a result to the original
++            # Deferred.  First though, let's try to identify the potentially
++            # confusing situation which results when return_value() is
++            # accidentally invoked from a different function, one that wasn't
++            # decorated with @inline_callbacks.
++
++            # The traceback starts in this frame (the one for
++            # _inline_callbacks); the next one down should be the application
++            # code.
++            appCodeTrace = sys.exc_info()[2].tb_next
++            if is_failure:
++                # If we invoked this generator frame by throwing an exception
++                # into it, then throwExceptionIntoGenerator will consume an
++                # additional stack frame itself, so we need to skip that too.
++                appCodeTrace = appCodeTrace.tb_next
++            # Now that we've identified the frame being exited by the
++            # exception, let's figure out if returnValue was called from it
++            # directly.  returnValue itself consumes a stack frame, so the
++            # application code will have a tb_next, but it will *not* have a
++            # second tb_next.
++            if appCodeTrace.tb_next and appCodeTrace.tb_next.tb_next:
++                # If returnValue was invoked non-local to the frame which it is
++                # exiting, identify the frame that ultimately invoked
++                # returnValue so that we can warn the user, as this behavior is
++                # confusing.
++                ultimateTrace = appCodeTrace
++                while ultimateTrace.tb_next.tb_next:
++                    ultimateTrace = ultimateTrace.tb_next
++                filename = ultimateTrace.tb_frame.f_code.co_filename
++                lineno = ultimateTrace.tb_lineno
++                warnings.warn_explicit(
++                    "returnValue() in %r causing %r to exit: "
++                    "returnValue should only be invoked by functions decorated "
++                    "with inlineCallbacks" % (
++                        ultimateTrace.tb_frame.f_code.co_name,
++                        appCodeTrace.tb_frame.f_code.co_name),
++                    DeprecationWarning, filename, lineno)
++            deferred.callback(err.value)
++            return deferred
++        except:
++            deferred.errback()
++            return deferred
++
++        if isinstance(result, Deferred):
++            # a deferred was yielded, get the result.
++            def gotResult(res):
++                if waiting[0]:
++                    waiting[0] = False
++                    waiting[1] = res
++                else:
++                    _inline_callbacks(res, gen, deferred)
++
++            result.add_callbacks(gotResult, gotResult)
++            if waiting[0]:
++                # Haven't called back yet, set flag so that we get reinvoked
++                # and return from the loop
++                waiting[0] = False
++                return deferred
++
++            result = waiting[1]
++            # Reset waiting to initial values for next loop.  gotResult uses
++            # waiting, but this isn't a problem because gotResult is only
++            # executed once, and if it hasn't been executed yet, the return
++            # branch above would have been taken.
++            waiting[0] = True
++            waiting[1] = None
++    return deferred
++
++def inline_callbacks(func):
++    """inline_callbacks helps you write Deferred-using code that looks like a
++    regular sequential function. For example:
++
++        def thingummy():
++            thing = yield makeSomeRequestResultingInDeferred()
++            print thing #the result! hoorj!
++        thingummy = inline_callbacks(thingummy)
++
++    When you call anything that results in a Deferred, you can simply yield it;
++    your generator will automatically be resumed when the Deferred's result is
++    available. The generator will be sent the result of the Deferred with the
++    'send' method on generators, or if the result was a failure, 'throw'.
++
++    Your inline_callbacks-enabled generator will return a Deferred object, which
++    will result in the return value of the generator (or will fail with a
++    failure object if your generator raises an unhandled exception). Note that
++    you can't use return result to return a value; use return_value(result)
++    instead. Falling off the end of the generator, or simply using return
++    will cause the Deferred to have a result of None.
++
++    The Deferred returned from your deferred generator may errback if your
++    generator raised an exception:
++
++        def thingummy():
++            thing = yield makeSomeRequestResultingInDeferred()
++            if thing == 'I love Twisted':
++                # will become the result of the Deferred
++                return_value('TWISTED IS GREAT!')
++            else:
++                # will trigger an errback
++                raise Exception('DESTROY ALL LIFE')
++        thingummy = inline_callbacks(thingummy)
++    """
++    @wraps(func)
++    def unwind_generator(*args, **kwargs):
++        return _inline_callbacks(None, func(*args, **kwargs), Deferred())
++    return unwind_generator
++
++
+ # vim:tw=4:sw=4:et
--- aptdaemon-0.11+bzr345.orig/debian/patches/03_auth_me_less.patch
+++ aptdaemon-0.11+bzr345/debian/patches/03_auth_me_less.patch
@@ -0,0 +1,100 @@
+=== modified file 'aptdaemon/core.py'
+--- aptdaemon/core.py	2010-03-31 08:46:59 +0000
++++ aptdaemon/core.py	2010-04-01 14:41:59 +0000
+@@ -910,8 +910,16 @@
+         sender -- the unique D-Bus name of the sender (provided by D-Bus)
+         """
+         log.info("UpdateCache() was called")
++        # UBUNTU-HACK: Check silently if changing repositories has been granted
++        #              before to reduce clicks to install packages from
++        #              partner repository.
++        #              AddRepository -> UpdateCache -> InstallPackages
+         deferred = policykit1.check_authorization_by_name(sender,
++                                         policykit1.PK_ACTION_CHANGE_REPOSITORY,
++                                         flags=policykit1.CHECK_AUTH_NONE)
++        auth_update = lambda x: policykit1.check_authorization_by_name(sender,
+                                               policykit1.PK_ACTION_UPDATE_CACHE)
++        deferred.add_errback(auth_update)
+         deferred.add_callback(lambda x: policykit1.get_uid_from_dbus_name(sender))
+         deferred.add_callback(lambda uid: Transaction(ROLE_UPDATE_CACHE,
+                                                       self.queue, uid))
+@@ -1022,8 +1030,16 @@
+         """
+         log.info("InstallPackages() was called: %s" % package_names)
+         packages = (package_names, [], [], [], [])
++        # UBUNTU-HACK: Check silently if changing repositories has been granted
++        #              before to reduce clicks to install packages from
++        #              partner repository.
++        #              AddRepository -> UpdateCache -> InstallPackages
+         deferred = policykit1.check_authorization_by_name(sender,
+-                                          policykit1.PK_ACTION_INSTALL_PACKAGES)
++                                         policykit1.PK_ACTION_CHANGE_REPOSITORY,
++                                         flags=policykit1.CHECK_AUTH_NONE)
++        auth_inst = lambda x: policykit1.check_authorization_by_name(sender,
++                                         policykit1.PK_ACTION_INSTALL_PACKAGES)
++        deferred.add_errback(auth_inst)
+         deferred.add_callback(lambda x: \
+                               policykit1.get_uid_from_dbus_name(sender))
+         deferred.add_callback(lambda uid: Transaction(ROLE_INSTALL_PACKAGES,
+
+=== modified file 'aptdaemon/policykit1.py'
+--- aptdaemon/policykit1.py	2010-01-08 07:55:35 +0000
++++ aptdaemon/policykit1.py	2010-04-01 14:38:48 +0000
+@@ -52,7 +52,8 @@
+         self.action_id = action_id
+         self.subject = subject
+ 
+-def check_authorization_by_name(dbus_name, action_id, timeout=300, bus=None):
++def check_authorization_by_name(dbus_name, action_id, timeout=300, bus=None,
++                                flags=None):
+     """Check if the given sender is authorized for the specified action.
+ 
+     If the sender is not authorized raise NotAuthorizedError.
+@@ -62,11 +63,13 @@
+     action_id -- the PolicyKit policy name of the action
+     timeout -- time in seconds for the user to authenticate
+     bus -- the D-Bus connection (defaults to the system bus)
++    flags -- optional flags to control the authentication process
+     """
+     subject = ("system-bus-name", {"name": dbus_name})
+-    return _check_authorization(subject, action_id, timeout, bus)
++    return _check_authorization(subject, action_id, timeout, bus, flags)
+ 
+-def check_authorization_by_pid(pid, action_id, timeout=300, bus=None):
++def check_authorization_by_pid(pid, action_id, timeout=300, bus=None,
++                               flags=None):
+     """Check if the given process is authorized for the specified action.
+ 
+     If the sender is not authorized raise NotAuthorizedError.
+@@ -76,11 +79,12 @@
+     action_id -- the PolicyKit policy name of the action
+     timeout -- time in seconds for the user to authenticate
+     bus -- the D-Bus connection (defaults to the system bus)
++    flags -- optional flags to control the authentication process
+     """
+     subject = ("unix-process", {"pid": pid})
+     return _check_authorization(subject, action_id, timeout, bus)
+ 
+-def _check_authorization(subject, action_id, timeout, bus):
++def _check_authorization(subject, action_id, timeout, bus, flags=None):
+     def policykit_done((authorized, challenged, auth_details)):
+         if authorized:
+             deferred.callback(auth_details)
+@@ -88,12 +92,14 @@
+             deferred.errback(NotAuthorizedError(subject, action_id))
+     if not bus:
+         bus = dbus.SystemBus()
++    # Set the default flags
++    if flags is None:
++        flags = CHECK_AUTH_ALLOW_USER_INTERACTION
+     deferred = Deferred()
+     pk = bus.get_object("org.freedesktop.PolicyKit1",
+                         "/org/freedesktop/PolicyKit1/Authority")
+     details = {}
+-    pk.CheckAuthorization(subject, action_id, details,
+-                          CHECK_AUTH_ALLOW_USER_INTERACTION, "",
++    pk.CheckAuthorization(subject, action_id, details, flags, "",
+                           dbus_interface="org.freedesktop.PolicyKit1.Authority",
+                           timeout=timeout,
+                           reply_handler=policykit_done,
+
--- aptdaemon-0.11+bzr345.orig/debian/patches/01_enable_component.patch
+++ aptdaemon-0.11+bzr345/debian/patches/01_enable_component.patch
@@ -0,0 +1,70 @@
+=== modified file 'aptdaemon/client.py'
+--- aptdaemon/client.py	2010-02-21 11:54:16 +0000
++++ aptdaemon/client.py	2010-03-30 07:38:03 +0000
+@@ -585,6 +585,18 @@
+         return self._run_transaction("InstallPackages", [package_names],
+                                      wait, reply_handler, error_handler)
+ 
++    def enable_distro_component(self, component,
++                                reply_handler=None, error_handler=None):
++        """Add component to the sources list.
++
++        Keyword arguments:
++        component -- a components e.g. main or universe
++        """
++        daemon = get_aptdaemon()
++        return daemon.EnableDistroComponent(component, 
++                                            reply_handler=reply_handler,
++                                            error_handler=error_handler)
++
+     def add_repository(self, src_type, uri, dist, comps=[], comment="", 
+                        sourcesfile="", reply_handler=None, error_handler=None):
+         """Add repository to the sources list.
+
+=== modified file 'aptdaemon/core.py'
+--- aptdaemon/core.py	2010-02-10 10:48:21 +0000
++++ aptdaemon/core.py	2010-03-30 07:38:03 +0000
+@@ -52,6 +52,8 @@
+ from softwareproperties.AptAuth import AptAuth
+ from aptsources.sourceslist import SourcesList
+ import apt_pkg
++import aptsources
++import aptsources.distro
+ 
+ import errors
+ from enums import *
+@@ -1167,6 +1169,33 @@
+                                                              sourcesfile))
+         return deferred
+ 
++    def _enable_component(self, component):
++        """Helper for the enable-component function"""
++        old_umask = os.umask(0022)
++        sourceslist = SourcesList()
++        distro = aptsources.distro.get_distro()
++        distro.get_sources(sourceslist)
++        distro.enable_component(component)
++        sourceslist.save()
++        os.umask(old_umask)
++        return True
++
++    @dbus_deferred_method(APTDAEMON_DBUS_INTERFACE,
++                          in_signature="s", out_signature="b",
++                          sender_keyword="sender")
++    def EnableDistroComponent(self, component, sender):
++        """Enable given component in the sources list.
++
++        Keyword arguments:
++        component -- a components, e.g. main or universe
++        sender -- the unique D-Bus name of the sender (provided by D-Bus)
++        """
++        log.info("EnableComponent() was called: component='%s' ", component)
++        action = policykit1.PK_ACTION_CHANGE_REPOSITORY
++        deferred = policykit1.check_authorization_by_name(sender, action)
++        deferred.add_callback(lambda x: self._enable_component(component))
++        return deferred
++
+     @dbus_deferred_method(APTDAEMON_DBUS_INTERFACE,
+                           in_signature="", out_signature="as",
+                           sender_keyword="sender")
+
--- aptdaemon-0.11+bzr345.orig/debian/patches/05_conffile_not_exists.patch
+++ aptdaemon-0.11+bzr345/debian/patches/05_conffile_not_exists.patch
@@ -0,0 +1,19 @@
+=== modified file 'aptdaemon/gtkwidgets.py'
+--- a/aptdaemon/gtkwidgets.py	2009-12-14 10:56:10 +0000
++++ b/aptdaemon/gtkwidgets.py	2010-04-16 20:34:39 +0000
+@@ -695,8 +695,12 @@
+     def show_diff(self, from_path, to_path):
+         """Show the difference between two files."""
+         #FIXME: Use gio
+-        from_lines = open(from_path).readlines()
+-        to_lines = open(to_path).readlines()
++        # Do not fail on not available files (LP:563504)
++        try:
++            from_lines = open(from_path).readlines()
++            to_lines = open(to_path).readlines()
++        except IOError:
++            return
+         iter = self.buffer.get_start_iter()
+         for line in difflib.unified_diff(from_lines, to_lines, lineterm=""):
+             if line.startswith("@@"):
+
--- aptdaemon-0.11+bzr345.orig/debian/patches/series
+++ aptdaemon-0.11+bzr345/debian/patches/series
@@ -0,0 +1,6 @@
+10_backport_mav_defer_py.patch
+01_enable_component.patch
+02_fix_errback.patch
+03_auth_me_less.patch
+04_caution_is_good.patch
+05_conffile_not_exists.patch
--- aptdaemon-0.11+bzr345.orig/debian/patches/04_caution_is_good.patch
+++ aptdaemon-0.11+bzr345/debian/patches/04_caution_is_good.patch
@@ -0,0 +1,74 @@
+## Description: add some description
+## Origin/Author: add some origin or author
+## Bug: bug URL
+diff -Nur -x '*.orig' -x '*~' aptdaemon-0.11+bzr345/aptdaemon/worker.py aptdaemon-0.11+bzr345.new/aptdaemon/worker.py
+--- aptdaemon-0.11+bzr345/aptdaemon/worker.py	2010-03-31 10:57:32.000000000 +0200
++++ aptdaemon-0.11+bzr345.new/aptdaemon/worker.py	2010-04-16 22:08:54.000000000 +0200
+@@ -548,6 +548,17 @@
+         install_range -- tuple containing the start and end point of the
+                          install progress
+         """
++        changes = self._cache.get_changes()
++        if not changes:
++             return
++        # Do not allow to remove essential packages
++        for pkg in changes:
++            if pkg.marked_delete and (pkg.essential == True or \
++                                      pkg.installed.priority == "required" or \
++                                      pkg.name == "aptdaemon"):
++                raise TransactionFailed(ERROR_NOT_REMOVE_ESSENTIAL_PACKAGE,
++                                        "Package %s cannot be removed." % \
++                                        pkg.name)
+         self._check_obsoleted_dependencies()
+         self._check_unauthenticated()
+         if self.trans.cancelled:
+diff -Nur -x '*.orig' -x '*~' aptdaemon-0.11+bzr345/aptdaemon/worker.py.rej aptdaemon-0.11+bzr345.new/aptdaemon/worker.py.rej
+--- aptdaemon-0.11+bzr345/aptdaemon/worker.py.rej	1970-01-01 01:00:00.000000000 +0100
++++ aptdaemon-0.11+bzr345.new/aptdaemon/worker.py.rej	2010-04-16 22:07:58.000000000 +0200
+@@ -0,0 +1,21 @@
++--- aptdaemon/worker.py	2010-03-30 19:48:19 +0000
+++++ aptdaemon/worker.py	2010-04-16 19:46:48 +0000
++@@ -539,8 +539,17 @@
++         install_range -- tuple containing the start and end point of the
++                          install progress
++         """
++-        if not self._cache.get_changes():
+++        changes = self._cache.get_changes()
+++        if not changes:
++             return
+++        # Do not allow to remove essential packages
+++        for pkg in changes:
+++            if pkg.marked_delete and (pkg.essential == True or \
+++                                      pkg.installed.priority == "required" or \
+++                                      pkg.name == "aptdaemon"):
+++                raise TransactionFailed(ERROR_NOT_REMOVE_ESSENTIAL_PACKAGE,
+++                                        "Package %s cannot be removed." % \
+++                                        pkg.name)
++         self._check_obsoleted_dependencies()
++         self._check_unauthenticated()
++         if self.trans.cancelled:
+diff -Nur -x '*.orig' -x '*~' aptdaemon-0.11+bzr345/b/aptdaemon/worker.py.rej aptdaemon-0.11+bzr345.new/b/aptdaemon/worker.py.rej
+--- aptdaemon-0.11+bzr345/b/aptdaemon/worker.py.rej	1970-01-01 01:00:00.000000000 +0100
++++ aptdaemon-0.11+bzr345.new/b/aptdaemon/worker.py.rej	2010-04-16 22:07:53.000000000 +0200
+@@ -0,0 +1,21 @@
++--- a/aptdaemon/worker.py	2010-03-30 19:48:19 +0000
+++++ b/aptdaemon/worker.py	2010-04-16 19:46:48 +0000
++@@ -539,8 +539,17 @@
++         install_range -- tuple containing the start and end point of the
++                          install progress
++         """
++-        if not self._cache.get_changes():
+++        changes = self._cache.get_changes()
+++        if not changes:
++             return
+++        # Do not allow to remove essential packages
+++        for pkg in changes:
+++            if pkg.marked_delete and (pkg.essential == True or \
+++                                      pkg.installed.priority == "required" or \
+++                                      pkg.name == "aptdaemon"):
+++                raise TransactionFailed(ERROR_NOT_REMOVE_ESSENTIAL_PACKAGE,
+++                                        "Package %s cannot be removed." % \
+++                                        pkg.name)
++         self._check_obsoleted_dependencies()
++         self._check_unauthenticated()
++         if self.trans.cancelled:
