Merge ~chad.smith/cloud-init:fix-cloudinit-subcommands into cloud-init:master
Proposed by
Chad Smith
Status: | Merged | ||||
---|---|---|---|---|---|
Approved by: | Scott Moser | ||||
Approved revision: | 3bbe537c848f5f107d0af8d328fb85c5f5592b7e | ||||
Merged at revision: | 89579a68d9f51e51b24f96b933da656afd83edfb | ||||
Proposed branch: | ~chad.smith/cloud-init:fix-cloudinit-subcommands | ||||
Merge into: | cloud-init:master | ||||
Diff against target: |
46 lines (+19/-5) 2 files modified
cloudinit/cmd/main.py (+4/-5) tests/unittests/test_cli.py (+15/-0) |
||||
Related bugs: |
|
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Scott Moser | Approve | ||
Server Team CI bot | continuous-integration | Approve | |
Review via email: mp+329493@code.launchpad.net |
Description of the change
cloud-init cli: Fix command line parsing of coniditionally loaded subcommands
In an effort to save file load cost during system boot, certain
subcommands, analyze and devel, do not get loaded unless the subcommand is
specified on the commandline. Because setup.py entrypoint for cloud-init
script doesn't specify sysv_args parameter when calling the CLI's main()
we need main to read sys.argv into sysv_args so our subparser loading
continues to work.
LP: #1712676
To post a comment you must log in.
PASSED: Continuous integration, rev:3bbe537c848 f5f107d0af8d328 fb85c5f5592b7e /jenkins. ubuntu. com/server/ job/cloud- init-ci/ 193/
https:/
Executed test runs:
SUCCESS: Checkout
SUCCESS: Unit & Style Tests
SUCCESS: Ubuntu LTS: Build
SUCCESS: Ubuntu LTS: Integration
SUCCESS: MAAS Compatability Testing
IN_PROGRESS: Declarative: Post Actions
Click here to trigger a rebuild: /jenkins. ubuntu. com/server/ job/cloud- init-ci/ 193/rebuild
https:/