gto
gto copied to clipboard
`assign` should fail when `--stage` is not provided
If you don't provide --stage arg, this should fail but produce the incorrect tag:
$ gto assign bugfixed --auto-push
Created git tag '[email protected]' that registers version
Running `git push origin [email protected]`
Successfully pushed git tag [email protected] to the remote.
Created git tag 'bugfixed#None#1' that assigns stage to version 'v0.0.1'
Running `git push origin bugfixed#None#1`
Successfully pushed git tag bugfixed#None#1 to the remote.
❌ Cannot parse tag name 'bugfixed#None#1'
Hey @aguschin i would like to work on this pls assign it to me
Sure! Please ping me in case you need any details :) In the nutshell, it should be something like this:
$ gto assign bugfixed --auto-push
❌ `stage` must be provided
>>> gto.api.assign(..., stage=None)
WrongArgs: `stage` can't be None
We can just raise WrongArgs("stage can't be None"), and running the CLI command would issue the same message. It is fine, I assume.