From 389fe246d85aa59348b770db793e9455fd17d73c Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Tue, 21 Feb 2006 18:23:49 +0000 Subject: * merged changes from doko, prepared new upload --- debian/changelog | 19 +++++++++++++++---- debian/control | 17 +---------------- debian/rules | 1 + 3 files changed, 17 insertions(+), 20 deletions(-) (limited to 'debian') diff --git a/debian/changelog b/debian/changelog index 80634e36..ddce68cb 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,12 +1,23 @@ -python-apt (0.6.16.1) unstable; urgency=low +python-apt (0.6.16ubuntu3) dapper; urgency=low - * memleak fixed when pkgCache objects are deallocated * typos fixed (thanks to Gustavo Franco) * pkgRecords.Record added to get raw record data * python/cache.cc: "key" in pkgCache::VerIterator.DependsList[key] is - no longer locale specific but always english + no longer locale specific but always englis + + -- Michael Vogt Tue, 21 Feb 2006 19:23:09 +0100 + +python-apt (0.6.16ubuntu2) dapper; urgency=low + + * Drop python2.3 package. + + -- Matthias Klose Tue, 14 Feb 2006 15:27:26 +0000 + +python-apt (0.6.16ubuntu1) dapper; urgency=low + + * memleak fixed when pkgCache objects are deallocated - -- Michael Vogt Thu, 26 Jan 2006 16:30:02 +0100 + -- Michael Vogt Thu, 12 Jan 2006 00:08:05 +0100 python-apt (0.6.16) unstable; urgency=low diff --git a/debian/control b/debian/control index bfa67c67..350d08e0 100644 --- a/debian/control +++ b/debian/control @@ -4,7 +4,7 @@ Priority: optional Maintainer: APT Development Team Uploaders: Matt Zimmerman , Michael Vogt Standards-Version: 3.6.1.1 -Build-Depends: debhelper (>= 4.2.28), libapt-pkg-dev (>= 0.6.40), apt-utils, python-dev, python2.4-dev, python2.3-dev +Build-Depends: debhelper (>= 4.2.28), libapt-pkg-dev (>= 0.6.40), apt-utils, python-dev, python2.4-dev Package: python-apt Architecture: all @@ -20,21 +20,6 @@ Description: Python interface to libapt-pkg - Parsing of Debian package control files, and other files with a similar structure -Package: python2.3-apt -Architecture: any -Depends: python2.3, ${shlibs:Depends} -Conflicts: python-apt (<< 0.6.11) -Priority: optional -Description: Python interface to libapt-pkg - The apt-pkg Python interface will provide full access to the internal - libapt-pkg structures allowing Python programs to easily perform a - variety of functions, such as: - . - - Access to the APT configuration system - - Access to the APT package information database - - Parsing of Debian package control files, and other files with a - similar structure - Package: python2.4-apt Architecture: any Depends: python2.4, ${shlibs:Depends} diff --git a/debian/rules b/debian/rules index 0ab6fa27..9439a2c9 100755 --- a/debian/rules +++ b/debian/rules @@ -16,6 +16,7 @@ DEB_BUILD_PROG:=debuild --preserve-envvar PATH --preserve-envvar CCACHE_DIR -us #export DH_VERBOSE=1 PYTHON=python2.3 python2.4 +PYTHON=python2.4 build: build-stamp build-stamp: -- cgit v1.2.3 From 251a9c10f4c848df5d1daaef63a16e4ce6d5dc0b Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Mon, 6 Mar 2006 18:58:21 +0000 Subject: * added purge option --- apt/package.py | 9 ++++++--- debian/changelog | 4 +++- 2 files changed, 9 insertions(+), 4 deletions(-) (limited to 'debian') diff --git a/apt/package.py b/apt/package.py index 4fceb904..66bfd72b 100644 --- a/apt/package.py +++ b/apt/package.py @@ -274,10 +274,13 @@ class Package(object): self._pcache.cachePreChange() self._depcache.MarkKeep(self._pkg) self._pcache.cachePostChange() - def markDelete(self, autoFix=True): - """ mark a package for delete. Run the resolver if autoFix is set """ + def markDelete(self, autoFix=True, purge=False): + """ mark a package for delete. Run the resolver if autoFix is set. + Mark the package as purge (remove with configuration) if 'purge' + is set. + """ self._pcache.cachePreChange() - self._depcache.MarkDelete(self._pkg) + self._depcache.MarkDelete(self._pkg, purge) # try to fix broken stuffsta if autoFix and self._depcache.BrokenCount > 0: Fix = apt_pkg.GetPkgProblemResolver(self._depcache) diff --git a/debian/changelog b/debian/changelog index 23f586d9..f9a26c49 100644 --- a/debian/changelog +++ b/debian/changelog @@ -9,7 +9,9 @@ python-apt (0.6.16.2) unstable; urgency=low - fix various pychecker warnings * apt/cache.py: - return useful values on Cache.update() - * apt/cache.py, apt/package.py: fix various pychecker warnings + * apt/package.py: + - fix various pychecker warnings + - added setDelete(purge) option -- -- cgit v1.2.3 From f4fd803ae9d2a0bbdb03f5b9fc21e432ebbdb0b3 Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Mon, 8 May 2006 16:38:33 +0200 Subject: * merged r192 from mainline --- debian/changelog | 8 ++++++++ debian/compat | 1 + debian/control | 6 +++--- debian/rules | 5 +---- setup.py | 18 +++++++----------- 5 files changed, 20 insertions(+), 18 deletions(-) create mode 100644 debian/compat (limited to 'debian') diff --git a/debian/changelog b/debian/changelog index 567ef8e9..b02c3917 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,11 @@ +python-apt (0.6.16.2ubuntu6) unstable; urgency=low + + * debian/control: + + Replaces: python-apt (<< 0.6.11), instead of Conflicts which is not + correct here. (closes: #308586). + + -- + python-apt (0.6.16.2ubuntu5) dapper; urgency=low * apt/cache.py: Release locks on failure (thanks to Colin Watson) diff --git a/debian/compat b/debian/compat new file mode 100644 index 00000000..7813681f --- /dev/null +++ b/debian/compat @@ -0,0 +1 @@ +5 \ No newline at end of file diff --git a/debian/control b/debian/control index 350d08e0..e8d0038c 100644 --- a/debian/control +++ b/debian/control @@ -3,8 +3,8 @@ Section: python Priority: optional Maintainer: APT Development Team Uploaders: Matt Zimmerman , Michael Vogt -Standards-Version: 3.6.1.1 -Build-Depends: debhelper (>= 4.2.28), libapt-pkg-dev (>= 0.6.40), apt-utils, python-dev, python2.4-dev +Standards-Version: 3.6.2.0 +Build-Depends: debhelper (>= 5.0), libapt-pkg-dev (>= 0.6.40), apt-utils, python-dev, python2.4-dev Package: python-apt Architecture: all @@ -23,7 +23,7 @@ Description: Python interface to libapt-pkg Package: python2.4-apt Architecture: any Depends: python2.4, ${shlibs:Depends} -Conflicts: python-apt (<< 0.6.11) +Replaces: python-apt (<< 0.6.11) Priority: optional Description: Python interface to libapt-pkg The apt-pkg Python interface will provide full access to the internal diff --git a/debian/rules b/debian/rules index 9439a2c9..c71baf08 100755 --- a/debian/rules +++ b/debian/rules @@ -6,9 +6,6 @@ # This has to be exported to make some magic below work. export DH_OPTIONS -# This is the debhelper compatibility version to use. -export DH_COMPAT=3 - DEBVER=$(shell dpkg-parsechangelog |sed -n -e '/^Version:/s/^Version: //p') DEB_BUILD_PROG:=debuild --preserve-envvar PATH --preserve-envvar CCACHE_DIR -us -uc $(DEB_BUILD_PROG_OPTS) @@ -84,7 +81,7 @@ source diff: arch-build: rm -rf debian/arch-build mkdir -p debian/arch-build/python-apt-$(DEBVER) - baz inventory -s | xargs cp -a --parents --target=debian/arch-build/python-apt-$(DEBVER) + tar -c --exclude=arch-build --no-recursion -f - `bzr inventory` | (cd debian/arch-build/python-apt-$(DEBVER);tar xf -) (cd debian/arch-build/python-apt-$(DEBVER); $(DEB_BUILD_PROG)) binary: binary-indep binary-arch diff --git a/setup.py b/setup.py index f9255607..5adb0376 100644 --- a/setup.py +++ b/setup.py @@ -7,22 +7,18 @@ import string, glob # The apt_pkg module -files = string.split(parse_makefile("python/makefile")["APT_PKG_SRC"]); -for i in range(0,len(files)): - files[i] = "python/"+ files[i]; -apt_pkg = Extension("apt_pkg", files, - libraries=["apt-pkg"]); +files = map(lambda source: "python/"+source, + string.split(parse_makefile("python/makefile")["APT_PKG_SRC"])) +apt_pkg = Extension("apt_pkg", files, libraries=["apt-pkg"]); # The apt_inst module -files = string.split(parse_makefile("python/makefile")["APT_INST_SRC"]); -for i in range(0,len(files)): - files[i] = "python/"+ files[i]; -apt_inst = Extension("apt_inst", files, - libraries=["apt-pkg","apt-inst"]); +files = map(lambda source: "python/"+source, + string.split(parse_makefile("python/makefile")["APT_INST_SRC"])) +apt_inst = Extension("apt_inst", files, libraries=["apt-pkg","apt-inst"]); setup(name="python-apt", - version="0.6.13", + version="0.6.17", description="Python bindings for APT", author="APT Development Team", author_email="deity@lists.debian.org", -- cgit v1.2.3 From b47ce124b9672ea58f87dd2380c409566ffcfefd Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Wed, 17 May 2006 18:14:35 +0200 Subject: * prepared new upload with cherry picked patch from mainline --- apt/package.py | 11 +++++++---- debian/changelog | 9 +++++++++ 2 files changed, 16 insertions(+), 4 deletions(-) (limited to 'debian') diff --git a/apt/package.py b/apt/package.py index 66bfd72b..9f329069 100644 --- a/apt/package.py +++ b/apt/package.py @@ -49,7 +49,7 @@ class Package(object): # check if we found a version if ver == None: - #print "No version for: %s (Candidate: %s)" % (self._pkg.Name, UseCandidate) + print "No version for: %s (Candidate: %s)" % (self._pkg.Name, UseCandidate) return False if ver.FileList == None: @@ -149,13 +149,15 @@ class Package(object): def summary(self): """ Return the short description (one line summary) """ - self._lookupRecord() + if not self._lookupRecord(): + return "" return self._records.ShortDesc summary = property(summary) def description(self, format=True): """ Return the formated long description """ - self._lookupRecord() + if not self._lookupRecord(): + return "" desc = "" for line in string.split(self._records.LongDesc, "\n"): tmp = string.strip(line) @@ -168,7 +170,8 @@ class Package(object): def rawDescription(self): """ return the long description (raw)""" - self._lookupRecord() + if not self._lookupRecord(): + return "" return self._records.LongDesc rawDescription = property(rawDescription) diff --git a/debian/changelog b/debian/changelog index 6859407c..9822dc42 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,12 @@ +python-apt (0.6.16.2ubuntu7) dapper; urgency=low + + * apt/package.py: + - check if _lookupRecord() succeeded when checking + maintainer or description (fixes invalid descriptions under + rare circumstances in gnome-app-install) + + -- Michael Vogt Wed, 17 May 2006 18:12:58 +0200 + python-apt (0.6.16.2ubuntu6) dapper; urgency=low * debian/control: -- cgit v1.2.3 From a7af5ff42bdc6cd8d8652f7304926a7b58686c70 Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Wed, 17 May 2006 19:29:39 +0200 Subject: * cherry picked from main --- apt/package.py | 4 ++-- debian/changelog | 7 +++++++ 2 files changed, 9 insertions(+), 2 deletions(-) (limited to 'debian') diff --git a/apt/package.py b/apt/package.py index d0119b6f..dfb74789 100644 --- a/apt/package.py +++ b/apt/package.py @@ -105,12 +105,12 @@ class Package(object): return ver.Downloadable def candidateDownloadable(self): " returns if the canidate is downloadable " - self._downloadable(useCandidate=True) + return self._downloadable(useCandidate=True) candidateDownloadable = property(candidateDownloadable) def installedDownloadable(self): " returns if the installed version is downloadable " - self._downloadable(useCandidate=False) + return self._downloadable(useCandidate=False) installedDownloadable = property(installedDownloadable) def sourcePackageName(self): diff --git a/debian/changelog b/debian/changelog index 9822dc42..bc6f5177 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,10 @@ +python-apt (0.6.16.2ubuntu8) dapper; urgency=low + + * apt/package.py: + - fix return value in {candidate,installed}Downloadable + + -- Michael Vogt Wed, 17 May 2006 19:28:44 +0200 + python-apt (0.6.16.2ubuntu7) dapper; urgency=low * apt/package.py: -- cgit v1.2.3 From 0b081c5451d6394618290cd9a5767d767d98b819 Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Mon, 3 Jul 2006 21:42:55 +0200 Subject: * prepared rebuild --- debian/changelog | 7 +++++++ debian/control | 2 +- 2 files changed, 8 insertions(+), 1 deletion(-) (limited to 'debian') diff --git a/debian/changelog b/debian/changelog index bc6f5177..ad6bc8d8 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,10 @@ +python-apt (0.6.16.2ubuntu9) edgy; urgency=low + + * rebuild against the latest apt (with auto-mark support) + * the full merge needs a newer python-support + + -- Michael Vogt Mon, 3 Jul 2006 21:33:40 +0200 + python-apt (0.6.16.2ubuntu8) dapper; urgency=low * apt/package.py: diff --git a/debian/control b/debian/control index e8d0038c..4f5f3019 100644 --- a/debian/control +++ b/debian/control @@ -4,7 +4,7 @@ Priority: optional Maintainer: APT Development Team Uploaders: Matt Zimmerman , Michael Vogt Standards-Version: 3.6.2.0 -Build-Depends: debhelper (>= 5.0), libapt-pkg-dev (>= 0.6.40), apt-utils, python-dev, python2.4-dev +Build-Depends: debhelper (>= 5.0), libapt-pkg-dev (>= 0.6.44.2), apt-utils, python-dev, python2.4-dev Package: python-apt Architecture: all -- cgit v1.2.3 From 1ec002106f5db5e855ab8053a549a53b1e8dc8e3 Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Mon, 14 Aug 2006 16:24:58 +0200 Subject: * updated build-deps --- debian/changelog | 6 ++++++ debian/control | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) (limited to 'debian') diff --git a/debian/changelog b/debian/changelog index d720a91b..73adccba 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +python-apt (0.6.19ubuntu2) edgy; urgency=low + + * tightened build-deps on latest apt + + -- Michael Vogt Thu, 3 Aug 2006 17:02:30 +0200 + python-apt (0.6.19ubuntu1) edgy; urgency=low [ Michael Vogt ] diff --git a/debian/control b/debian/control index c057feed..e2f97b78 100644 --- a/debian/control +++ b/debian/control @@ -5,7 +5,7 @@ Maintainer: APT Development Team Uploaders: Matt Zimmerman , Michael Vogt Standards-Version: 3.6.2.0 XS-Python-Version: all -Build-Depends: debhelper (>= 5.0.37.1), libapt-pkg-dev (>= 0.6.44.2), apt-utils, python-all-dev, python-central +Build-Depends: debhelper (>= 5.0.37.1), libapt-pkg-dev (>= 0.6.45), apt-utils, python-all-dev, python-central Package: python-apt Architecture: any -- cgit v1.2.3 From 1427f53977faddace94c435f3a6b3c09d9a52660 Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Mon, 18 Sep 2006 21:17:02 +0200 Subject: * merged dokos changelog-only change *cough* *cough* --- debian/changelog | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'debian') diff --git a/debian/changelog b/debian/changelog index 8487ba9b..02007000 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,4 +1,4 @@ -python-apt (0.6.19ubuntu4) edgy; urgency=low +python-apt (0.6.19ubuntu5) edgy; urgency=low * python/pkgmanager.cc: - fix typo (closes: #382853) @@ -15,6 +15,12 @@ python-apt (0.6.19ubuntu4) edgy; urgency=low -- Michael Vogt Mon, 18 Sep 2006 18:28:19 +0200 +python-apt (0.6.19ubuntu4) edgy; urgency=low + + * Rebuild to add support for python2.5. + + -- Matthias Klose Fri, 8 Sep 2006 13:32:47 +0000 + python-apt (0.6.19ubuntu3) edgy; urgency=low * merged ddtp support -- cgit v1.2.3 From 0d6bdd9d329f6527f6a5f2337828e03c2e2af508 Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Fri, 6 Oct 2006 17:22:40 +0200 Subject: * python/depcache.cc: - suport for pkgActionGrup added --- debian/changelog | 2 +- python/depcache.cc | 70 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 71 insertions(+), 1 deletion(-) (limited to 'debian') diff --git a/debian/changelog b/debian/changelog index d9b428bd..b1099dea 100644 --- a/debian/changelog +++ b/debian/changelog @@ -10,7 +10,7 @@ python-apt (0.6.19) unstable; urgency=low - fix commit doc string to also cite the open related callbacks - allow change of rootdir for APT database loading - -- + -- Michael Vogt Tue, 27 Jun 2006 16:51:56 +0200 python-apt (0.6.18) unstable; urgency=low diff --git a/python/depcache.cc b/python/depcache.cc index 60bbc1a4..159a7103 100644 --- a/python/depcache.cc +++ b/python/depcache.cc @@ -745,3 +745,73 @@ PyTypeObject PkgProblemResolverType = }; /*}}}*/ + +// pkgActionGroup Class /*{{{*/ +// --------------------------------------------------------------------- + + +static PyObject *PkgActionGroupRelease(PyObject *Self,PyObject *Args) +{ + pkgDepCache::ActionGroup *ag = GetCpp(Self); + if (PyArg_ParseTuple(Args,"") == 0) + return 0; + ag->release(); + Py_INCREF(Py_None); + return HandleErrors(Py_None); +} + +static PyMethodDef PkgActionGroupMethods[] = +{ + {"release", PkgActionGroupRelease, METH_VARARGS, "release()"}, + {} +}; + + +static PyObject *ActionGroupAttr(PyObject *Self,char *Name) +{ + pkgDepCache::ActionGroup *ag = GetCpp(Self); + + return Py_FindMethod(PkgActionGroupMethods,Self,Name); +} + + +PyTypeObject PkgActionGroupType = +{ + PyObject_HEAD_INIT(&PyType_Type) + 0, // ob_size + "pkgActionGroup", // tp_name + sizeof(CppOwnedPyObject), // tp_basicsize + 0, // tp_itemsize + // Methods + CppOwnedDealloc, // tp_dealloc + 0, // tp_print + ActionGroupAttr, // tp_getattr + 0, // tp_setattr + 0, // tp_compare + 0, // tp_repr + 0, // tp_as_number + 0, // tp_as_sequence + 0, // tp_as_mapping + 0, // tp_hash +}; + +PyObject *GetPkgActionGroup(PyObject *Self,PyObject *Args) +{ + PyObject *Owner; + if (PyArg_ParseTuple(Args,"O!",&PkgDepCacheType,&Owner) == 0) + return 0; + + pkgDepCache *depcache = GetCpp(Owner); + pkgDepCache::ActionGroup *group = new pkgDepCache::ActionGroup(*depcache); + CppOwnedPyObject *PkgActionGroupPyObj; + PkgActionGroupPyObj = CppOwnedPyObject_NEW(Owner, + &PkgActionGroupType, + group); + HandleErrors(PkgActionGroupPyObj); + + return PkgActionGroupPyObj; + +} + + + /*}}}*/ -- cgit v1.2.3 From 47a1e41c1786a637c2bef222d0f304c6c19a2b8d Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Fri, 3 Nov 2006 22:04:04 +0100 Subject: * apt/progress.py: - protect against unparsable strings from dpkg --- apt/progress.py | 7 ++++++- debian/changelog | 6 ++++++ 2 files changed, 12 insertions(+), 1 deletion(-) (limited to 'debian') diff --git a/apt/progress.py b/apt/progress.py index 8ac0e1dc..5169adf7 100644 --- a/apt/progress.py +++ b/apt/progress.py @@ -175,7 +175,12 @@ class InstallProgress(DumbInstallProgress): if self.read.endswith("\n"): s = self.read #print s - (status, pkg, percent, status_str) = string.split(s, ":") + try: + (status, pkg, percent, status_str) = string.split(s, ":",3) + except ValueError, e: + # silently ignore lines that can't be parsed + self.read = "" + return #print "percent: %s %s" % (pkg, float(percent)/100.0) if status == "pmerror": self.error(pkg,status_str) diff --git a/debian/changelog b/debian/changelog index 08e83ae5..c864bf48 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +python-apt (0.6.19ubuntu9.1) edgy-updates; urgency=low + + * protect against not-parsable strings send from dpkg (lp: 68553) + + -- Michael Vogt Fri, 27 Oct 2006 10:41:44 +0200 + python-apt (0.6.19ubuntu9) edgy; urgency=low * Reupload to restore dependency on python-central. -- cgit v1.2.3 From 68673966c0fb8b9563b1521f08f1baeaa6d17b6e Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Fri, 2 Feb 2007 16:21:29 +0100 Subject: * debian/rules: re-added arch-build --- debian/rules | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'debian') diff --git a/debian/rules b/debian/rules index 6367c02f..32845c7a 100755 --- a/debian/rules +++ b/debian/rules @@ -6,3 +6,14 @@ DEB_PYTHON_SYSTEM=pycentral # Add here any variable or target overrides you need include /usr/share/cdbs/1/rules/debhelper.mk include /usr/share/cdbs/1/class/python-distutils.mk + +PKG=gdebi +DEBVER=$(shell dpkg-parsechangelog |sed -n -e '/^Version:/s/^Version: //p') +DEB_BUILD_PROG:=debuild --preserve-envvar PATH --preserve-envvar CCACHE_DIR -us -uc $(DEB_BUILD_PROG_OPTS) + +arch-build:: + rm -rf debian/arch-build + mkdir -p debian/arch-build/$(PKG)-$(DEBVER) + tar -c --exclude=arch-build --no-recursion -f - `bzr inventory` | (cd debian/arch-build/$(PKG)-$(DEBVER);tar xf -) + (cd debian/arch-build/$(PKG)-$(DEBVER) && $(DEB_BUILD_PROG)) + -- cgit v1.2.3 From 9650108bea5e4f4195eabe7814638446082f81cd Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Fri, 2 Feb 2007 16:28:45 +0100 Subject: * added pycompat * finalized changelog * added versionized b-d to python-central --- debian/changelog | 4 +++- debian/control | 2 +- debian/pycompat | 1 + 3 files changed, 5 insertions(+), 2 deletions(-) create mode 100644 debian/pycompat (limited to 'debian') diff --git a/debian/changelog b/debian/changelog index ffceba45..545034c6 100644 --- a/debian/changelog +++ b/debian/changelog @@ -3,8 +3,10 @@ python-apt (0.6.20ubuntu2) feisty; urgency=low * python/depcache.cc: - MarkInstall() has new FromUser argument to support marking packages as automatically installed + * merged the 'aptsources' module for sources.list handling + (thanks to Sebastian Heinlein) - -- Michael Vogt Fri, 26 Jan 2007 16:39:10 +0100 + -- Michael Vogt Fri, 2 Feb 2007 16:26:38 +0100 python-apt (0.6.20ubuntu1) feisty; urgency=low diff --git a/debian/control b/debian/control index 4ea3a31c..9e304c29 100644 --- a/debian/control +++ b/debian/control @@ -5,7 +5,7 @@ Maintainer: APT Development Team Uploaders: Matt Zimmerman , Michael Vogt Standards-Version: 3.7.2 XS-Python-Version: all -Build-Depends: debhelper (>= 5.0.37.1), libapt-pkg-dev (>= 0.6.45), apt-utils, python-all-dev, python-central, python-distutils-extra, cdbs +Build-Depends: debhelper (>= 5.0.37.1), libapt-pkg-dev (>= 0.6.45), apt-utils, python-all-dev, python-distutils-extra, cdbs, python-central (>= 0.5) Package: python-apt Architecture: any diff --git a/debian/pycompat b/debian/pycompat new file mode 100644 index 00000000..0cfbf088 --- /dev/null +++ b/debian/pycompat @@ -0,0 +1 @@ +2 -- cgit v1.2.3 From 4d7d86374effe9bfd3a360aaaa7b09758f5c948e Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Tue, 13 Feb 2007 18:36:57 +0100 Subject: * fixed crash in Mirror.has_repository * fixed docstring --- aptsources/distinfo.py | 8 ++++++-- aptsources/distro.py | 2 +- debian/changelog | 12 ++++++++++++ debian/control | 2 +- 4 files changed, 20 insertions(+), 4 deletions(-) (limited to 'debian') diff --git a/aptsources/distinfo.py b/aptsources/distinfo.py index f3c68cae..261243b4 100644 --- a/aptsources/distinfo.py +++ b/aptsources/distinfo.py @@ -91,8 +91,12 @@ class Mirror: def get_repositories_for_proto(self, proto): return filter(lambda r: r.proto == proto, self.repositories) def has_repository(self, proto, dir): - return len(filter(lambda r: (r.proto == proto) and dir in r.dir, - self.repositories)) > 0 + if dir is None: + return False + for r in self.repositories: + if r.proto == proto and dir in r.dir: + return True + return False def get_repo_urls(self): return map(lambda r: r.get_url(self.hostname), self.repositories) def get_location(self): diff --git a/aptsources/distro.py b/aptsources/distro.py index f53783dc..9643524b 100644 --- a/aptsources/distro.py +++ b/aptsources/distro.py @@ -174,7 +174,6 @@ class Distribution: Enable a component in all main, child and source code sources (excluding cdrom based sources) - sourceslist: an aptsource.sources_list comp: the component that should be enabled """ def add_component_only_once(source, comps_per_dist): @@ -427,3 +426,4 @@ def get_distro(): release) else: return Distribution(id, codename, description, relase) + diff --git a/debian/changelog b/debian/changelog index 9380ddbb..e5a5b660 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,15 @@ +python-apt (0.6.20ubuntu5) feisty; urgency=low + + * be more robust in has_repository (LP#84897) + + -- Michael Vogt Tue, 13 Feb 2007 17:49:55 +0100 + +python-apt (0.6.20ubuntu4) feisty; urgency=low + + * rebuild against latest libapt + + -- Michael Vogt Tue, 6 Feb 2007 16:40:37 +0100 + python-apt (0.6.20ubuntu3) feisty; urgency=low * fixes in the new 'aptsources' module diff --git a/debian/control b/debian/control index 9e304c29..bf1ca1de 100644 --- a/debian/control +++ b/debian/control @@ -5,7 +5,7 @@ Maintainer: APT Development Team Uploaders: Matt Zimmerman , Michael Vogt Standards-Version: 3.7.2 XS-Python-Version: all -Build-Depends: debhelper (>= 5.0.37.1), libapt-pkg-dev (>= 0.6.45), apt-utils, python-all-dev, python-distutils-extra, cdbs, python-central (>= 0.5) +Build-Depends: debhelper (>= 5.0.37.1), libapt-pkg-dev (>= 0.6.46.4ubuntu7), apt-utils, python-all-dev, python-distutils-extra, cdbs, python-central (>= 0.5) Package: python-apt Architecture: any -- cgit v1.2.3 From d8f0eef84bc05f6e87ebf50bd8780accec03eacb Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Mon, 19 Feb 2007 12:17:58 +0100 Subject: * aptsources/distro.py: - fixed crash in add_source() --- aptsources/distro.py | 2 +- debian/changelog | 7 +++++++ 2 files changed, 8 insertions(+), 1 deletion(-) (limited to 'debian') diff --git a/aptsources/distro.py b/aptsources/distro.py index 9643524b..7acd1942 100644 --- a/aptsources/distro.py +++ b/aptsources/distro.py @@ -164,7 +164,7 @@ class Distribution: new_source = self.sourceslist.add(type, uri, dist, comps, comment) # if source code is enabled add a deb-src line after the new # source - if self.get_source_code == True and tpye == self.binary_type: + if self.get_source_code == True and type == self.binary_type: self.sourceslist.add(self.source_type, uri, dist, comps, comment, file=new_source.file, pos=self.sourceslist.list.index(new_source)+1) diff --git a/debian/changelog b/debian/changelog index e5a5b660..cb818eea 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,10 @@ +python-apt (0.6.20ubuntu6) feisty; urgency=low + + * aptsources/distro.py: + - fix crash in add_source (LP#85806) + + -- + python-apt (0.6.20ubuntu5) feisty; urgency=low * be more robust in has_repository (LP#84897) -- cgit v1.2.3 From 1c878fca17aaa7d8300224e1aed0f13066fe3e84 Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Thu, 22 Feb 2007 17:11:51 +0100 Subject: * apt/package.py: - handle invalid unicode more gracefully (LP#86215) * rebuild against latest apt --- apt/package.py | 7 ++++++- debian/changelog | 5 ++++- debian/control | 2 +- python/string.cc | 6 ++++-- 4 files changed, 15 insertions(+), 5 deletions(-) (limited to 'debian') diff --git a/apt/package.py b/apt/package.py index af5dd327..39e2993c 100644 --- a/apt/package.py +++ b/apt/package.py @@ -166,7 +166,12 @@ class Package(object): desc_iter = ver.TranslatedDescription self._records.Lookup(desc_iter.FileList.pop(0)) desc = "" - for line in string.split(unicode(self._records.LongDesc,"utf-8"),"\n"): + try: + s = unicode(self._records.LongDesc,"utf-8") + except UnicodeDecodeError,e: + s = _("Invalid unicode in description for '%s' (%s). " + "Please report.") % (name,e) + for line in string.split(s,"\n"): tmp = string.strip(line) if tmp == ".": desc += "\n" diff --git a/debian/changelog b/debian/changelog index cb818eea..9e0fe1be 100644 --- a/debian/changelog +++ b/debian/changelog @@ -2,8 +2,11 @@ python-apt (0.6.20ubuntu6) feisty; urgency=low * aptsources/distro.py: - fix crash in add_source (LP#85806) + * apt/package.py: + - handle invalid unicode more gracefully (LP#86215) + * rebuild against latest apt - -- + -- Michael Vogt Mon, 19 Feb 2007 16:34:52 +0100 python-apt (0.6.20ubuntu5) feisty; urgency=low diff --git a/debian/control b/debian/control index bf1ca1de..b243adb1 100644 --- a/debian/control +++ b/debian/control @@ -5,7 +5,7 @@ Maintainer: APT Development Team Uploaders: Matt Zimmerman , Michael Vogt Standards-Version: 3.7.2 XS-Python-Version: all -Build-Depends: debhelper (>= 5.0.37.1), libapt-pkg-dev (>= 0.6.46.4ubuntu7), apt-utils, python-all-dev, python-distutils-extra, cdbs, python-central (>= 0.5) +Build-Depends: debhelper (>= 5.0.37.1), libapt-pkg-dev (>= 0.6.46.4ubuntu8), apt-utils, python-all-dev, python-distutils-extra, cdbs, python-central (>= 0.5) Package: python-apt Architecture: any diff --git a/python/string.cc b/python/string.cc index 16adc8cd..d0926da5 100644 --- a/python/string.cc +++ b/python/string.cc @@ -53,9 +53,11 @@ PyObject *StrSizeToStr(PyObject *Self,PyObject *Args) if (PyArg_ParseTuple(Args,"O",&Obj) == 0) return 0; if (PyInt_Check(Obj)) - return CppPyString(SizeToStr(PyInt_AS_LONG(Obj))); + return CppPyString(SizeToStr(PyInt_AsLong(Obj))); + if (PyLong_Check(Obj)) + return CppPyString(SizeToStr(PyLong_AsLong(Obj))); if (PyFloat_Check(Obj)) - return CppPyString(SizeToStr(PyFloat_AS_DOUBLE(Obj))); + return CppPyString(SizeToStr(PyFloat_AsDouble(Obj))); PyErr_SetString(PyExc_TypeError,"Only understand integers and floats"); return 0; -- cgit v1.2.3 From 8e60722c4150cf0164a80406ec1ff06d0c7bc11e Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Mon, 26 Feb 2007 14:43:04 +0100 Subject: * merged dokos patch --- debian/changelog | 11 +++++++++-- debian/compat | 2 +- debian/control | 12 ++++++++++++ debian/rules | 25 ++++++++++++++++++++++++- po/python-apt.pot | 2 +- 5 files changed, 47 insertions(+), 5 deletions(-) (limited to 'debian') diff --git a/debian/changelog b/debian/changelog index 9e0fe1be..387424d8 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,4 +1,4 @@ -python-apt (0.6.20ubuntu6) feisty; urgency=low +python-apt (0.6.20ubuntu7) feisty; urgency=low * aptsources/distro.py: - fix crash in add_source (LP#85806) @@ -6,7 +6,14 @@ python-apt (0.6.20ubuntu6) feisty; urgency=low - handle invalid unicode more gracefully (LP#86215) * rebuild against latest apt - -- Michael Vogt Mon, 19 Feb 2007 16:34:52 +0100 + -- Michael Vogt Mon, 26 Feb 2007 14:31:00 +0100 + +python-apt (0.6.20ubuntu6) feisty; urgency=low + + * Build the extension for the debug interpreter. + * Set Ubuntu maintainer address. + + -- Matthias Klose Sat, 17 Feb 2007 02:10:37 +0100 python-apt (0.6.20ubuntu5) feisty; urgency=low diff --git a/debian/compat b/debian/compat index 7813681f..7ed6ff82 100644 --- a/debian/compat +++ b/debian/compat @@ -1 +1 @@ -5 \ No newline at end of file +5 diff --git a/debian/control b/debian/control index b243adb1..0c50e35f 100644 --- a/debian/control +++ b/debian/control @@ -14,6 +14,7 @@ Priority: optional Replaces: python2.3-apt (<< 0.6.18), python2.4-apt (<< 0.6.18) Conflicts: python2.3-apt (<< 0.6.18), python2.4-apt (<< 0.6.18) Provides: ${python:Provides} +Suggests: python-apt-dbg XB-Python-Version: ${python:Versions} Description: Python interface to libapt-pkg The apt_pkg Python interface will provide full access to the internal @@ -27,3 +28,14 @@ Description: Python interface to libapt-pkg . The included 'aptsources' Python interface provides an abstraction of the sources.list configuration on the repository and the distro level. + +Package: python-apt-dbg +Priority: extra +Architecture: any +Depends: python-dbg, python-apt (= ${Source-Version}), ${shlibs:Depends} +Description: Python interface to libapt-pkg (debug extension) + The apt_pkg Python interface will provide full access to the internal + libapt-pkg structures allowing Python programs to easily perform a + variety of functions. + . + This package contains the extension built for the python debug interpreter. diff --git a/debian/rules b/debian/rules index 32845c7a..7e837e8b 100755 --- a/debian/rules +++ b/debian/rules @@ -3,6 +3,8 @@ DEB_AUTO_CLEANUP_RCS := yes DEB_PYTHON_SYSTEM=pycentral +DEB_PYTHON_PACKAGES_EXCLUDE=python-apt-dbg + # Add here any variable or target overrides you need include /usr/share/cdbs/1/rules/debhelper.mk include /usr/share/cdbs/1/class/python-distutils.mk @@ -14,6 +16,27 @@ DEB_BUILD_PROG:=debuild --preserve-envvar PATH --preserve-envvar CCACHE_DIR -us arch-build:: rm -rf debian/arch-build mkdir -p debian/arch-build/$(PKG)-$(DEBVER) - tar -c --exclude=arch-build --no-recursion -f - `bzr inventory` | (cd debian/arch-build/$(PKG)-$(DEBVER);tar xf -) + tar -c --exclude=arch-build --no-recursion -f - `bzr inventory` \ + | (cd debian/arch-build/$(PKG)-$(DEBVER);tar xf -) (cd debian/arch-build/$(PKG)-$(DEBVER) && $(DEB_BUILD_PROG)) +build/python-apt-dbg:: + set -e; \ + for i in $(cdbs_python_build_versions); do \ + python$$i-dbg ./setup.py build; \ + done + +install/python-apt-dbg:: + for i in $(cdbs_python_build_versions); do \ + python$$i-dbg ./setup.py install --root $(CURDIR)/debian/python-apt-dbg; \ + done + find debian/python-apt-dbg \ + ! -type d ! -name '*_d.so' | xargs rm -f + find debian/python-apt-dbg -depth -empty -exec rmdir {} \; + +binary-predeb/python-apt-dbg:: + rm -rf debian/python-apt-dbg/usr/share/doc/python-apt-dbg + ln -s python-apt debian/python-apt-dbg/usr/share/doc/python-apt-dbg + +clean:: + rm -rf build/lib* build/temp* diff --git a/po/python-apt.pot b/po/python-apt.pot index ba144165..d4f55396 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: 2007-01-26 14:17+0100\n" +"POT-Creation-Date: 2007-02-14 17:34+0100\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" -- cgit v1.2.3 From a1611b6a1d0754eb54a751797d5be0137740f081 Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Tue, 27 Feb 2007 10:26:30 +0100 Subject: * debian/python-apt.install: - required now because we build python-dbg too * debian/changelog: - merged matts changes * debian/control: - change maintainer --- debian/changelog | 14 ++++++++++++++ debian/control | 5 +++-- debian/python-apt.install | 2 ++ 3 files changed, 19 insertions(+), 2 deletions(-) create mode 100644 debian/python-apt.install (limited to 'debian') diff --git a/debian/changelog b/debian/changelog index 387424d8..bd402382 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,17 @@ +python-apt (0.6.20ubuntu9) feisty; urgency=low + + * Re-add debian/python-apt.install (LP: #88134) + - This seems to have gone missing between 0.6.20ubuntu6 and 0.6.20ubuntu8 + - This probably happened because it wasn't added to bzr + + -- Matt Zimmerman Mon, 26 Feb 2007 14:04:15 -0800 + +python-apt (0.6.20ubuntu8) feisty; urgency=low + + * fix FTBFS + + -- Michael Vogt Mon, 26 Feb 2007 18:41:37 +0100 + python-apt (0.6.20ubuntu7) feisty; urgency=low * aptsources/distro.py: diff --git a/debian/control b/debian/control index 0c50e35f..c705c697 100644 --- a/debian/control +++ b/debian/control @@ -1,11 +1,12 @@ Source: python-apt Section: python Priority: optional -Maintainer: APT Development Team +Maintainer: Michael Vogt +XSBC-Original-Maintainer: APT Development Team Uploaders: Matt Zimmerman , Michael Vogt Standards-Version: 3.7.2 XS-Python-Version: all -Build-Depends: debhelper (>= 5.0.37.1), libapt-pkg-dev (>= 0.6.46.4ubuntu8), apt-utils, python-all-dev, python-distutils-extra, cdbs, python-central (>= 0.5) +Build-Depends: debhelper (>= 5.0.37.1), libapt-pkg-dev (>= 0.6.46.4ubuntu8), apt-utils, python-all-dev, python-distutils-extra, cdbs, python-central (>= 0.5), python-all-dbg Package: python-apt Architecture: any diff --git a/debian/python-apt.install b/debian/python-apt.install new file mode 100644 index 00000000..3e08ba50 --- /dev/null +++ b/debian/python-apt.install @@ -0,0 +1,2 @@ +debian/tmp/usr/lib/python* +debian/tmp/usr/share/python-apt -- cgit v1.2.3 From 2fd8253d205afd8341efe5775e2fab1b76ef1f52 Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Tue, 27 Feb 2007 10:53:51 +0100 Subject: * debian/rules: - the package is python-apt not gdebi (blush) --- debian/rules | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'debian') diff --git a/debian/rules b/debian/rules index 7e837e8b..63c9bc3b 100755 --- a/debian/rules +++ b/debian/rules @@ -9,7 +9,7 @@ DEB_PYTHON_PACKAGES_EXCLUDE=python-apt-dbg include /usr/share/cdbs/1/rules/debhelper.mk include /usr/share/cdbs/1/class/python-distutils.mk -PKG=gdebi +PKG=python-apt DEBVER=$(shell dpkg-parsechangelog |sed -n -e '/^Version:/s/^Version: //p') DEB_BUILD_PROG:=debuild --preserve-envvar PATH --preserve-envvar CCACHE_DIR -us -uc $(DEB_BUILD_PROG_OPTS) -- cgit v1.2.3 From e542d9c5e2663bafc3f16ed8d9adba5f5e34d87d Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Thu, 1 Mar 2007 14:39:55 +0100 Subject: * debian/rules: python-apt is the name of the pacakge --- debian/rules | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'debian') diff --git a/debian/rules b/debian/rules index 7e837e8b..63c9bc3b 100755 --- a/debian/rules +++ b/debian/rules @@ -9,7 +9,7 @@ DEB_PYTHON_PACKAGES_EXCLUDE=python-apt-dbg include /usr/share/cdbs/1/rules/debhelper.mk include /usr/share/cdbs/1/class/python-distutils.mk -PKG=gdebi +PKG=python-apt DEBVER=$(shell dpkg-parsechangelog |sed -n -e '/^Version:/s/^Version: //p') DEB_BUILD_PROG:=debuild --preserve-envvar PATH --preserve-envvar CCACHE_DIR -us -uc $(DEB_BUILD_PROG_OPTS) -- cgit v1.2.3 From c631c7d089ff1178c6ce4379aa5cb8561459ac6d Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Thu, 1 Mar 2007 16:04:30 +0100 Subject: * debian/control: - added XS-Vcs-Bzr header to make finding the repo easier --- debian/changelog | 7 +++++++ debian/control | 1 + 2 files changed, 8 insertions(+) (limited to 'debian') diff --git a/debian/changelog b/debian/changelog index bd402382..bd5bb14b 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,10 @@ +python-apt (0.6.20ubuntu10) feisty; urgency=low + + * debian/control: + - added XS-Vcs-Bzr header to make finding the repo easier + + -- Michael Vogt Thu, 1 Mar 2007 14:36:33 +0100 + python-apt (0.6.20ubuntu9) feisty; urgency=low * Re-add debian/python-apt.install (LP: #88134) diff --git a/debian/control b/debian/control index c705c697..2a344320 100644 --- a/debian/control +++ b/debian/control @@ -7,6 +7,7 @@ Uploaders: Matt Zimmerman , Michael Vogt Standards-Version: 3.7.2 XS-Python-Version: all Build-Depends: debhelper (>= 5.0.37.1), libapt-pkg-dev (>= 0.6.46.4ubuntu8), apt-utils, python-all-dev, python-distutils-extra, cdbs, python-central (>= 0.5), python-all-dbg +XS-Vcs-Bzr: http://launchpad.net/~ubuntu-core-dev/python-apt/ubuntu Package: python-apt Architecture: any -- cgit v1.2.3 From ec30e020ffdcb6cf5f11fd1e761083bd9711c41c Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Fri, 9 Mar 2007 15:40:39 +0100 Subject: * apt/cdrom.py: - fix bug in cdrom __init__ code * debian/rules: - added "DH_PYCENTRAL=nomove" --- apt/cdrom.py | 4 ++-- debian/changelog | 10 ++++++++++ debian/rules | 2 ++ 3 files changed, 14 insertions(+), 2 deletions(-) (limited to 'debian') diff --git a/apt/cdrom.py b/apt/cdrom.py index d499b30a..8d73339c 100644 --- a/apt/cdrom.py +++ b/apt/cdrom.py @@ -1,6 +1,6 @@ import apt_pkg -from apt.progress import CdromProgress +from progress import CdromProgress class Cdrom(object): def __init__(self, progress=None, mountpoint=None, nomount=True): @@ -12,7 +12,7 @@ class Cdrom(object): """ self._cdrom = apt_pkg.GetCdrom() if progress is None: - self._progress = apt.progress.CdromProgress() + self._progress = CdromProgress() else: self._progress = progress # see if we have a alternative mountpoint diff --git a/debian/changelog b/debian/changelog index 5e648c93..c67bc8ea 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,13 @@ +python-apt (0.6.20ubuntu12) feisty; urgency=low + + * apt/cdrom.py: + - fix bug in cdrom __init__ code + * debian/rules: + - added "DH_PYCENTRAL=nomove" + + + -- Michael Vogt Wed, 7 Mar 2007 10:41:00 +0100 + python-apt (0.6.20ubuntu11) feisty; urgency=low * apt/packages.py: diff --git a/debian/rules b/debian/rules index 63c9bc3b..33d04a21 100755 --- a/debian/rules +++ b/debian/rules @@ -3,6 +3,8 @@ DEB_AUTO_CLEANUP_RCS := yes DEB_PYTHON_SYSTEM=pycentral +export DH_PYCENTRAL=nomove + DEB_PYTHON_PACKAGES_EXCLUDE=python-apt-dbg # Add here any variable or target overrides you need -- cgit v1.2.3 From 9a97aa02892342fa4fe7e2f8e3bfe314f194ef0e Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Wed, 14 Mar 2007 16:44:10 +0100 Subject: * python/depache.cc: - properly support isAutoInstalled flag --- debian/changelog | 4 +++- python/depcache.cc | 15 +++++++++++++++ 2 files changed, 18 insertions(+), 1 deletion(-) (limited to 'debian') diff --git a/debian/changelog b/debian/changelog index 974662bc..7e897122 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,8 +1,10 @@ python-apt (0.6.20ubuntu13) feisty; urgency=low * fix in the duplicated source checking (thanks to Sebastian Heinlein) + * python/depache.cc: + - properly support isAutoInstalled flag - -- + -- Michael Vogt Wed, 14 Mar 2007 16:38:22 +0100 python-apt (0.6.20ubuntu12) feisty; urgency=low diff --git a/python/depcache.cc b/python/depcache.cc index 71e6a2e6..94ff708c 100644 --- a/python/depcache.cc +++ b/python/depcache.cc @@ -386,6 +386,20 @@ static PyObject *PkgDepCacheIsGarbage(PyObject *Self,PyObject *Args) return HandleErrors(Py_BuildValue("b",state.Garbage)); } +static PyObject *PkgDepCacheIsAutoInstalled(PyObject *Self,PyObject *Args) +{ + pkgDepCache *depcache = GetCpp(Self); + + PyObject *PackageObj; + if (PyArg_ParseTuple(Args,"O!",&PackageType,&PackageObj) == 0) + return 0; + + pkgCache::PkgIterator &Pkg = GetCpp(PackageObj); + pkgDepCache::StateCache &state = (*depcache)[Pkg]; + + return HandleErrors(Py_BuildValue("b",state.Flags & pkgCache::Flag::Auto)); +} + static PyObject *PkgDepCacheIsNowBroken(PyObject *Self,PyObject *Args) { pkgDepCache *depcache = GetCpp(Self); @@ -524,6 +538,7 @@ static PyMethodDef PkgDepCacheMethods[] = {"IsNowBroken",PkgDepCacheIsNowBroken,METH_VARARGS,"Is pkg is now broken"}, {"IsInstBroken",PkgDepCacheIsInstBroken,METH_VARARGS,"Is pkg broken on the current install"}, {"IsGarbage",PkgDepCacheIsGarbage,METH_VARARGS,"Is pkg garbage (mark-n-sweep)"}, + {"IsAutoInstalled",PkgDepCacheIsAutoInstalled,METH_VARARGS,"Is pkg marked as auto installed"}, {"MarkedInstall",PkgDepCacheMarkedInstall,METH_VARARGS,"Is pkg marked for install"}, {"MarkedUpgrade",PkgDepCacheMarkedUpgrade,METH_VARARGS,"Is pkg marked for upgrade"}, {"MarkedDelete",PkgDepCacheMarkedDelete,METH_VARARGS,"Is pkg marked for delete"}, -- cgit v1.2.3 From 0b8033d96e6144f8bc05583be0b2d1743f3c73a6 Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Thu, 15 Mar 2007 13:09:32 +0100 Subject: * aptsources/distro.py: - fix typo (LP#84009) --- aptsources/distro.py | 5 ++--- debian/changelog | 7 +++++++ 2 files changed, 9 insertions(+), 3 deletions(-) (limited to 'debian') diff --git a/aptsources/distro.py b/aptsources/distro.py index a95fecdd..16fb0dc7 100644 --- a/aptsources/distro.py +++ b/aptsources/distro.py @@ -426,8 +426,7 @@ def get_distro(): return UbuntuDistribution(id, codename, description, release) elif id == "Debian": - return DebianDistribution(id, codename, description, - release) + return DebianDistribution(id, codename, description, release) else: - return Distribution(id, codename, description, relase) + return Distribution(id, codename, description, release) diff --git a/debian/changelog b/debian/changelog index 7e897122..05efcd08 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,10 @@ +python-apt (0.6.20ubuntu14) feisty; urgency=low + + * aptsources/distro.py: + - fix typo (LP#84009) + + -- + python-apt (0.6.20ubuntu13) feisty; urgency=low * fix in the duplicated source checking (thanks to Sebastian Heinlein) -- cgit v1.2.3 From 608943524b167fe6191750b739b0d230b549638c Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Thu, 22 Mar 2007 15:34:50 +0100 Subject: * fix gettext import (LP#92764) --- apt/package.py | 2 ++ debian/changelog | 1 + 2 files changed, 3 insertions(+) (limited to 'debian') diff --git a/apt/package.py b/apt/package.py index fec438c0..1f373ad3 100644 --- a/apt/package.py +++ b/apt/package.py @@ -24,6 +24,8 @@ import sys import random import string +from gettext import gettext as _ + class BaseDependency(object): " a single dependency " def __init__(self, name, rel, ver, pre): diff --git a/debian/changelog b/debian/changelog index 05efcd08..4950be51 100644 --- a/debian/changelog +++ b/debian/changelog @@ -2,6 +2,7 @@ python-apt (0.6.20ubuntu14) feisty; urgency=low * aptsources/distro.py: - fix typo (LP#84009) + * fix gettext import (LP#92764) -- -- cgit v1.2.3