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

Find references only working in the current document. Not working. Across the project. #3280

Open
kcpinnaka opened this issue Sep 22, 2024 · 0 comments

Comments

@kcpinnaka
Copy link

I'm using the following command to start the server
` command = [
"x:\jdk-17_windows-x64_bin\jdk-17.0.2\bin\java.exe",
"-Declipse.application=org.eclipse.jdt.ls.core.id1",
"-Dosgi.bundles.defaultStartLevel=4",
"-Declipse.product=org.eclipse.jdt.ls.core.product",
"-Dosgi.checkConfiguration=true",
r"-Dosgi.sharedConfiguration.area=x:\eclipse.jdt.lsNew\org.eclipse.jdt.ls.product\target\repository\config_win",
"-Dosgi.sharedConfiguration.area.readOnly=true",
"-Dosgi.configuration.cascaded=true",
"-noverify",
"-Xms1G",
f"-Djava.util.logging.config.file={log_config}",
"-Dlog.level=ALL",
"-jar",
r"x:\eclipse.jdt.lsNew\org.eclipse.jdt.ls.product\target\repository\plugins\org.eclipse.equinox.launcher_1.6.900.v20240613-2009.jar",
"-configuration",
r"x:\eclipse.jdt.lsNew\org.eclipse.jdt.ls.product\target\repository\config_win",
"-data",
path
]
def initialize(self):
params = {
"processId": None,
"rootUri": self.root_uri,
"capabilities": { "references": { "dynamicRegistration": True } }
}
return self.client.send_request_and_wait_for_response("initialize", params)

def find_references(self, file_uri, line, character):
    params = {
        "textDocument": {"uri": file_uri},
        "position": {"line": line, "character": character},
        "context": {"includeDeclaration": True}
    }
    return self.client.send_request_and_wait_for_response("textDocument/references", params)

`

Find references only working in the current document. Not working. Across the project.

However, when I run the project In Eclipse, PDE debugging mode on jdt.ls.socket-stream.launch,
I am able to see all references across the project.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant