Skip to content

Let ProjectsRootNode.getNodes(true) use the real keys - #9589

Merged
jtulach merged 1 commit into
apache:masterfrom
jtulach:jtulach/NestedProjects
Sep 2, 2026
Merged

Let ProjectsRootNode.getNodes(true) use the real keys#9589
jtulach merged 1 commit into
apache:masterfrom
jtulach:jtulach/NestedProjects

Conversation

@jtulach

@jtulach jtulach commented Aug 31, 2026

Copy link
Copy Markdown
Contributor

While writing a unit tests for ProjectsRootNode I realized that ProjectsRootNode.getNodes(true) violates the intended behavior. It should always wait for optimal result, but it doesn't not. The addNotify schedules setKeys called into a deferred RP task.... as such getChildren().getNodes(true) may return empty array while they should see the result of setKeys.

Modifying the code in getNodes(boolean optimalResult) to update the keys when optimalResult is requested. This alignes with ProjectsRootNode.getNodesCount which was already updating the keys with setKeys when optimal result was requested.

Prior to change in ProjectsRootNode.getNodes(boolean) my new unit tests (also part of this PR) were failing. Now they are reliably passing.

@jtulach

jtulach commented Sep 1, 2026

Copy link
Copy Markdown
Contributor Author

We are "green" with 4f91375. I'll squash and merge now.

@jtulach
jtulach force-pushed the jtulach/NestedProjects branch from 4f91375 to 139c3e0 Compare September 1, 2026 17:21
@jtulach jtulach added this to the NB32 milestone Sep 1, 2026
@jtulach
jtulach merged commit 20acfa9 into apache:master Sep 2, 2026
75 of 76 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci:all-tests [ci] enable all tests Project UI View

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants