haskell / haskell-language-server

Official haskell ide support via language server (LSP). Successor of ghcide & haskell-ide-engine.
Apache License 2.0
2.71k stars 368 forks source link

Jumping to definition in beam-core from beam-sqlite results in errors. #3442

Closed amano-kenji closed 5 months ago

amano-kenji commented 1 year ago

Your environment

Which OS do you use? Gentoo Linux

Which version of GHC do you use and how did you install it? 9.0.2 from Gentoo Linux

How is your project built (alternative: link to the project)? https://github.com/haskell-beam/beam

Which LSP client (editor/plugin) do you use? nvim-lspconfig

Which version of HLS do you use and how did you install it? 1.9.0.0 from Gentoo Linux

Have you configured HLS in any way (especially: a hie.yaml file)? hie.yaml

cradle:
  cabal:

Steps to reproduce

Expected behaviour

No error

Actual behaviour

Diagnostics:
1. • No instance for (Database.Beam.Backend.SQL.SQL92.IsSql92TableNameSyntax
                        SqliteTableNameSyntax)
       arising from the superclasses of an instance declaration
   • In the instance declaration for
       ‘IsSql92DropTableSyntax SqliteDropTableSyntax’

and various other errors.

I can avoid the error by visiting beam-migrate from beam-sqlite before visiting beam-core from beam-sqlite. If I visited beam-core from beam-sqlite, then the errors can be eliminated by visiting beam-migrate from beam-sqlite.

fendor commented 1 year ago

This is caused by our custom support for multiple home units and might be fixed eventually if #3502 together with some other PRs lands.

michaelpj commented 5 months ago

This should be fixed with the new multi-component support.