Merge ~bryce/git-ubuntu:fix_derive_codename_from_series into git-ubuntu:master
Status: | Superseded |
---|---|
Proposed branch: | ~bryce/git-ubuntu:fix_derive_codename_from_series |
Merge into: | git-ubuntu:master |
Diff against target: |
195 lines (+150/-3) 2 files modified
gitubuntu/source_information.py (+21/-3) gitubuntu/source_information_test.py (+129/-0) |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Robie Basak | Needs Fixing | ||
Server Team CI bot | continuous-integration | Approve | |
Review via email: mp+370035@code.staging.launchpad.net |
Commit message
source_information: Fix ubuntu series lookup
Corrects an issue found by coverity:
usd-importer/
copy_
usd-importer/
remediation: Should it say "u_udi" instead?
The code is erroneously using the Debian implementation of codename(),
which translates aliases ('unstable', 'testing', etc.) to the release
codenames ('sid', 'buster', etc.) Fortunately, if it doesn't match
anything it just returns the release name passed to it, which is exactly
what the Ubuntu implementation of codename() does.
Thus, even though the code is incorrect, it's behavior will always be
correct in practice. Thus this fix corrects a purely theoretical
problem, not one that would produce invalid behavior.
Tests and code documentation for derive_
Description of the change
These four patches should probably be squashed to land, although you may want to land the syntax error fix separately; I couldn't get pytest to function without it but it's an independent issue. I've left the patches split out for review convenience, but if they're landed this way patch #1 will introduce a test failure, that patch #3 fixes.
There was an error fetching revisions from git servers. Please try again in a few minutes. If the problem persists, contact Launchpad support.
PASSED: Continuous integration, rev:147037f0801 dea8a8541840728 0768076045f3d8 /jenkins. ubuntu. com/server/ job/git- ubuntu- ci/102/
https:/
Executed test runs:
SUCCESS: VM Setup
SUCCESS: Build
SUCCESS: Unit Tests
IN_PROGRESS: Declarative: Post Actions
Click here to trigger a rebuild: /jenkins. ubuntu. com/server/ job/git- ubuntu- ci/102/ rebuild
https:/