Looks good, I just ask for a couple comments for the refs fetch and push, and a couple minor inline notes. Otherwise looks solid, some really good refactoring, and I'm looking forward to seeing the new notes feature in practice. I'm still a bit nervous that this will uncover warts in git, but maybe not, and in any case it feels like the right way to go technically.
If you agree with the comment suggestions, please go ahead and land after adding, no need for second round of review.
* Review
√ python3 setup.py build
√ python3 setup.py check
√ ./snap-wrappers/wrappers/git-ubuntu-self-test
No broken requirements found.
pip3 found all required dependencies
pylint passed!
PASS (syntax) source-package-walker.py
PASS (compilation) source-package-walker.py
PASS (syntax) update-repository-alias.py
PASS (compilation) update-repository-alias.py
PASS (syntax) import-source-packages.py
PASS (compilation) import-source-packages.py
332 passed, 3 xfailed in 187.90 seconds
! Per-patch code review
√ ef26b8a077b6ff3a8c455d38fc838dad4625df00
+ Die wrappers!
+ LGTM
√ 4bdd58db60bad113b1eb6a87621554f8f8bedef6
+ Pythonic objects FTW
+ LGTM
√ 69bc94052dbd1793fce7f4f9f32b76cb2c8f3b98
+ Verified the promised skip of test_get_import_commit_msg() is
indeed dropped in 061371a7 (next patch).
+ LGTM
√ 061371a77089930b27a261ff0447ba60d517fa82
+ This is the key patch in the set. Moves change info from the
commit message into the git note.
+ add_changelog_note_to_commit() is added, and has corresponding
test cases test_add_changelog_note_to_commit() and test_double_changelog_note_add_does_not_fail()
+ Uses the new gitubuntu.spec module
+ LGTM
√ 224684300a41a929492f981c453a3f71d77175d6
+ Largely cleanup/refactor from prior commit. Uses patch_state.
+ LGTM, nice cleanup
√ 9323899deab7a1d57e3c0ac9f92a47f552602502
+ Verified all call points are updated with correct argument list.
+ LGTM
√ 37ea80888ea65deaeeb509e3624e2a0f6b92d61c
+ Verified no consumers for _commit_import() other than importer.py, and all
call points are updated with correct argument list.
+ LGTM
! a133d0da5316cedf72c220649ffa8691057a3c2c
+ If I understand the refspecs properly, then the fetch with this
refspec: 'refs/notes/commits:refs/notes/usd-import-team/changelog'
will import the notes from 'refs/notes/commits' in the remote
repository, into 'refs/notes/usd-import-team/changelog' in the
local checkout. Then later, there is a repo.git_run() call that
pushes them back in the opposite direction.
+ The commit message explains this sufficiently, but the _main_with_repo() itself is lengthy (250+ lines!) and only
lightly commented, so this notes pushing/pulling feature may not
be clear to future readers. This would be a good opportunity to
add a comment each for the repo.fetch_remote_refspecs() and
git_run() calls, to define the refspec's being fetched and
pulled. Hopefully over time this routine can be whittled down,
and these comments will eventually turn into proper codedocs
somewhere.
+ The commit message suggests this is a workaround to a limitation
in Launchpad that is anticipated to be fixed. If this is the
case please also include:
• Link to the relevant LP bug or discussion in commit msg
• Comment in the code to flag when the refs/notes/commits can be
dropped
• Bug report against usd-importer to follow up on the tech debt
√ b0319c9f18629d6548988ac93ea9d98f1f4a5bf2
+ LGTM
√ 49d62ab97b7107abfb3dc2a993b50a74cf79215b
+ LGTM
Looks good, I just ask for a couple comments for the refs fetch and push, and a couple minor inline notes. Otherwise looks solid, some really good refactoring, and I'm looking forward to seeing the new notes feature in practice. I'm still a bit nervous that this will uncover warts in git, but maybe not, and in any case it feels like the right way to go technically.
If you agree with the comment suggestions, please go ahead and land after adding, no need for second round of review.
* Review wrappers/ wrappers/ git-ubuntu- self-test package- walker. py package- walker. py repository- alias.py repository- alias.py source- packages. py source- packages. py a8c455d38fc838d ad4625df00 3b1eb6a87621554 f8f8bedef6 3fce7f4f9f32b76 cb2c8f3b98 import_ commit_ msg() is b27a261ff0447ba 60d517fa82 note_to_ commit( ) is added, and has corresponding changelog_ note_to_ commit( ) and
test_double_ changelog_ note_add_ does_not_ fail() 9492f981c453a3f 71d77175d6 57e3c0ac9f92a47 f552602502 aeeb509e3624e2a 0f6b92d61c f72c220649ffa86 91057a3c2c
'refs/ notes/commits: refs/notes/ usd-import- team/changelog' commits' in the remote usd-import- team/changelog' in the
_main_ with_repo( ) itself is lengthy (250+ lines!) and only remote_ refspecs( ) and 548988ac93ea9d9 8f1f4a5bf2 bfb3dc2a993b50a 74cf79215b
√ python3 setup.py build
√ python3 setup.py check
√ ./snap-
No broken requirements found.
pip3 found all required dependencies
pylint passed!
PASS (syntax) source-
PASS (compilation) source-
PASS (syntax) update-
PASS (compilation) update-
PASS (syntax) import-
PASS (compilation) import-
332 passed, 3 xfailed in 187.90 seconds
! Per-patch code review
√ ef26b8a077b6ff3
+ Die wrappers!
+ LGTM
√ 4bdd58db60bad11
+ Pythonic objects FTW
+ LGTM
√ 69bc94052dbd179
+ Verified the promised skip of test_get_
indeed dropped in 061371a7 (next patch).
+ LGTM
√ 061371a77089930
+ This is the key patch in the set. Moves change info from the
commit message into the git note.
+ add_changelog_
test cases test_add_
+ Uses the new gitubuntu.spec module
+ LGTM
√ 224684300a41a92
+ Largely cleanup/refactor from prior commit. Uses patch_state.
+ LGTM, nice cleanup
√ 9323899deab7a1d
+ Verified all call points are updated with correct argument list.
+ LGTM
√ 37ea80888ea65de
+ Verified no consumers for _commit_import() other than importer.py, and all
call points are updated with correct argument list.
+ LGTM
! a133d0da5316ced
+ If I understand the refspecs properly, then the fetch with this
refspec:
will import the notes from 'refs/notes/
repository, into 'refs/notes/
local checkout. Then later, there is a repo.git_run() call that
pushes them back in the opposite direction.
+ The commit message explains this sufficiently, but the
lightly commented, so this notes pushing/pulling feature may not
be clear to future readers. This would be a good opportunity to
add a comment each for the repo.fetch_
git_run() calls, to define the refspec's being fetched and
pulled. Hopefully over time this routine can be whittled down,
and these comments will eventually turn into proper codedocs
somewhere.
+ The commit message suggests this is a workaround to a limitation
in Launchpad that is anticipated to be fixed. If this is the
case please also include:
• Link to the relevant LP bug or discussion in commit msg
• Comment in the code to flag when the refs/notes/commits can be
dropped
• Bug report against usd-importer to follow up on the tech debt
√ b0319c9f18629d6
+ LGTM
√ 49d62ab97b7107a
+ LGTM