Skip to content

Reject temporary_channel_id duplicates early#3324

Merged
t-bast merged 2 commits into
masterfrom
temporary-channel-id-conflict
Jul 17, 2026
Merged

Reject temporary_channel_id duplicates early#3324
t-bast merged 2 commits into
masterfrom
temporary-channel-id-conflict

Conversation

@t-bast

@t-bast t-bast commented Jul 8, 2026

Copy link
Copy Markdown
Member

We previously rejected duplicate temporary_channel_id immediately, but we didn't immediately reject temporary_channel_ids that conflict with a final channel_id with the same peer: the rejection would happen later in the flow when transitioning from temporary to final IDs, which made debugging harder.

We previously rejected duplicate `temporary_channel_id` immediately, but
we didn't immediately reject `temporary_channel_id`s that conflict with
a *final* `channel_id` with the same peer: the rejection would happen
later in the flow when transitioning from temporary to final IDs, which
made debugging harder.
@t-bast
t-bast requested a review from pm47 July 8, 2026 11:26
Since the channel interceptor step isn't atomic, we must check for
duplicate channel IDs *after* rate-limiting, to ensure that we don't
try inserting an entry in the channels map that is already there.
@t-bast
t-bast merged commit 9b0bcec into master Jul 17, 2026
1 check passed
@t-bast
t-bast deleted the temporary-channel-id-conflict branch July 17, 2026 13:30
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