Skip to content

Conversation

@sanity
Copy link
Collaborator

@sanity sanity commented Dec 2, 2025

Problem

The previous stacked PRs (#2169#2171#2172#2174#2175) ran into git history divergence issues after squash-merging #2167. This made it impossible to cleanly merge the subsequent approved changes.

This Solution

This PR consolidates the approved changes from PRs #2169 and #2171 (both approved by Nacho) into a single clean PR against main:

Changes from PR #2169 (wire protocol cleanup):

  • Remove ObservedAddr in favor of std::net::SocketAddr
  • Clean up wire protocol types for address handling
  • Remove unused transient_manager module

Changes from PR #2171 (NAT routing improvements):

  • Add PeerAddr enum to explicitly represent known/unknown addresses
  • Update PeerKeyLocation to use PeerAddr for NAT scenarios
  • Peers behind NAT can now properly indicate their address is unknown

Context

This is part of issue #2164 (peer identity simplification). The original stacked PR approach was blocked because:

  1. PR refactor(routing): add upstream_addr for connection-based routing #2167 was squash-merged to main
  2. Git couldn't recognize subsequent branches as "ahead" of main
  3. The intermediate branches couldn't be directly merged

This PR recreates the approved changes by applying the diff from the intermediate branch to a fresh branch based on main.

Testing

Related

[AI-assisted - Claude]

Consolidates approved changes from PRs #2169 and #2171:

- Remove ObservedAddr in favor of std::net::SocketAddr
- Add PeerAddr enum to explicitly represent known/unknown addresses
- Update PeerKeyLocation to use PeerAddr for NAT scenarios
- Clean up wire protocol types for address handling
- Remove unused transient_manager module

This is part of the larger #2164 effort to simplify peer identity.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <[email protected]>
sanity added a commit that referenced this pull request Dec 2, 2025
Consolidates changes from PRs #2172, #2174, and #2175:

This builds on PR #2191 (wire protocol cleanup) and adds:
- Fix seeding/subscribe operations to handle PeerAddr::Unknown for NAT scenarios
- Gateway properly fills in observed addresses from packet source
- Improved subscriber address tracking in seeding manager
- Update live_tx and connection tests for new address model

NOTE: This PR requires review - previous PRs (#2174, #2175) had
CHANGES_REQUESTED from Nacho. Submitting consolidated changes for
fresh review.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <[email protected]>
@sanity sanity enabled auto-merge December 2, 2025 00:36
@sanity sanity added this pull request to the merge queue Dec 2, 2025
Merged via the queue into main with commit 15386d6 Dec 2, 2025
8 checks passed
@sanity sanity deleted the fix/nat-routing-consolidated-2191 branch December 2, 2025 00:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants