From 7b921f4d09f33d9ea0446904b3a6cfe4adbcebd2 Mon Sep 17 00:00:00 2001 From: "(no author)" <(no author)@cd1c1023-2f26-0410-ae45-c471fc1f0318> Date: Sun, 11 Nov 2007 18:53:52 +0000 Subject: [PATCH] reagent md5remote scan atoms in all branches git-svn-id: http://svn.sabayonlinux.org/projects/entropy/trunk@658 cd1c1023-2f26-0410-ae45-c471fc1f0318 --- TODO | 2 +- libraries/reagentTools.py | 22 ++++++++++++++-------- 2 files changed, 15 insertions(+), 9 deletions(-) diff --git a/TODO b/TODO index 951e337cd..cbb1a3541 100644 --- a/TODO +++ b/TODO @@ -3,7 +3,7 @@ TODO list: - use depgraph generation function to generate dependencies - installPackages should pull conflicts depends too - find a way to better handle real smartapps deps - - equo world, user should specify which branch to switch to + - equo world, user should specify which branch to switch to (or without params: detect latest automatically, at the end write branch| to equo conf files) Project Status: diff --git a/libraries/reagentTools.py b/libraries/reagentTools.py index 4144c65cd..b3810d1d4 100644 --- a/libraries/reagentTools.py +++ b/libraries/reagentTools.py @@ -1246,11 +1246,14 @@ def database(options): # catch the names pkgs2check = [] for pkg in mypackages: - result = dbconn.atomMatch(pkg) - if result[0] != -1: - iatom = dbconn.retrieveAtom(result[0]) - ibranch = dbconn.retrieveBranch(result[0]) - pkgs2check.append((iatom,result[0],ibranch)) + result = dbconn.atomMatch(pkg, multiMatch = True, matchBranches = etpConst['branches']) + if result[1] == 0: + for idresult in result[0]: + iatom = dbconn.retrieveAtom(idresult) + ibranch = dbconn.retrieveBranch(idresult) + pkgs2check.append((iatom,idresult,ibranch)) + else: + print_warning(red("ATTENTION: ")+blue("cannot match: ")+bold(pkg)) if (not worldSelected): print_info(red(" This is the list of the packages that would be checked:")) @@ -1372,9 +1375,10 @@ def database(options): # catch the names pkgs2check = [] for pkg in mypackages: - result = dbconn.atomMatch(pkg) - if result[0] != -1: - pkgs2check.append(result[0]) + result = dbconn.atomMatch(pkg, multiMatch = True, matchBranches = etpConst['branches']) + if result[1] == 0: + for idresult in result[0]: + pkgs2check.append(idresult) else: print_warning(red("ATTENTION: ")+blue("cannot match: ")+bold(pkg)) @@ -1422,6 +1426,8 @@ def database(options): print_warning(" "+red(" -> Digest verification of ")+green(pkgfilename)+bold(" not supported")) elif len(ck) == 32: ckOk = True + else: + print_warning(" "+red(" -> Digest verification of ")+green(pkgfilename)+bold(" failed for unknown reasons")) if (ckOk): pkgMatch += 1