delivery: reconcile backchannel outcomes and reverse resources

This commit is contained in:
DeFiDude committed 2026-08-14 13:49:48 -06:00
1 parent 681c0f5961
commit b40dcd37f2
2 files changed
+2086 -65

No files matched your search

File diff suppressed because it is too large. Load diff
+11 -3
View File
@@ -1978,15 +1978,19 @@ impl LxmRouter {
let mut raw = header.pack();
raw.extend_from_slice(&packet_payload);
if transport_tx
let dispatched = transport_tx
.try_send(rns_transport::messages::TransportMessage::Outbound(
rns_transport::messages::OutboundRequest {
raw: Bytes::from(raw),
destination_hash: dest_hash,
},
))
.is_ok()
&& message.state == MessageState::Sending
.is_ok();
if dispatched
&& matches!(
message.state,
MessageState::Sending | MessageState::Sent
)
{
message.mark_sent();
message.progress = 1.0;
@@ -3643,6 +3647,10 @@ mod tests {
let received = rx.try_recv();
assert!(received.is_ok(), "expected outbound packet from tick()");
assert!(
router.pending_outbound.is_empty(),
"a successful fire-and-forget tick must not requeue the sent packet"
);
}
#[test]