Manifest: Don't hard pin LSP to an OCaml version
What
Relaxes a hard constraint on ocaml-lsp to allow us to use make build-dev-deps when upgrading to a new compiler (introduced in !16071 (merged))
Why
Currently, ocaml-lsp is set to 1.20.1-4.14 meaning that if we want to upgrade the compiler to another version than 4.14, this hard constraint will fail.
How
By setting ocaml-lsp >= 1.20.1
Manually testing the MR
You can test it by removing the HEAD, rebasing on ocaml5 and trying make build-dev-deps, you should have the following:
❯ opam list | grep ocaml-base
ocaml-base-compiler 4.14.2 Official release 4.14.2
❯ git rebase -i ocaml5
Successfully rebased and updated refs/heads/master.
❯ make build-dev-deps
Use opam repository commit: e566c29b12a9c284b68b3f6cbe7fbd4e8452406f
...
Done.
[ERROR] Package conflict!
* No agreement on the version of ocaml:
- (invariant) → ocaml-base-compiler = 5.2.1 → ocaml = 5.2.1
- deps-of-octez-dev-deps → ocaml-lsp-server >= 1.20.1-4.14 → ocaml < 5.0
You can temporarily relax the switch invariant with `--update-invariant'
* No agreement on the version of ocaml-base-compiler:
- (invariant) → ocaml-base-compiler = 5.2.1
- deps-of-octez-dev-deps → ocaml-lsp-server >= 1.20.1-4.14 → ocaml < 5.0 → ocaml-base-compiler < 4.14.3~
* Incompatible packages:
- (invariant) → ocaml-base-compiler = 5.2.1
- deps-of-octez-dev-deps → ocaml-lsp-server >= 1.20.1-4.14 → ocaml < 5.0 → dkml-base-compiler
* Incompatible packages:
- (invariant) → ocaml-base-compiler = 5.2.1
- deps-of-octez-dev-deps → ocaml-lsp-server >= 1.20.1-4.14 → ocaml < 5.0 → ocaml-variants >= 3.10.0
* Missing dependency:
- deps-of-octez-dev-deps → ocaml-lsp-server >= 1.20.1-4.14 → ocaml < 5.0 → ocaml-variants >= 3.10.0 → ocaml-beta
unmet availability conditions: 'enable-ocaml-beta-repository'
* Missing dependency:
- deps-of-octez-dev-deps → ocaml-lsp-server >= 1.20.1-4.14 → ocaml < 5.0 → ocaml-variants >= 3.10.0 → system-msvc
unmet availability conditions: 'os = "win32"'
With this MR:
❯ opam list | grep ocaml-base
ocaml-base-compiler 4.14.2 Official release 4.14.2
❯ git rebase -i ocaml5
Successfully rebased and updated refs/heads/master.
❯ make build-dev-deps
Use opam repository commit: e566c29b12a9c284b68b3f6cbe7fbd4e8452406f
...
The following actions will be performed:
=== install 3 packages
∗ dune-rpc 3.16.1 [required by ocaml-lsp-server]
∗ ocaml-lsp-server 1.20.1 [required by octez-dev-deps]
∗ ocamlc-loc 3.16.1 [required by ocaml-lsp-server]
<><> Processing actions <><><><><><><><><><><><><><><><><><><><><><><><><><><><>
⬇ retrieved ocaml-lsp-server.1.20.1 (cached)
⬇ retrieved dune-rpc.3.16.1, ocamlc-loc.3.16.1 (cached)
∗ installed ocamlc-loc.3.16.1
∗ installed dune-rpc.3.16.1
∗ installed ocaml-lsp-server.1.20.1
Done.
Checklist
-
Document the interface of any function added or modified (see the coding guidelines) -
Document any change to the user interface, including configuration parameters (see node configuration) -
Provide automatic testing (see the testing guide). -
For new features and bug fixes, add an item in the appropriate changelog ( docs/protocols/alpha.rstfor the protocol and the environment,CHANGES.rstat the root of the repository for everything else). -
Select suitable reviewers using the Reviewersfield below. -
Select as Assigneethe next person who should take action on that MR