Skip to content
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

Broken if the initial opam-repository clone fails #86

Closed
AltGr opened this issue Jul 11, 2019 · 3 comments · Fixed by #140
Closed

Broken if the initial opam-repository clone fails #86

AltGr opened this issue Jul 11, 2019 · 3 comments · Fixed by #140

Comments

@AltGr
Copy link
Contributor

AltGr commented Jul 11, 2019

We only check if e.g. the dir ~/.opam/plugins/opam-publish/repos/ocaml%opam-repository exists before deciding wether to clone or update. It happened that the initial clone failed, but the directory still existed (without a proper .git).

Then all attempts would fail while trying to run git fetch in there. It would be nice to have better detection, or recover the git error to clone again from scratch.

Discovered by user @sanette on https://discuss.ocaml.org/t/best-way-to-publish-opam-package/4036/17 : thanks!

@DmxLarchey
Copy link

Hi @rjbou and @AltGr,

I have entered into this situation where /usr/bin/git fetch --multiple origin user is called (and fails) after an initial incomplete opam publish. Could you please tell me how do I reverse this situation?

@kit-ty-kate
Copy link
Contributor

@DmxLarchey as a quick fix rm -rf ~/.opam/plugins/opam-publish/repos/ocaml%opam-repository should work

@DmxLarchey
Copy link

@kit-ty-kate

Thank you very much. It worked !! And publishing now succeeded !!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants