-
Notifications
You must be signed in to change notification settings - Fork 637
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
nextflow pull -r needs to be run twice to pull remote tag #4246
Comments
Hey @bentsherman, thanks for the patch on this. Is there a plan to merge 4247? |
Just waiting for @pditommaso to approve |
I was testing the associated PR, however I was not able to replicate the reported issue. This command works for me
What am I missing? |
You have to delete the tag from the git repo to force git to pull a remote tag separate from the initial clone, like pulling a new release. See the "steps to reproduce the problem" in the OP |
Bug report
Expected behavior
nextflow pull -r <tag>
checks out a new tag from the remote repository.Actual behavior
nextflow pull -r <tag>
yields the following error:Cannot find revision <tag> -- Make sure that it exists in the remote repository
nextflow pull -r <tag>
is successfulSteps to reproduce the problem
Environment
Additional context
Running Nextflow pull on an existing asset repo, triggers the following events:
git.checkout() .setName(revision) .call()
, which will fail because the repository has not been fetched yetcheckoutRemoteBranch(revision)
, triggered by the failure of the firstgit.checkout()
fetch.call()
, where the remote repository is now fetchedgit.checkout()
, which fails because it tries to specifically track an upstreamorigin/<revision>
branch (but revision is a tag)When running the command a second time, the repository is successfully updated by the first
git.checkout().setName(revision)
.Some initial thoughts on how to work around this:
checkoutRemoteBranch
,download
could attempt to checkout the revision as a tagThe text was updated successfully, but these errors were encountered: