Thanks to visit codestin.com
Credit goes to github.com

Skip to content

[fix] Fix simple storage unit tests on IPv6 nodes#135

Merged
0oshowero0 merged 1 commit into
Ascend:mainfrom
0oshowero0:fix_ipv6_ut
Jul 4, 2026
Merged

[fix] Fix simple storage unit tests on IPv6 nodes#135
0oshowero0 merged 1 commit into
Ascend:mainfrom
0oshowero0:fix_ipv6_ut

Conversation

@0oshowero0

@0oshowero0 0oshowero0 commented Jul 4, 2026

Copy link
Copy Markdown
Collaborator

This PR updates the simple storage unit test mock client to create its ZMQ DEALER socket through the shared create_zmq_socket() helper instead of constructing a raw socket directly.

The fixture now passes the storage node IP from ZMQServerInfo into the mock client, allowing IPv6 endpoints to correctly enable the zmq.IPV6 socket option. This matches production socket setup behavior and fixes hangs/failures when running tests/test_simple_storage_unit.py on IPv6-only environments.

Signed-off-by: 0oshowero0 <[email protected]>
Copilot AI review requested due to automatic review settings July 4, 2026 06:17
@ascend-robot

Copy link
Copy Markdown

CLA Signature Pass

0oshowero0, thanks for your pull request. All authors of the commits have signed the CLA. 👍

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

This PR fixes IPv6-only test hangs in tests/test_simple_storage_unit.py by ensuring the mock storage client creates its ZMQ DEALER socket via the shared create_zmq_socket() helper and receives the storage node’s IP so IPv6 socket options are enabled consistently with production.

Changes:

  • Updated MockStorageClient to create its ZMQ socket via create_zmq_socket(ctx, zmq.DEALER, storage_ip) (enabling zmq.IPV6 when appropriate).
  • Extended the storage_setup fixture to also yield zmq_info.ip.
  • Updated all test call sites to pass storage_ip into MockStorageClient.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@0oshowero0 0oshowero0 merged commit 8a01e9e into Ascend:main Jul 4, 2026
8 checks passed
@0oshowero0 0oshowero0 deleted the fix_ipv6_ut branch July 4, 2026 06:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants