sjhajharia opened a new pull request, #20225: URL: https://github.com/apache/kafka/pull/20225
### Problem The `ShareGroupCommandTest.testDeleteShareGroupOffsetsArgsWithoutTopic()` and `ShareGroupCommandTest.testDeleteShareGroupOffsetsArgsWithoutGroup()` tests were flaky due to a dependency on Set iteration order in error message generation. ### Root Cause The cleanup commit that replaced `new HashSet<>(Arrays.asList(...))` with `Set.of(...)` in ShareGroupCommandOptions changed the iteration characteristics of collections used for error message generation: This produces different orders like `[topic], [group]` vs `[group], [topic]`, but the tests expected a specific order, causing intermittent failures. ### Solution Fix the root cause by ensuring deterministic error message generation through alphabetical sorting of option names. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: jira-unsubscr...@kafka.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org