refactor main functions
Bug #1707321 reported by
Nish Aravamudan
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
git-ubuntu |
Fix Released
|
Undecided
|
Nish Aravamudan |
Bug Description
Across all the source, we should refactor the subcommand::main functions, so they the subcommands can be called for testing (and re-use) rather than only via __main__. This will involve:
1) create internal functions that take the expected arguments as keywords, with relevant defaults?
2) main() simply takes the args, grabs the ones to pass to the function created in 1) and calls it.
Related branches
~nacc/git-ubuntu:refactor-main-v2
- Server Team CI bot: Approve (continuous-integration)
- Andreas Hasenack: Approve
- Robie Basak: Pending requested
-
Diff: 8236 lines (+4156/-3550)13 files modifiedgitubuntu/__main__.py (+139/-99)
gitubuntu/build.py (+127/-117)
gitubuntu/buildsource.py (+55/-59)
gitubuntu/clone.py (+136/-105)
gitubuntu/importer.py (+1389/-1178)
gitubuntu/importlocal.py (+312/-260)
gitubuntu/importppa.py (+227/-175)
gitubuntu/lint.py (+570/-532)
gitubuntu/merge.py (+423/-355)
gitubuntu/queue.py (+299/-281)
gitubuntu/remote.py (+158/-100)
gitubuntu/submit.py (+189/-176)
gitubuntu/tag.py (+132/-113)
~nacc/git-ubuntu:refactor-main-v2
Superseded
for merging
into
git-ubuntu:master
- Server Team CI bot: Pending (continuous-integration) requested
- Andreas Hasenack: Pending requested
- Robie Basak: Pending requested
-
Diff: 8140 lines (+4083/-3539)13 files modifiedgitubuntu/__main__.py (+114/-99)
gitubuntu/build.py (+127/-117)
gitubuntu/buildsource.py (+55/-59)
gitubuntu/clone.py (+107/-105)
gitubuntu/importer.py (+1389/-1178)
gitubuntu/importlocal.py (+312/-260)
gitubuntu/importppa.py (+256/-175)
gitubuntu/lint.py (+560/-524)
gitubuntu/merge.py (+423/-355)
gitubuntu/queue.py (+299/-281)
gitubuntu/remote.py (+120/-97)
gitubuntu/submit.py (+189/-176)
gitubuntu/tag.py (+132/-113)
~nacc/git-ubuntu:refactor-main-v2
Superseded
for merging
into
git-ubuntu:master
- Server Team CI bot: Approve (continuous-integration)
- Robie Basak: Pending requested
- Andreas Hasenack: Pending requested
-
Diff: 8131 lines (+4074/-3539)13 files modifiedgitubuntu/__main__.py (+105/-99)
gitubuntu/build.py (+127/-117)
gitubuntu/buildsource.py (+55/-59)
gitubuntu/clone.py (+107/-105)
gitubuntu/importer.py (+1389/-1178)
gitubuntu/importlocal.py (+312/-260)
gitubuntu/importppa.py (+256/-175)
gitubuntu/lint.py (+560/-524)
gitubuntu/merge.py (+423/-355)
gitubuntu/queue.py (+299/-281)
gitubuntu/remote.py (+120/-97)
gitubuntu/submit.py (+189/-176)
gitubuntu/tag.py (+132/-113)
~nacc/git-ubuntu:gu-review
Superseded
for merging
into
git-ubuntu:master
- Server Team CI bot: Needs Fixing (continuous-integration)
- Andreas Hasenack: Pending requested
- Robie Basak: Pending requested
-
Diff: 447 lines (+252/-37)5 files modifiedgitubuntu/__main__.py (+43/-7)
gitubuntu/clone.py (+34/-7)
gitubuntu/lint.py (+22/-8)
gitubuntu/remote.py (+50/-15)
gitubuntu/review.py (+103/-0)
~nacc/git-ubuntu:refactor-main-v2
Superseded
for merging
into
git-ubuntu:master
- Server Team CI bot: Needs Fixing (continuous-integration)
- Andreas Hasenack: Pending requested
- Robie Basak: Pending requested
-
Diff: 8131 lines (+4074/-3539)13 files modifiedgitubuntu/__main__.py (+105/-99)
gitubuntu/build.py (+127/-117)
gitubuntu/buildsource.py (+55/-59)
gitubuntu/clone.py (+107/-105)
gitubuntu/importer.py (+1389/-1178)
gitubuntu/importlocal.py (+312/-260)
gitubuntu/importppa.py (+256/-175)
gitubuntu/lint.py (+560/-524)
gitubuntu/merge.py (+423/-355)
gitubuntu/queue.py (+299/-281)
gitubuntu/remote.py (+120/-97)
gitubuntu/submit.py (+189/-176)
gitubuntu/tag.py (+132/-113)
~nacc/git-ubuntu:gu-review
Superseded
for merging
into
git-ubuntu:master
- Server Team CI bot: Needs Fixing (continuous-integration)
- Andreas Hasenack: Pending requested
- Robie Basak: Pending requested
-
Diff: 453 lines (+247/-41)5 files modifiedgitubuntu/__main__.py (+38/-11)
gitubuntu/clone.py (+34/-7)
gitubuntu/lint.py (+22/-8)
gitubuntu/remote.py (+50/-15)
gitubuntu/review.py (+103/-0)
~nacc/git-ubuntu:refactor-main-v2
Superseded
for merging
into
git-ubuntu:master
- Server Team CI bot: Needs Fixing (continuous-integration)
- Andreas Hasenack: Pending requested
- Robie Basak: Pending requested
-
Diff: 8300 lines (+4121/-3559)17 files modifiedbin/git-ubuntu (+1/-1)
bin/import-cron (+1/-1)
bin/snap/snap-git-ubuntu (+1/-0)
gitubuntu/__main__.py (+141/-124)
gitubuntu/build.py (+132/-129)
gitubuntu/buildsource.py (+55/-59)
gitubuntu/clone.py (+107/-105)
gitubuntu/importer.py (+1388/-1176)
gitubuntu/importlocal.py (+312/-260)
gitubuntu/importppa.py (+256/-175)
gitubuntu/lint.py (+548/-509)
gitubuntu/merge.py (+423/-355)
gitubuntu/queue.py (+299/-281)
gitubuntu/remote.py (+120/-97)
gitubuntu/source_information.py (+15/-0)
gitubuntu/submit.py (+190/-174)
gitubuntu/tag.py (+132/-113)
~nacc/git-ubuntu:gu-review
Superseded
for merging
into
git-ubuntu:master
- Robie Basak: Needs Fixing
-
Diff: 8362 lines (+4219/-3553)15 files modifiedgitubuntu/__main__.py (+142/-123)
gitubuntu/build.py (+132/-129)
gitubuntu/buildsource.py (+55/-59)
gitubuntu/clone.py (+109/-105)
gitubuntu/importer.py (+1388/-1176)
gitubuntu/importlocal.py (+312/-260)
gitubuntu/importppa.py (+256/-175)
gitubuntu/lint.py (+529/-506)
gitubuntu/merge.py (+423/-355)
gitubuntu/queue.py (+299/-281)
gitubuntu/remote.py (+120/-97)
gitubuntu/review.py (+117/-0)
gitubuntu/source_information.py (+15/-0)
gitubuntu/submit.py (+190/-174)
gitubuntu/tag.py (+132/-113)
Changed in usd-importer: | |
status: | New → Confirmed |
milestone: | none → 1.0 |
Changed in usd-importer: | |
status: | Confirmed → Triaged |
Changed in usd-importer: | |
status: | Triaged → In Progress |
assignee: | nobody → Nish Aravamudan (nacc) |
status: | In Progress → Triaged |
Changed in usd-importer: | |
status: | Triaged → In Progress |
Changed in usd-importer: | |
status: | In Progress → Fix Released |
To post a comment you must log in.