Skip to content
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

Autocompletion not working as expected in multiple places #1584

Open
lengors opened this issue Aug 15, 2024 · 1 comment
Open

Autocompletion not working as expected in multiple places #1584

lengors opened this issue Aug 15, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@lengors
Copy link

lengors commented Aug 15, 2024

Extension Name: vscode-gradle
Extension Version:v 3.16.4
OS Version: Windows 11
VSCode version: 1.92.1

Describe the bug
I don't get autocomplete for my gradle build files (including settings file) in many situations including, but not limited to:

  • no suggestions inside action passed to toolchain inside java closure
  • implementation and testImplementation inside dependencies aren't suggested
  • version after string with plugin name isn't suggested
  • useJUnitPlatform isn't suggested

To Reproduce
Create gradle project (can be through VSCode or gradle init, doesn't matter) and select option to generate either a lib or an app with groovy dsl.
That's it, the lack of proper autocompletion is evident right after start editing the build.gradle file.

Expected behavior
Suggestions in all of the above scenarios to be displayed for proper autocompletion behavior.

Output from "Gradle for Java"

[info] [gradle-server] Gradle Server started, listening on 59729
[info] Gradle client connected to server
[info] Java Home: C:\Users\<user>\.vscode\extensions\redhat.java-1.33.0-win32-x64\jre\17.0.11-win32-x86_64
[info] JVM Args: --add-opens=java.base/java.util=ALL-UNNAMED,--add-opens=java.base/java.lang=ALL-UNNAMED,--add-opens=java.base/java.lang.invoke=ALL-UNNAMED,--add-opens=java.prefs/java.util.prefs=ALL-UNNAMED,--add-opens=java.base/java.nio.charset=ALL-UNNAMED,--add-opens=java.base/java.net=ALL-UNNAMED,--add-opens=java.base/java.util.concurrent.atomic=ALL-UNNAMED,-XX:MaxMetaspaceSize=384m,-XX:+HeapDumpOnOutOfMemoryError,-Xms256m,-Xmx512m,-Dfile.encoding=UTF-8,-Duser.country=GB,-Duser.language=en,-Duser.variant
[info] Gradle User Home: C:\Users\<user>\.gradle
[info] Gradle Version: 8.6
[info] Deprecated Gradle features were used in this build, making it incompatible with Gradle 9.0.

You can use '--warning-mode all' to show the individual deprecation warnings and determine if they come from your own scripts or plugins.

For more on this, please refer to https://docs.gradle.org/8.6/userguide/command_line_interface.html#sec:command_line_warnings in the Gradle documentation.

CONFIGURE SUCCESSFUL in 4s
[info] Found 31 tasks
[info] [gradle-server] ago. 16, 2024 12:08:38 DA MANHÃ org.eclipse.lsp4j.jsonrpc.RemoteEndpoint handleCancellation
WARNING: Unmatched cancel notification for request id 24
[info] [gradle-server] ago. 16, 2024 12:08:46 DA MANHÃ org.eclipse.lsp4j.jsonrpc.RemoteEndpoint handleCancellation
WARNING: Unmatched cancel notification for request id 36
[info] Build file changed: c:\Users\<user>\Documents\Projects\test-gradle-vscode-cmd\build.gradle
[info] Java Home: C:\Users\<user>\.vscode\extensions\redhat.java-1.33.0-win32-x64\jre\17.0.11-win32-x86_64
[info] JVM Args: --add-opens=java.base/java.util=ALL-UNNAMED,--add-opens=java.base/java.lang=ALL-UNNAMED,--add-opens=java.base/java.lang.invoke=ALL-UNNAMED,--add-opens=java.prefs/java.util.prefs=ALL-UNNAMED,--add-opens=java.base/java.nio.charset=ALL-UNNAMED,--add-opens=java.base/java.net=ALL-UNNAMED,--add-opens=java.base/java.util.concurrent.atomic=ALL-UNNAMED,-XX:MaxMetaspaceSize=384m,-XX:+HeapDumpOnOutOfMemoryError,-Xms256m,-Xmx512m,-Dfile.encoding=UTF-8,-Duser.country=GB,-Duser.language=en,-Duser.variant
[info] Gradle User Home: C:\Users\<user>\.gradle
[info] Gradle Version: 8.6
[info] Deprecated Gradle features were used in this build, making it incompatible with Gradle 9.0.

You can use '--warning-mode all' to show the individual deprecation warnings and determine if they come from your own scripts or plugins.

For more on this, please refer to https://docs.gradle.org/8.6/userguide/command_line_interface.html#sec:command_line_warnings in the Gradle documentation.

CONFIGURE SUCCESSFUL in 83ms
[info] Found 31 tasks

Does the bug still exist if you disable all other extensions?
Yes

@lengors lengors added the bug Something isn't working label Aug 15, 2024
@mamilic
Copy link
Contributor

mamilic commented Aug 16, 2024

I am expreiencing the same issues. @jdneo , you can try to reproduce issues with this project.
demo.zip

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants