-
Notifications
You must be signed in to change notification settings - Fork 97
Extend import suggestions for more than one option #913
Extend import suggestions for more than one option #913
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the fix! I have been annoyed by this bug quite a few times.
Some minor changes needed before merging it
Question: I get different results from calling
Note the |
That's what the call to |
Nope. I have that whole piece of code intact.
|
I ran the same command and printed out the diagnostics. Does this add any clue? The diagnostics returns with
Same command, run immediately but successful this time:
It turns out that the first case is the expected behavior since, there was a parsed error in the input I was feeding the Here is the input which is the cause of the parser error:
|
Please take a look at the LSP transport messages to get a better understanding of the issue |
* Add support for extending import list when multiple options are available * Add function to module export list to make it available for testing * Fix typo * Add doc strings * Add tests for testing regex used to parse multiple choices for import suggestions. * Add test group * Remove trailing spaces * Hlint suggestions * Remove not used variable * Remove temporary code * Reuse matchRegExUnifySpaces * Fix test input. * Use testCase instead of testSession * Update extend import tests to assert on multiple actions. * Extend extendImports to use multiple modules for setup * Hlint changes
* Add support for extending import list when multiple options are available * Add function to module export list to make it available for testing * Fix typo * Add doc strings * Add tests for testing regex used to parse multiple choices for import suggestions. * Add test group * Remove trailing spaces * Hlint suggestions * Remove not used variable * Remove temporary code * Reuse matchRegExUnifySpaces * Fix test input. * Use testCase instead of testSession * Update extend import tests to assert on multiple actions. * Extend extendImports to use multiple modules for setup * Hlint changes
* Add support for extending import list when multiple options are available * Add function to module export list to make it available for testing * Fix typo * Add doc strings * Add tests for testing regex used to parse multiple choices for import suggestions. * Add test group * Remove trailing spaces * Hlint suggestions * Remove not used variable * Remove temporary code * Reuse matchRegExUnifySpaces * Fix test input. * Use testCase instead of testSession * Update extend import tests to assert on multiple actions. * Extend extendImports to use multiple modules for setup * Hlint changes
* Add support for extending import list when multiple options are available * Add function to module export list to make it available for testing * Fix typo * Add doc strings * Add tests for testing regex used to parse multiple choices for import suggestions. * Add test group * Remove trailing spaces * Hlint suggestions * Remove not used variable * Remove temporary code * Reuse matchRegExUnifySpaces * Fix test input. * Use testCase instead of testSession * Update extend import tests to assert on multiple actions. * Extend extendImports to use multiple modules for setup * Hlint changes
Fixes #792.