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

Change global lock only if format upgrade is performed #4612

Merged
merged 5 commits into from
Mar 30, 2021

Conversation

rjbou
Copy link
Collaborator

@rjbou rjbou commented Mar 24, 2021

The global lock is no more taken regarding opam root format upgrade needs. It is upgraded to the needed one (read ou write) according the kind of upgrade to perform (light/hard, on the fly or not), and released afterwards.

fix #4597

@rjbou rjbou added this to the 2.1.0~rc milestone Mar 24, 2021
@rjbou rjbou requested a review from AltGr March 24, 2021 18:42
@rjbou rjbou added this to PR in Progress in Opam 2.1.x via automation Mar 24, 2021
Copy link
Member

@dra27 dra27 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM - nice simpler test too!

Opam 2.1.x automation moved this from PR in Progress to PR Finalised Mar 25, 2021
@AltGr
Copy link
Member

AltGr commented Mar 30, 2021

Thanks, this indeed feels much better.
We still have one possible deadlock (in case of two concurrent hard upgrades), but that one was already there and is documented, with ~dontblock:true set to avoid it when non-interactive.

@rjbou rjbou merged commit 6b590ee into ocaml:master Mar 30, 2021
Opam 2.1.x automation moved this from PR Finalised to Done Mar 30, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Opam 2.1.x
  
Done
Development

Successfully merging this pull request may close these issues.

Compilation of some packages hanging!
3 participants