##// END OF EJS Templates
obsolete: add a `commonversion` function...
Pierre-Yves David -
r22345:cf7014c5 default
parent child Browse files
Show More
@@ -455,6 +455,17 b' class obsstore(object):'
455 seennodes |= pendingnodes
455 seennodes |= pendingnodes
456 return seenmarkers
456 return seenmarkers
457
457
458 def commonversion(versions):
459 """Return the newest version listed in both versions and our local formats.
460
461 Returns None if no common version exists.
462 """
463 versions.sort(reverse=True)
464 # search for highest version known on both side
465 for v in versions:
466 if v in formats:
467 return v
468 return None
458
469
459 # arbitrary picked to fit into 8K limit from HTTP server
470 # arbitrary picked to fit into 8K limit from HTTP server
460 # you have to take in account:
471 # you have to take in account:
General Comments 0
You need to be logged in to leave comments. Login now