git://git.onelab.eu
/
sfa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
676d81c
)
fix package import
author
Tony Mack
<tmack@cs.princeton.edu>
Tue, 12 Jan 2010 02:49:28 +0000
(
02:49
+0000)
committer
Tony Mack
<tmack@cs.princeton.edu>
Tue, 12 Jan 2010 02:49:28 +0000
(
02:49
+0000)
sfa/server/sfa-clean-peer-records.py
patch
|
blob
|
history
diff --git
a/sfa/server/sfa-clean-peer-records.py
b/sfa/server/sfa-clean-peer-records.py
index
18e13e3
..
80dbc23
100644
(file)
--- a/
sfa/server/sfa-clean-peer-records.py
+++ b/
sfa/server/sfa-clean-peer-records.py
@@
-12,7
+12,7
@@
from sfa.trust.certificate import Keypair
from sfa.trust.hierarchy import Hierarchy
from sfa.util.report import trace, error
from sfa.server.registry import Registries
from sfa.trust.hierarchy import Hierarchy
from sfa.util.report import trace, error
from sfa.server.registry import Registries
-from sfa.util.xmlrpcprotocol import *
+import sfa.util.xmlrpcprotocol as xmlrpcprotocol
import socket
def main():
import socket
def main():
@@
-60,7
+60,14
@@
def main():
try:
records = registries[registry_hrn].resolve(credential, target_hrns)
found_records.extend([record['hrn'] for record in records])
try:
records = registries[registry_hrn].resolve(credential, target_hrns)
found_records.extend([record['hrn'] for record in records])
+ except ServerException:
+ # an exception will be thrown if the record doenst exist
+ # if so remove the record from the local registry
+ continue
except:
except:
+ # this deosnt necessarily mean the records dont exist
+ # lets give them the benefit of the doubt here (for now)
+ found_records.extend(target_hrns)
traceback.print_exc()
# remove what wasnt found
traceback.print_exc()
# remove what wasnt found