Merge ~emitorino/usn-tool:fix_usn_similarity_to_consider_old_usns into usn-tool:master
Status: | Merged |
---|---|
Merged at revision: | 1311977c225c2b27078f52a8fc3f0d7aa4044e0b |
Proposed branch: | ~emitorino/usn-tool:fix_usn_similarity_to_consider_old_usns |
Merge into: | usn-tool:master |
Diff against target: |
22 lines (+8/-4) 1 file modified
usn.py (+8/-4) |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Alex Murray | Approve | ||
Review via email: mp+416099@code.launchpad.net |
Commit message
- usn.py: check is sources key is present before comparing USNs in usn_similar
Description of the change
While trying to publish the updates to the USNs related to fixing terms which could be non-inclusive, usn.py failed to compare USNs when sources key is not present. This happens only with old USNs: 126-1, 149-1, 152-1, 155-1, 204-1, 30-1, 363-1, 412-1 and 483-1.
If needed we can add the sources to those USNs as well, but the check seems correct anyways for the script to not fail like it is failing now:
Traceback (most recent call last):
File "/home/
output = main(sys.argv[1:])
File "/home/
if key in database and not usn_similar(
File "/home/
if set(old[
KeyError: 'sources'
LGTM!