Gentoo Archives: gentoo-commits

From: Brian Dolbec <brian.dolbec@×××××.com>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/portage:plugin-sync commit in: pym/portage/sync/
Date: Tue, 30 Sep 2014 00:47:07
Message-Id: 1412037746.6d671d0bece90ae9943b03577f372fc8ff76e905.dol-sen@gentoo
1 commit: 6d671d0bece90ae9943b03577f372fc8ff76e905
2 Author: Brian Dolbec <dolsen <AT> gentoo <DOT> org>
3 AuthorDate: Tue Jun 17 18:44:43 2014 +0000
4 Commit: Brian Dolbec <brian.dolbec <AT> gmail <DOT> com>
5 CommitDate: Tue Sep 30 00:42:26 2014 +0000
6 URL: http://sources.gentoo.org/gitweb/?p=proj/portage.git;a=commit;h=6d671d0b
7
8 portage/sync: Add additional output info for unsupported sync-types
9
10 Comment out some debug print()'s
11
12 ---
13 pym/portage/sync/__init__.py | 5 +++--
14 pym/portage/sync/config_checks.py | 4 ++++
15 2 files changed, 7 insertions(+), 2 deletions(-)
16
17 diff --git a/pym/portage/sync/__init__.py b/pym/portage/sync/__init__.py
18 index 6d2a732..b74c89e 100644
19 --- a/pym/portage/sync/__init__.py
20 +++ b/pym/portage/sync/__init__.py
21 @@ -11,12 +11,12 @@ sync_manager = None
22
23 path = os.path.join(os.path.dirname(__file__), "modules")
24 # initial development debug info
25 -print("module path:", path)
26 +#print("module path:", path)
27
28 module_controller = Modules(path=path, namepath="portage.sync.modules")
29
30 # initial development debug info
31 -print(module_controller.module_names)
32 +#print(module_controller.module_names)
33 module_names = module_controller.module_names[:]
34
35
36 @@ -43,6 +43,7 @@ def get_syncer(settings=None, logger=None):
37
38 def validate_config(repo, logger):
39 '''Validate the repos.conf settings for the repo'''
40 + global module_names, module_controller
41 if not check_type(repo, logger, module_names):
42 return False
43
44
45 diff --git a/pym/portage/sync/config_checks.py b/pym/portage/sync/config_checks.py
46 index 8ef1974..db316aa 100644
47 --- a/pym/portage/sync/config_checks.py
48 +++ b/pym/portage/sync/config_checks.py
49 @@ -26,6 +26,10 @@ def check_type(repo, logger, module_names):
50 _("Repository '%s' has sync-type attribute set to unsupported value: '%s'")
51 % (repo.name, repo.sync_type),
52 level=logger.ERROR, noiselevel=-1)
53 + writemsg_level("!!! %s\n" %
54 + _("Installed sync-types are: '%s'")
55 + % (str(module_names)),
56 + level=logger.ERROR, noiselevel=-1)
57 return False
58 return True