My lsp server stopped working sometime ago after upgrading Dune, I couldn’t view or go to some type definitions. When I investigated further, I got this error:
The current Merlin configuration has been generated by another, incompatible, version of Dune. Please rebuild the project. (Using the same version of Dune as the one running the 'ocaml-merlin' server.)ocamllsp
The latest release of dune cannot build the current codebase, so as a quick fix, my mentor showed me a way to solve the issue temporarily and continue working. This was achieved by checking out to a stable point before the latest release:
38131cc8ce71dc86ab12a82d79212a3bdfc07bc4
Then creating a new branch from that branch, and rebasing my development branch unto the new branch created from the stable branch above. With this I am able to build the project and also view type definitions.
While this temporary fix works, it’s clearly not the best approach in the long run, please I need to know if there’s a better way or more permanent way I can fix this for future releases.
My development is on a mac with intel processor.