-
Notifications
You must be signed in to change notification settings - Fork 83
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Require the Bitbucket Server URL, project and repo name to always be passed for bbs2gh migrate-repo
#1057
Require the Bitbucket Server URL, project and repo name to always be passed for bbs2gh migrate-repo
#1057
Conversation
@@ -283,44 +283,6 @@ public void Errors_If_BbsServer_Url_Not_Provided_But_Smb_User_Is_Provided() | |||
.WithMessage("*SSH*SMB*--bbs-server-url*"); | |||
} | |||
|
|||
[Fact] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We now validate in the Args
class that all 3 arguments are always provided
I've tested all three flows (end-to-end + upload-and-import + import-only) after this change, and they all behave as expected. |
Docs changes in https://github.com/github/docs-internal/pull/38838 |
Did you consider doing a 2-phase implementation (like we have done for other breaking changes). Where we first make those arguments optional when using Then at some point in the future come back and make them required. |
I did consider it - but I feel like a more decisive approach is fair game during a limited private beta that is heading to public beta in the near future. It's easy for me to contact affected users, so I thought a more immediate change made sense to fix what is a pretty nasty bug. But I will think more on this over the weekend! Thanks for raising it. |
b44455f
to
70af1ce
Compare
…passed for `bbs2gh migrate-repo` This makes a breaking change to `bbs2gh migrate-repo` requiring the `--bbs-server-url`, `--bbs-project` and `--bbs-repo` to always be passed, even in the flows where the CLI doesn't talk to the Bitbucket Server API. This change is important because it allows us to always sent the URL of the repository to the GitHub API when starting the migration, which allows us to intelligently pick the right repo to migrate from the archive. Fixes #1056.
345a9c9
to
45c7787
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
This makes a breaking change to
bbs2gh migrate-repo
requiring the--bbs-server-url
,--bbs-project
and--bbs-repo
to always be passed, even in the flows where the CLI doesn't talk to the Bitbucket Server API.This change allows us to always construct the URL of the repository and then send it to the GitHub API when starting the migration.
That's important, because the URL allows us to intelligently pick the right repo to migrate from the archive, rather than picking the "first" repo in the fork hierarchy (which may be wrong!).
I did consider introducing a warning first and then making a breaking change, but I thought going straight to a breaking change was the right decision because:
Fixes #1056.
ThirdPartyNotices.txt
(if applicable)