[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#523998: marked as done (python-apt: Package class should have a get_version method)



Your message dated Thu, 30 Jul 2009 17:32:30 +0000
with message-id <E1MWZUU-0001Zs-Qx@ries.debian.org>
and subject line Bug#523998: fixed in python-apt 0.7.12.0
has caused the Debian Bug report #523998,
regarding python-apt: Package class should have a get_version method
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact owner@bugs.debian.org
immediately.)


-- 
523998: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=523998
Debian Bug Tracking System
Contact owner@bugs.debian.org with problems
--- Begin Message ---
Package: python-apt
Version: 0.7.7.1+nmu1
Severity: wishlist
Tags: patch

The Package class should provide a nice way to get a corresponding Version 
instance by specifing the version string.

E.g.: Package.get_version("242-1")

See the attached patch

Cheers,

Sebastian

-- System Information:
Debian Release: 5.0
  APT prefers stable
  APT policy: (500, 'stable')
Architecture: i386 (i686)

Kernel: Linux 2.6.26-1-686 (SMP w/2 CPU cores)
Locale: LANG=de_DE.UTF-8, LC_CTYPE=de_DE.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/bash

Versions of packages python-apt depends on:
ii  apt [libapt-pkg-libc6.7-6-4. 0.7.20.2    Advanced front-end for dpkg
ii  apt-utils [libapt-inst-libc6 0.7.20.2    APT utility programs
ii  libc6                        2.7-18      GNU C Library: Shared libraries
ii  libgcc1                      1:4.3.2-1.1 GCC support library
ii  libstdc++6                   4.3.2-1.1   The GNU Standard C++ Library v3
ii  lsb-release                  3.2-20      Linux Standard Base version report
ii  python                       2.5.2-3     An interactive high-level object-o
ii  python-central               0.6.8       register and build utility for Pyt

python-apt recommends no packages.

Versions of packages python-apt suggests:
pn  python-apt-dbg                <none>     (no description available)

-- no debconf information
# Bazaar merge directive format 2 (Bazaar 0.90)
# revision_id: renate@unstable.virtual-20090410204237-qwwl1a7f9yy1ogci
# target_branch: ../debian-sid/
# testament_sha1: b87ebcdf3d99a10932db8528b7f3b8365763ba41
# timestamp: 2009-04-10 22:43:31 +0200
# base_revision_id: jak@debian.org-20090401154054-zh33a3avjszl3fg7
# 
# Begin patch
=== modified file 'apt/package.py'
--- apt/package.py	2009-04-01 14:27:15 +0000
+++ apt/package.py	2009-04-10 20:42:37 +0000
@@ -872,6 +872,13 @@
         """
         return [Version(self, ver) for ver in self._pkg.VersionList]
 
+    def get_version(self, version):
+        """Get the Version instance matching the given version string."""
+        for ver in self.versions:
+            if ver.version == version:
+                return ver
+        return None
+
     # depcache actions
 
     def markKeep(self):

# Begin bundle
IyBCYXphYXIgcmV2aXNpb24gYnVuZGxlIHY0CiMKQlpoOTFBWSZTWb2VsC0AAZNfgERUUWf//3LD
TQC////wUAP2bxuNodI22PYSSKekamaT0j0einim1DRoGgAAyGglEpjRmknkiD1GgAAAAAAEiQIQ
NTUeU/VPKA009QyAaMnqHqDQMpI0D0TRoDBA0aGgMgA00wEkkaaTTJiZU9o0KeU/SZJtPSm1AGTR
o0VodM82wW+ebuNTHRP2cNBGFSKtnV2QB2LnRWOVECoXG/QfLFjc8TlOqeBOCKLm6/nr5Ug46O7t
mXX2KzrH2pHF3MsmY0rInKkHn6t1eGXTu2anjLbxd1/q540JUv2zvIPn6PkuoZtXS6NQYBVxFRnU
NReyNsVOEGtxOSxKk6hJrfFdqkExO7kJVB2CbqIiE5PXAYQ4fyMlmRGmQUsoR7Lt9RH8zM47SnaX
uVMZnH2NqYyOeaRVltwvXGjNlXxEaBV9NIEKi2wjvLYEAnIyaG9SKLdbeRnStvMeCpbJSMlujM9T
gi9agYSIFMURziQ9LsMSw1zOPIDDLePgkklkTQSdgVo4YUjhWllBiU7kUXTnuZRIs1Ijy6+wYZMC
8kKJUbb7rBihSiSHsqkSwQmQLqE7TSKi0vE4+bdhAnJjMRzizp8ZOD+8WKmYKWOjHd6UXNKO5Noa
ZweDf1nDbK0FnHVP2hmU0sXi0zsdc+sBqIgaseM362NcQ9PmpO5UeBxViepIMDrO2N7BTEe4YqRg
XiqNRYf5iZLZ5twK5xYGwzm4P4HVLwuKHIYfZQLngEEtC81zeQK84wOSwzLgHQtOY4vIjMbSFsTJ
W4iniY+C3zU4lMhiZVEmjMiKCU8rjyD75dZ44Ti54uGjlLwDuCdoGk5pbiU4Eqco6uaAY9cQmtdh
sJf1cLiepIAyZDKFlL4/6MBeGk9i9LFlSMig/QQpOl4tIMMDx5Wbl48Oza35ZeMRWDZVgKYDTf8G
NigK4sTWAwqVNtep0wXtE7usOV9a7FR6I24D85SlPLcx4hkmxtCBstkfmSDkSW9oH6KvBiRVFwMZ
gcljVYrFuJ65LEmK3l+3Ot3OoqiQ+o4T3HRursKkpXwpMjQQpg0jAklJUCaYft/G09SUyAMyHJy3
d8kBalirwgJcRg9S90qKspwD3g5TPU9EmdqYxUCQK5ct++Ni6qRUytU4cDBbdZKZE7C6e7vaeiKt
SzBnzbCS5lEtYUQqZJQQu+RUb5z05slgbsGk2MTiyuL0mzXYLh8VKnBdCkQK3IotIigEsMC5rVXQ
SIC9Mak1pahLBMuCPB3UPZ6pOQprlISVjmQMAQEKbEEsAC8VCrCDxBk4jhwKiax3eJ+JPhrE+cyr
eUP8XckU4UJC9lbAtA==

--- End Message ---
--- Begin Message ---
Source: python-apt
Source-Version: 0.7.12.0

We believe that the bug you reported is fixed in the latest version of
python-apt, which is due to be installed in the Debian FTP archive:

python-apt-dbg_0.7.12.0_amd64.deb
  to pool/main/p/python-apt/python-apt-dbg_0.7.12.0_amd64.deb
python-apt_0.7.12.0.dsc
  to pool/main/p/python-apt/python-apt_0.7.12.0.dsc
python-apt_0.7.12.0.tar.gz
  to pool/main/p/python-apt/python-apt_0.7.12.0.tar.gz
python-apt_0.7.12.0_amd64.deb
  to pool/main/p/python-apt/python-apt_0.7.12.0_amd64.deb



A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 523998@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Julian Andres Klode <jak@debian.org> (supplier of updated python-apt package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@debian.org)


-----BEGIN PGP SIGNED MESSAGE-----
Hash: RIPEMD160

Format: 1.8
Date: Thu, 30 Jul 2009 14:08:30 +0200
Source: python-apt
Binary: python-apt python-apt-dbg
Architecture: source amd64
Version: 0.7.12.0
Distribution: unstable
Urgency: low
Maintainer: APT Development Team <deity@lists.debian.org>
Changed-By: Julian Andres Klode <jak@debian.org>
Description: 
 python-apt - Python interface to libapt-pkg
 python-apt-dbg - Python interface to libapt-pkg (debug extension)
Closes: 416247 523997 523998 525134 527543 532338 532660
Changes: 
 python-apt (0.7.12.0) unstable; urgency=low
 .
   [ Julian Andres Klode ]
   * python/cache.cc:
     - Support Breaks, Enhances dependency types (Closes: #416247)
   * debian/control:
     - Only recommend libjs-jquery (Closes: #527543)
     - Build-depend on libapt-pkg-dev (>= 0.7.22~)
     - Update Standards-Version to 3.8.2
   * apt/cache.py:
     - Correctly handle rootdir on second and later invocations of
       open(), by calling InitSystem again. (LP: #320665).
     - Provide broken_count, delete_count, install_count, keep_count
       properties (Closes: #532338)
     - Only create Package objects when they are requested, do not keep them in
       a dict. Saves 10MB for 25,000 packages on my machine.
   * apt/package.py:
     - Allow to set the candidate of a package (Closes: #523997)
       + Support assignments to the 'candidate' property of Package objects.
       + Initial patch by Sebastian Heinlein
     - Make comparisons of Version object more robust.
     - Return VersionList objects in Package.versions, which are sequences
       and also provide features of mappings. (partial API BREAK)
       + Allows to get a specific version (Closes: #523998)
   * apt/progress/__init__.py:
     - Do not break out of InstallProgress.waitChild()'s loop just because it
       is hitting EINTR, but only on child exit or on ECHILD.
   * Use debhelper 7 instead of CDBS
 .
   [ Stefano Zacchiroli ]
   * debian/python-apt.doc-base: register the documentation with the
     doc-base system (Closes: #525134)
 .
   [ Sebastian Heinlein ]
   * apt/progress.py: Extract the package name from the status message
     (Closes: #532660)
Checksums-Sha1: 
 53c55f55c603e4645cf80b10af401bb462616d83 1191 python-apt_0.7.12.0.dsc
 69df96f527a457618b99233b5b626d90f58558e6 680643 python-apt_0.7.12.0.tar.gz
 218344eaff611f7a99ff701b71d9cd717b90be6c 404106 python-apt_0.7.12.0_amd64.deb
 9f5ba661ed5917c6d568daa73a64b9c1587c7bb8 1530614 python-apt-dbg_0.7.12.0_amd64.deb
Checksums-Sha256: 
 411f2f48eda5f8a33e3e40319c4a670f24fe3b958c2e48a3873f4d963f48a43f 1191 python-apt_0.7.12.0.dsc
 b18d4e018e2ec1b2c26f906f83ec920b92475a00c88e5fb104b7bbd32a320984 680643 python-apt_0.7.12.0.tar.gz
 9461666854200c8b43881cc27d3d55f0526919c6b65a249da18067311cdcee7e 404106 python-apt_0.7.12.0_amd64.deb
 eec35a8f455d5cfdc62ddc443ceb1c474f156e981abaf7f3f5a3bb6533dc708d 1530614 python-apt-dbg_0.7.12.0_amd64.deb
Files: 
 40309d6887a42104b4bc640749b3d7ef 1191 python optional python-apt_0.7.12.0.dsc
 8f5a2c65bafe0ece59ef538169fa9925 680643 python optional python-apt_0.7.12.0.tar.gz
 87c903e07134bd2ad3277c582f342f80 404106 python optional python-apt_0.7.12.0_amd64.deb
 d7d2f0309c111d76ca2d58fb6a571dc2 1530614 debug extra python-apt-dbg_0.7.12.0_amd64.deb

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)

iEYEAREDAAYFAkpx1q4ACgkQrCpf/gCCPsIH6wCfZMKr4q6VZzUnK0a6w0vI2xKW
foEAnifFoNGHa6LFtKj08ycrdjRjCSfQ
=YdXq
-----END PGP SIGNATURE-----



--- End Message ---

Reply to: