summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSebastian Heinlein <sebi@glatzor.de>2008-08-25 00:08:23 +0200
committerSebastian Heinlein <sebi@glatzor.de>2008-08-25 00:08:23 +0200
commitee8376bb4355b58b7816ab5c184dba1af231d76b (patch)
treeb53998fc74303a5d97272638100bf8d0ae13c5a3
parent7e98c1633f22a652b7a69080d822c0af87331d04 (diff)
parent34fa87e70cd6967805ba6faebf146bc4dcd5c14c (diff)
downloadpython-apt-ee8376bb4355b58b7816ab5c184dba1af231d76b.tar.gz
Merge with mvo
-rw-r--r--aptsources/__init__.py4
-rw-r--r--aptsources/distinfo.py1
-rw-r--r--debian/changelog6
-rw-r--r--po/python-apt.pot2
-rw-r--r--python/progress.cc6
5 files changed, 15 insertions, 4 deletions
diff --git a/aptsources/__init__.py b/aptsources/__init__.py
index 8d1c8b69..d6b3605c 100644
--- a/aptsources/__init__.py
+++ b/aptsources/__init__.py
@@ -1 +1,5 @@
+
+import apt_pkg
+# init the package system
+apt_pkg.init()
diff --git a/aptsources/distinfo.py b/aptsources/distinfo.py
index b962def6..a6c0faf8 100644
--- a/aptsources/distinfo.py
+++ b/aptsources/distinfo.py
@@ -128,7 +128,6 @@ class DistInfo:
base_dir = "/usr/share/python-apt/templates"):
self.metarelease_uri = ''
self.templates = []
- apt_pkg.init()
self.arch = apt_pkg.Config.Find("APT::Architecture")
location = None
diff --git a/debian/changelog b/debian/changelog
index 8cac6ae2..a2ae598a 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -9,6 +9,12 @@ python-apt (0.7.7.2) UNRELEASED; urgency=low
- do not change working dir in debExtractArchive() (LP: #184093)
* apt/cache.py:
- support "in" in apt.Cache() (LP: #251587)
+ * python/progress.cc:
+ - when pulse() does not return a boolean assume "true"
+ (thanks to Martin Pitt for telling me about the problem)
+ * aptsources/__init__.py, aptsources/distinfo.py:
+ - run apt_pkg.init() when aptsources gets imported and not
+ the distinfo function
-- Michael Vogt <michael.vogt@ubuntu.com> Wed, 30 Jul 2008 10:24:30 +0200
diff --git a/po/python-apt.pot b/po/python-apt.pot
index 7e731689..3d513b7b 100644
--- a/po/python-apt.pot
+++ b/po/python-apt.pot
@@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2008-07-31 12:00+0200\n"
+"POT-Creation-Date: 2008-08-15 09:59+0200\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
diff --git a/python/progress.cc b/python/progress.cc
index 793265db..99ad0a25 100644
--- a/python/progress.cc
+++ b/python/progress.cc
@@ -185,8 +185,10 @@ bool PyFetchProgress::Pulse(pkgAcquire * Owner)
bool res = true;
if(!PyArg_Parse(result, "b", &res))
{
- // mvo: this is harmless, we shouldn't print anything here
- //std::cerr << "result could not be parsed" << std::endl;
+ // most of the time the user who subclasses the pulse()
+ // method forgot to add a return {True,False} so we just
+ // assume he wants a True
+ return true;
}
// fetching can be canceld by returning false