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

Bug#733489: [PATCH] apt/package.py: Replaced pre_depend with rawtype in BaseDependency.__repr__ as rawtype gives more information including the information from pre_depend.




On 06/28/2015 11:41 AM, Julian Andres Klode wrote:
Hi Michael,

thanks for the patch. Unfortunately, I cannot apply it without
further work.

No worries. That was kinda expected after such a long break. ;-)

On Sat, Jun 27, 2015 at 12:39:49PM +0200, Michael Schaller wrote:
---
  apt/package.py   | 4 ++--
  debian/changelog | 6 ++++++
  2 files changed, 8 insertions(+), 2 deletions(-)

Could you please include the entire patch? I can't merge that with
git am otherwise. You somehow only put the diff into the patch file
attachment, and moved the subject into the emails subject and the
stat into the first part of the email.

I've just used standard 'git send-email --attach'. I've used now 'git format-patch' and attached the generated patch manually to this email. I hope that works better for you.

Also, please format your commit messages to have a short summary
(about 70 characters) followed by a longer paragraph.

75 is as short as I can make it. I hope is sufficiently short.

  class Dependency(list):
diff --git a/debian/changelog b/debian/changelog
index 2dc57e6..e14d29b 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,5 +1,6 @@
  python-apt (1.0.0~beta3) unstable; urgency=medium

+  [ Julian Andres Klode ]
    * tests/test_paths.py: Catch and assert the DeprecationWarning
    * setup.py: If no version is in the environment, return None
    * doc/source/library/apt_pkg.rst: Fix an example from old API to new API
@@ -9,6 +10,11 @@ python-apt (1.0.0~beta3) unstable; urgency=medium
    * apt.Cache: Issue a RuntimeWarning in connect()
    * doc: whatsnew: Document what's new in beta3

+  [ Michael Schaller ]
+  * apt/package.py: Replaced pre_depend with rawtype in BaseDependency.__repr__
+    as rawtype gives more information including the information from
+    pre_depend.
+
   -- Julian Andres Klode <jak@debian.org>  Wed, 17 Jun 2015 18:28:44 +0200

  python-apt (1.0.0~beta2) unstable; urgency=low

Please do not include changelog modifications. The changelog is
auto-generated from git commits.

Done.
>From ce34acb77fe95791a56393c7f434b3d69c28586c Mon Sep 17 00:00:00 2001
From: Michael Schaller <michael@5challer.de>
Date: Sun, 28 Jun 2015 13:32:49 +0200
Subject: [PATCH] apt/package.py: BaseDependency.__repr__: Replaced pre_depend
 with rawtype.

pre_depend only states if the relation is PreDepends.
rawtype gives the relation type itself.
---
 apt/package.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/apt/package.py b/apt/package.py
index 641b1a4..391ee4f 100644
--- a/apt/package.py
+++ b/apt/package.py
@@ -130,8 +130,8 @@ class BaseDependency(object):
         return self._dep.dep_type_untranslated == 'PreDepends'
 
     def __repr__(self):
-        return ('<BaseDependency: name:%r relation:%r version:%r preDepend:%r>'
-                % (self.name, self.relation, self.version, self.pre_depend))
+        return ('<BaseDependency: name:%r relation:%r version:%r rawtype:%r>'
+                % (self.name, self.relation, self.version, self.rawtype))
 
 
 class Dependency(list):
-- 
2.1.4


Reply to: