Skip to content

fix: correct inverted guard in WithRegistryIDs/WithProtocolIDs - #3604

Merged
Alanxtl merged 1 commit into
apache:developfrom
MaoMengww:develop
Aug 7, 2026
Merged

fix: correct inverted guard in WithRegistryIDs/WithProtocolIDs#3604
Alanxtl merged 1 commit into
apache:developfrom
MaoMengww:develop

Conversation

@MaoMengww

Copy link
Copy Markdown

Description

Fixes # (issue)
The root cause of the bug is an inverted guard condition. When a user use RegistryIDs/ProtocolIDs, a non-empty value should be written to the field; however, due to the inverted guard condition, the assignment is skipped whenever the user provides a value (i.e., len(IDs) > 0), causing it to be silently dropped. The test file: when a non-empty value is passed, the assertion should be that the field equals the input (assert.Equal), not that it differs (assert.NotEqual).

Refs #3598 (task1)

Checklist

  • I confirm the target branch is develop
  • Code has passed local testing
  • I have added tests that prove my fix is effective or that my feature works

@MaoMengww

Copy link
Copy Markdown
Author

@Alanxtl please review it

@sonarqubecloud

sonarqubecloud Bot commented Aug 6, 2026

Copy link
Copy Markdown

@codecov-commenter

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 53.87%. Comparing base (60d1c2a) to head (5c7c5b0).
⚠️ Report is 891 commits behind head on develop.

Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #3604      +/-   ##
===========================================
+ Coverage    46.76%   53.87%   +7.10%     
===========================================
  Files          295      474     +179     
  Lines        17172    36388   +19216     
===========================================
+ Hits          8031    19604   +11573     
- Misses        8287    15208    +6921     
- Partials       854     1576     +722     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@Alanxtl Alanxtl left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

lgtm

@Alanxtl
Alanxtl merged commit f2ec52e into apache:develop Aug 7, 2026
8 checks passed
@Alanxtl Alanxtl self-assigned this Aug 7, 2026
@Alanxtl Alanxtl added ☢️ Bug 3.3.3 version 3.3.3 labels Aug 7, 2026
@MaoMengww
MaoMengww deleted the develop branch August 7, 2026 05:48
@MaoMengww
MaoMengww restored the develop branch August 7, 2026 05:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

3.3.3 version 3.3.3 ☢️ Bug

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[OSPP] 完善 Dubbo-Go SDK 文档与 dubbo-go 入门任务

3 participants