MaskManager: portage-1-compat warnings.warn
authorZac Medico <zmedico@gentoo.org>
Fri, 28 Oct 2011 02:48:16 +0000 (19:48 -0700)
committerZac Medico <zmedico@gentoo.org>
Fri, 28 Oct 2011 02:48:16 +0000 (19:48 -0700)
pym/portage/package/ebuild/_config/LocationsManager.py
pym/portage/package/ebuild/_config/MaskManager.py

index ec3f0035fa392b1609894e8880b10b9ab5b532e1..244b7e0539b4a380053df5e3de425258618d8746 100644 (file)
@@ -136,15 +136,14 @@ class LocationsManager(object):
                        offenders = sorted(x for x in offenders
                                if os.path.isdir(os.path.join(currentPath, x)))
                        if offenders:
-                               warnings.warn((_("Profile '%(profile_path)s' in repository "
+                               warnings.warn(_("Profile '%(profile_path)s' in repository "
                                        "'%(repo_name)s' is implicitly using 'portage-1' profile format, but "
                                        "the repository profiles are not marked as that format.  This will break "
                                        "in the future.  Please either convert the following paths "
                                        "to files, or add\nprofile-formats = portage-1\nto the "
                                        "repositories layout.conf.  Files: '%(files)s'\n")
                                        % dict(profile_path=currentPath, repo_name=repo_loc,
-                                               files=', '.join(offenders))),
-                                       )
+                                               files=', '.join(offenders)))
 
                parentsFile = os.path.join(currentPath, "parent")
                eapi_file = os.path.join(currentPath, "eapi")
index affa5af31d8afe10c166631b03357a114d4c65da..64a1c5e153f15ed32166b1c88b2ee98701e2ce88 100644 (file)
@@ -5,6 +5,8 @@ __all__ = (
        'MaskManager',
 )
 
+import warnings
+
 from portage import os
 from portage.dep import ExtendedAtomDict, match_from_list, _repo_separator, _slot_separator
 from portage.localization import _
@@ -40,14 +42,13 @@ class MaskManager(object):
                                                recursive=repo_config.portage1_profiles,
                                                remember_source_file=True, verify_eapi=True)
                                if repo_config.portage1_profiles_compat and os.path.isdir(path):
-                                       writemsg((_("Repository '%(repo_name)s' is implicitly using "
+                                       warnings.warn(_("Repository '%(repo_name)s' is implicitly using "
                                                "'portage-1' profile format in its profiles/package.mask, but "
                                                "the repository profiles are not marked as that format.  This will break "
                                                "in the future.  Please either convert the following paths "
                                                "to files, or add\nprofile-format = portage-1\nto the "
                                                "repositories layout.conf.\n")
-                                               % dict(repo_name=repo_config.name)),
-                                               noiselevel=-1)
+                                               % dict(repo_name=repo_config.name))
 
                        return pmask_cache[loc]