You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've tried taking a look at ghcide, haskell-language-server and lsp repos and codebases to see which one might be responsible for dropping code lenses so quickly after typing, but didn't manage to find any clues.
Notice how "imports" lenses stay there, while signature suggestion ones are immediately dropped on typing. Maybe leaving "stale" lenses until new ones arrive would be a way to do it?
I suspect this is a known and old problem and everyone just disables that particular plugin and goes on. I've decided to create issue here, even though there's no code responsible for code lenses in this repo, because the issue is specific to vscode (and their "lenses above declarations" stand). If someone could describe some of the code parts or modules responsible for general code lens sending/updating or provide a guideline on "what" "where" and "why" I'd be happy to try to investigate.
Your environment
Which OS do you use: MacOS
Steps to reproduce
Have "insert signature" lens enabled
Write a snippet that would use that lens
Wait for lens to appear
Modify document
Expected behaviour
Vertical spacing allocated by code lenses stays there, enabling typing without redrawing file.
Actual behaviour
Editor lines are moved up and down after typing anything, as presented in attached screencast.
Debug info
Debug output:
No 'hie.yaml' found. Try to discover the project type!
Run entered for haskell-language-server-wrapper(haskell-language-server-wrapper) Version 1.6.1.0, Git revision f4022c5bb8530cd306c53b941878244bf27a5d41 (dirty) (51 commits) aarch64 ghc-8.10.7
Current directory: /Users/esgariot/Development/adventofcode2021/1
Operating system: darwin
Arguments: ["--debug","."]
Cradle directory: /Users/esgariot/Development/adventofcode2021/1
Cradle type: Default
Tool versions found on the $PATH
cabal: 3.6.2.0
stack: Not found
ghc: 8.10.7
Consulting the cradle to get project GHC version...
Project GHC version: 8.10.7
haskell-language-server exe candidates: ["haskell-language-server-8.10.7","haskell-language-server"]
Launching haskell-language-server exe at:/Users/esgariot/.local/bin/haskell-language-server-8.10.7
haskell-language-server version: 1.6.1.0 (GHC: 8.10.7) (PATH: /Users/esgariot/.local/bin/haskell-language-server-8.10.7~1.6.1.0) (GIT hash: f4022c5bb8530cd306c53b941878244bf27a5d41)
2022-04-19 12:33:12.497248 [ThreadId 4] INFO hls: Logging heap statistics every 60.00s
ghcide setup tester in /Users/esgariot/Development/adventofcode2021/1.
Report bugs at https://github.com/haskell/haskell-language-server/issues
Step 1/4: Finding files to test in /Users/esgariot/Development/adventofcode2021/1
Found 1 files
Step 2/4: Looking for hie.yaml files that control setup
Found 1 cradle
()
Step 3/4: Initializing the IDE
2022-04-19 12:33:12.500256 [ThreadId 8] DEBUG hls: Initializing exports map from hiedb
2022-04-19 12:33:12.500554 [ThreadId 8] DEBUG hls: Done initializing exports map from hiedb (6)
2022-04-19 12:33:12.500623 [ThreadId 4] DEBUG hls: Shake session initialized
Step 4/4: Type checking the files
2022-04-19 12:33:12.50102 [ThreadId 26] INFO hls: Consulting the cradle for "count.hs"
2022-04-19 12:33:12.501071 [ThreadId 26] WARNING hls: No [cradle](https://github.com/mpickering/hie-bios#hie-bios) found for count.hs.
Proceeding with [implicit cradle](https://hackage.haskell.org/package/implicit-hie).
You should ignore this message, unless you see a 'Multi Cradle: No prefixes matched' error.
2022-04-19 12:33:12.502616 [ThreadId 26] DEBUG hls: Output from setting up the cradle Cradle {cradleRootDir = "/Users/esgariot/Development/adventofcode2021/1", cradleOptsProg = CradleAction: Default}
2022-04-19 12:33:12.551714 [ThreadId 26] DEBUG hls: Session loading result: Right (ComponentOptions {componentOptions = [], componentRoot = "/Users/esgariot/Development/adventofcode2021/1", componentDependencies = []},"/Users/esgariot/.local/share/ghcup/ghc/8.10.7/lib/ghc-8.10.7")
2022-04-19 12:33:12.589135 [ThreadId 26] INFO hls: Using interface files cache dir: /Users/esgariot/.cache/ghcide/main-da39a3ee5e6b4b0d3255bfef95601890afd80709
2022-04-19 12:33:12.589259 [ThreadId 26] INFO hls: Making new HscEnv[main]
2022-04-19 12:33:12.592417 [ThreadId 26] DEBUG hls: New Component Cache HscEnvEq: (([],Just HscEnvEq 5),fromList [])
2022-04-19 12:33:12.592524 [ThreadId 26] DEBUG hls: Known files updated: fromList [(TargetFile NormalizedFilePath "/Users/esgariot/Development/adventofcode2021/1/count.hs",fromList ["/Users/esgariot/Development/adventofcode2021/1/count.hs"])]
2022-04-19 12:33:12.592623 [ThreadId 11] DEBUG hls: Finishing build session(exception: AsyncCancelled)
2022-04-19 12:33:12.592655 [ThreadId 26] DEBUG hls: Restarting build session due to new component with queue ["User TypeCheck"] for keys [GhcSessionIO; ,GetKnownTargets; ] (aborting the previous one took 0.00s)
2022-04-19 12:33:12.592798 [ThreadId 41] DEBUG hls: hlint:getIdeas:file:NormalizedFilePath "/Users/esgariot/Development/adventofcode2021/1/count.hs"
2022-04-19 12:33:12.699207 [ThreadId 48] INFO hls: finish: User TypeCheck (took 0.11s)
2022-04-19 12:33:12.702689 [ThreadId 99] INFO hls: finish: GetHie (took 0.00s)
2022-04-19 12:33:12.706783 [ThreadId 108] INFO hls: finish: GenerateCore (took 0.00s)
Completed (1 file worked, 0 files failed)
Paste the contents of extension specific log, you can check instructions about how to find it here
Hi, thank you for the bug report! Sorry, I missed this issue! However, this is a HLS bug and not the responsibility of vscode-haskell. Thus, I am moving this issue to the main rep.
Nagranie.z.ekranu.2022-04-19.o.12.09.10.mov
I've tried taking a look at
ghcide
,haskell-language-server
andlsp
repos and codebases to see which one might be responsible for dropping code lenses so quickly after typing, but didn't manage to find any clues.Notice how "imports" lenses stay there, while signature suggestion ones are immediately dropped on typing. Maybe leaving "stale" lenses until new ones arrive would be a way to do it?
I suspect this is a known and old problem and everyone just disables that particular plugin and goes on. I've decided to create issue here, even though there's no code responsible for code lenses in this repo, because the issue is specific to vscode (and their "lenses above declarations" stand). If someone could describe some of the code parts or modules responsible for general code lens sending/updating or provide a guideline on "what" "where" and "why" I'd be happy to try to investigate.
Your environment
Which OS do you use: MacOS
Steps to reproduce
Expected behaviour
Vertical spacing allocated by code lenses stays there, enabling typing without redrawing file.
Actual behaviour
Editor lines are moved up and down after typing anything, as presented in attached screencast.
Debug info
Debug output:
Paste the contents of extension specific log, you can check instructions about how to find it here
Extension log:
The text was updated successfully, but these errors were encountered: