Hash the patch directories better.

This commit is contained in:
Michael Still 2014-05-26 16:05:27 +10:00
parent b6ece5df25
commit ba73f3ba95
1 changed files with 2 additions and 1 deletions

View File

@ -122,7 +122,8 @@ for filename in changed_merge_files:
patchset = j['patchSet']['number']
project = j['change']['project']
patch_key = 'patches/%s/%s' % (project, number)
patch_key = 'patches/%s/%s/%s' % (project, number[:2],
number[2:])
if os.path.exists('%s/%s.json' % (patch_key, number)):
with open('%s/%s.json' % (patch_key, patchset)) as f:
patches.setdefault(patch_key, {})