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

Unexpected 'Project xxx has no explicit encoding set' warnings #2061

Merged
merged 1 commit into from
Apr 20, 2022

Conversation

snjeza
Copy link
Contributor

@snjeza snjeza commented Apr 18, 2022

@rgrunber
Copy link
Contributor

rgrunber commented Apr 20, 2022

Why can't we just set something like encoding/<project>=utf8 (as you described) or whichever is the default encoding, and then have the underlying Eclipse runtime (JDT-LS) silence the warning. Why do we need to ignore it ourselves ?

A client (eg. VS Code) could provide something like files.encoding and we would just have to ensure we set that on the LS side.

@snjeza
Copy link
Contributor Author

snjeza commented Apr 20, 2022

Why can't we just set something like encoding/=utf8 (as you described) or whichever is the default encoding, and then have the underlying Eclipse runtime (JDT-LS) silence the warning. Why do we need to ignore it ourselves ?

You can set

"java.project.encoding": "setDefault",

See redhat-developer/vscode-java@74ab5c4#diff-b335630551682c19a781afebcf4d07bf978fb1f8ac04c6bf87428ed5106870f5R204

Copy link
Contributor

@rgrunber rgrunber left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall, change is good. Just 1 small change, and I think we can merge.

Signed-off-by: Snjezana Peco <snjezana.peco@redhat.com>
@snjeza
Copy link
Contributor Author

snjeza commented Apr 20, 2022

test this please

@snjeza snjeza merged commit 50bc09d into eclipse-jdtls:master Apr 20, 2022
@rgrunber rgrunber added this to the Early May 2022 milestone Apr 20, 2022
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

Successfully merging this pull request may close these issues.

Unexpected 'Project xxx has no explicit encoding set' warnings
2 participants