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

Add check if WorkspaceFolders are supported or not #2801

Merged
merged 1 commit into from
Dec 8, 2023

Conversation

jnt0r
Copy link
Contributor

@jnt0r jnt0r commented Sep 12, 2023

fixes #2699
reopens #2700

@cdietrich cdietrich requested a review from szarnekow September 12, 2023 13:17
@cdietrich cdietrich added this to the Release_2.33 milestone Sep 12, 2023
initialize(initializer, callInitialized, false)
}

protected def InitializeResult initialize((InitializeParams)=>void initializer, boolean callInitialized, boolean useRootPath) {
val params = new InitializeParams => [
processId = 1
workspaceFolders = #[
new WorkspaceFolder(root.toURI.normalize.toUriString, '')
]
]
initializer?.apply(params)
Copy link
Contributor Author

Choose a reason for hiding this comment

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

@szarnekow when I move the initializer after the useRootPath if, the tests fail with NullPointers. I will have to take a look into this.

Copy link
Contributor

Choose a reason for hiding this comment

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

Did you figure why these failed when the order is swapped?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I'm getting closer and closer. But I'm having some problems getting the tests to run locally. Is there any guidance/documentation on how to get them running locally.

Copy link
Contributor

Choose a reason for hiding this comment

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

Which tests and what is the problem you are facing (maybe you have to select junit4 in the run dialog )

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The workspace was not setup correctly, but I don't know why. Everything was red and everything I tried didn't get it fixed. I now recreated the whole workspace with the eclipse installer and they are working again :)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@szarnekow The reason for the NullPointerExceptions were some test classes where the WorkspaceFolder capability was not setup correctly.

@jnt0r jnt0r requested a review from szarnekow November 8, 2023 19:58
@cdietrich
Copy link
Contributor

what is the state here.

@jnt0r can you please rebase and squash into 1 commit

@jnt0r jnt0r force-pushed the fork-main branch 2 times, most recently from 6fa8fcd to 707f31d Compare November 10, 2023 16:45
@cdietrich cdietrich modified the milestones: Release_2.33, Release_2.34 Nov 17, 2023
@jnt0r
Copy link
Contributor Author

jnt0r commented Dec 5, 2023

What's the state of this?

@szarnekow
Copy link
Contributor

What's the state of this?

Read through it and I like it. Can you please rebase your work and sign-off the commit?

Signed-off-by: Jonathan Pollert <jona.pollert@gmail.com>
@szarnekow szarnekow merged commit cf168df into eclipse-xtext:main Dec 8, 2023
5 checks passed
@szarnekow szarnekow added the bug label Dec 8, 2023
@jnt0r jnt0r deleted the fork-main branch December 9, 2023 19:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Incomplete check whether to use WorkspaceFolders or not?
3 participants