From 0321a0211af569abeb841e33e62f4b914845e4df Mon Sep 17 00:00:00 2001 From: "W. Trevor King" Date: Sun, 11 Nov 2012 16:06:08 -0500 Subject: [PATCH] package: wrap long lines to avoid pylint C0301 --- pym/gentoolkit/package.py | 29 ++++++++++++++++++++--------- 1 file changed, 20 insertions(+), 9 deletions(-) diff --git a/pym/gentoolkit/package.py b/pym/gentoolkit/package.py index f066783..3bf9fcd 100644 --- a/pym/gentoolkit/package.py +++ b/pym/gentoolkit/package.py @@ -198,26 +198,36 @@ class Package(CPV): envvars = (envvars,) if prefer_vdb: try: - result = portage.db[portage.root]["vartree"].dbapi.aux_get(self.cpv, envvars) + result = portage.db[portage.root][ + 'vartree'].dbapi.aux_get( + self.cpv, envvars) except KeyError: try: if not fallback: raise KeyError - result = portage.db[portage.root]["porttree"].dbapi.aux_get(self.cpv, envvars) + result = portage.db[portage.root][ + 'porttree'].dbapi.aux_get( + self.cpv, envvars) except KeyError: - err = "aux_get returned unexpected results" - raise errors.GentoolkitFatalError(err) + raise errors.GentoolkitFatalError( + 'aux_get returned unexpected ' + 'results') else: try: - result = portage.db[portage.root]["porttree"].dbapi.aux_get(self.cpv, envvars) + result = portage.db[portage.root][ + 'porttree'].dbapi.aux_get( + self.cpv, envvars) except KeyError: try: if not fallback: raise KeyError - result = portage.db[portage.root]["vartree"].dbapi.aux_get(self.cpv, envvars) + result = portage.db[portage.root][ + 'vartree'].dbapi.aux_get( + self.cpv, envvars) except KeyError: - err = "aux_get returned unexpected results" - raise errors.GentoolkitFatalError(err) + raise errors.GentoolkitFatalError( + 'aux_get returned unexpected ' + 'results') if got_string: return result[0] @@ -399,7 +409,8 @@ class Package(CPV): @note: We blindly assume that the package actually exists on disk. """ - unmasked = portage.db[portage.root]["porttree"].dbapi.xmatch("match-visible", self.cpv) + unmasked = portage.db[portage.root]['porttree'].dbapi.xmatch( + 'match-visible', self.cpv) return self.cpv not in unmasked -- 2.26.2