You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Avoid returning failure after initiating a channel #1143
open_channel_inner creates a channel before persisting the peer's reconnection information. If that persistence fails, the API returns Error::PersistenceFailed even though the channel is already live and opening messages may have been sent. A caller retrying the apparent failure can therefore open a second channel and repeat any push amount. The affected ordering is in src/lib.rs:1418-1449 at main 1dea48a5ea06e5af2eabbf0633b32aee3338bd6c; an ordinary transient peer-store write failure is sufficient.
Make the result accurately reflect whether channel opening was initiated: persist the required peer information before creating the channel, or return the initiated channel's ID and report the persistence problem separately. Add a regression that fails only the peer-store write and verifies the API cannot report an ordinary failed initiation while leaving a live channel; include successful initiation and retry controls. Fixing peer-store cache rollback alone does not fix this ordering issue. No regression test or production patch was run during triage.
Activity
Persist the peer before initiating a channel