-
Notifications
You must be signed in to change notification settings - Fork 360
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
No suggestions in VSCode #4345
Comments
I'm not able to reproduce this on linux. I don't know why there would be issues specific to windows for this. I see the exact same response contents as the request contents - are you sure that's the right message body for the response? It's identical to the completion request; there should be a JSON array or null somewhere in the response. What happens if you clone phan, run Did you disable or uninstall other php language servers such as intelliphense - those may or may not interfere (haven't tried that - it's more of an issue for hover types)
|
|
I can reproduce the unit test failure and overall slowness (and the test failure) if I run
(Running it on tests/misc/lsp/ for other files didn't have any impact) So it may somehow be an issue specific to completions when the character following the cursor is A simpler way to reproduce this than running unix2dos is this patch (for which tests on Linux fail quickly (< 2 seconds each), and tests on Windows surprisingly fail slowly): --- a/tests/Phan/LanguageServer/LanguageServerIntegrationTest.php
+++ b/tests/Phan/LanguageServer/LanguageServerIntegrationTest.php
@@ -1966,6 +1966,7 @@ EOT;
*/
private static function writeDidChangeNotificationToFile($proc_in, string $requested_uri, string $new_contents): void
{
+ $new_contents = \str_replace("\n", "\r\n", $new_contents);
$params = [
'textDocument' => ['uri' => $requested_uri],
'contentChanges' => [
|
This should be fixed in version 3.0.0 of the vscode extension (by default, it uses an installation of Phan bundled with that extension, not the phan version installed in the project) and in version 4.0.2 of Phan |
The analysis works correctly but the I don't know why the autocompletion does not work. Other functions like
go to declaration
does not work either.Phan 4.0.1
php-ast version 1.0.10
PHP version used to run Phan: 7.4.7
VSCode Extension: 2.2.0
./.phan/config.php
./src/index.php
The text was updated successfully, but these errors were encountered: