public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Michał Górny" <mgorny@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] proj/gentoopm:master commit in: gentoopm/portagepm/, gentoopm/paludispm/
Date: Sat, 13 Aug 2011 10:54:55 +0000 (UTC)	[thread overview]
Message-ID: <4e862d470e99c990243f9ef91a76528c81f691e7.mgorny@gentoo> (raw)

commit:     4e862d470e99c990243f9ef91a76528c81f691e7
Author:     Michał Górny <mgorny <AT> gentoo <DOT> org>
AuthorDate: Sat Aug 13 10:53:52 2011 +0000
Commit:     Michał Górny <mgorny <AT> gentoo <DOT> org>
CommitDate: Sat Aug 13 10:53:52 2011 +0000
URL:        http://git.overlays.gentoo.org/gitweb/?p=proj/gentoopm.git;a=commit;h=4e862d47

Python3: replace itertools.imap() with map().

---
 gentoopm/paludispm/pkg.py |    5 ++---
 gentoopm/portagepm/pkg.py |    7 +++----
 2 files changed, 5 insertions(+), 7 deletions(-)

diff --git a/gentoopm/paludispm/pkg.py b/gentoopm/paludispm/pkg.py
index 5acf362..4f9e874 100644
--- a/gentoopm/paludispm/pkg.py
+++ b/gentoopm/paludispm/pkg.py
@@ -3,7 +3,6 @@
 # (c) 2011 Michał Górny <mgorny@gentoo.org>
 # Released under the terms of the 2-clause BSD license.
 
-import itertools
 import paludis
 
 from ..basepm.depend import PMRequiredUseAtom
@@ -138,12 +137,12 @@ class PaludisID(PMPackage, PaludisAtom):
 	@property
 	def homepages(self):
 		spec = self._get_meta(self._pkg.homepage_key())
-		return SpaceSepTuple(itertools.imap(str, spec))
+		return SpaceSepTuple(map(str, spec))
 
 	@property
 	def keywords(self):
 		kws = self._get_meta(self._pkg.keywords_key())
-		return SpaceSepFrozenSet(itertools.imap(str, kws))
+		return SpaceSepFrozenSet(map(str, kws))
 
 	@property
 	def slot(self):

diff --git a/gentoopm/portagepm/pkg.py b/gentoopm/portagepm/pkg.py
index dbdf77e..0a1399d 100644
--- a/gentoopm/portagepm/pkg.py
+++ b/gentoopm/portagepm/pkg.py
@@ -3,7 +3,6 @@
 # (c) 2011 Michał Górny <mgorny@gentoo.org>
 # Released under the terms of the 2-clause BSD license.
 
-import itertools
 from portage.versions import cpv_getkey, cpv_getversion, vercmp
 
 from ..basepm.depend import PMRequiredUseAtom
@@ -106,7 +105,7 @@ class PortageDBCPV(PMPackage, CompletePortageAtom):
 		return PortagePackageVersion(self._cpv)
 
 	def _aux_get(self, *keys):
-		val = itertools.imap(str, self._dbapi.aux_get(self._cpv, keys))
+		val = map(str, self._dbapi.aux_get(self._cpv, keys))
 		if len(keys) == 1:
 			return next(iter(val))
 		else:
@@ -236,8 +235,8 @@ class PortageCPV(PortageDBCPV, PMInstallablePackage):
 		return self._dbapi.getRepositoryName(self._tree)
 
 	def _aux_get(self, *keys):
-		val = itertools.imap(str, self._dbapi.aux_get(self._cpv,
-				keys, mytree = self._tree))
+		val = map(str, self._dbapi.aux_get(self._cpv, keys,
+				mytree = self._tree))
 		if len(keys) == 1:
 			return next(iter(val))
 		else:



             reply	other threads:[~2011-08-13 10:55 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-08-13 10:54 Michał Górny [this message]
  -- strict thread matches above, loose matches on Subject: below --
2011-08-13  9:17 [gentoo-commits] proj/gentoopm:master commit in: gentoopm/portagepm/, gentoopm/paludispm/ Michał Górny
2011-07-23  9:27 Michał Górny
2011-07-16 22:55 Michał Górny
2011-07-07 15:55 Michał Górny

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4e862d470e99c990243f9ef91a76528c81f691e7.mgorny@gentoo \
    --to=mgorny@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox