Skip to content

Conversation

@archana-1924
Copy link
Contributor

The PR addresses Issue: eclipse-lsp4jakarta/lsp4jakarta#520
Root causes were observed in JavaCursorContextKind.java files in

  • lsp4jakarta.ls
  • lsp4jakarta.jdt

@angelozerr
Copy link
Contributor

Thanks @archana-1924.

This code follows the same idea than other LSP4J enumeration, see https://github.com/search?q=repo%3Aeclipse-lsp4j%2Flsp4j%20forValue&type=code

I think we should keep simple code and avoid hard coding some specific values.

The fix should be just:

NONE(10);

@archana-1924 archana-1924 changed the title Addresses fix #520: JavaCursorContextKind IllegalArgumentException in lsp4mp Addresses fix 520: JavaCursorContextKind IllegalArgumentException in lsp4mp Jul 30, 2025
@archana-1924 archana-1924 changed the title Addresses fix 520: JavaCursorContextKind IllegalArgumentException in lsp4mp Addresses fix https://github.com/eclipse-lsp4jakarta/lsp4jakarta/issues/520: JavaCursorContextKind IllegalArgumentException in lsp4mp Jul 30, 2025
@archana-1924 archana-1924 changed the title Addresses fix https://github.com/eclipse-lsp4jakarta/lsp4jakarta/issues/520: JavaCursorContextKind IllegalArgumentException in lsp4mp Addresses fix #520: JavaCursorContextKind IllegalArgumentException in lsp4mp Jul 30, 2025
@archana-1924
Copy link
Contributor Author

archana-1924 commented Jul 30, 2025

Thanks @archana-1924.

This code follows the same idea than other LSP4J enumeration, see https://github.com/search?q=repo%3Aeclipse-lsp4j%2Flsp4j%20forValue&type=code

I think we should keep simple code and avoid hard coding some specific values.

The fix should be just:

NONE(10);

Just an FYI, if we're changing the enum value as such, we might have to handle this fix in liberty tools, which were depended on this. CC: @turkeylurkey

@turkeylurkey
Copy link
Contributor

@archana-1924 I agree, also some code in liberty tools treats this ls and the jakarta ls the same so we likely need to make this change in jakarta.

@angelozerr angelozerr merged commit ac12f78 into eclipse-lsp4mp:master Jul 30, 2025
1 of 4 checks passed
@angelozerr
Copy link
Contributor

Thanks @archana-1924 !

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

Successfully merging this pull request may close these issues.

3 participants