Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix signing session #993

Merged
merged 2 commits into from
Jul 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
40 changes: 20 additions & 20 deletions chronicle/src/shards/service.rs
Original file line number Diff line number Diff line change
Expand Up @@ -233,26 +233,26 @@ where
for session in start_sessions {
tss.on_start(session);
}
while let Some(n) = self.messages.keys().copied().next() {
if n > block_number {
break;
}
for (shard_id, peer_id, msg) in self.messages.remove(&n).unwrap() {
let Some(tss) = self.tss_states.get_mut(&shard_id) else {
event!(
target: TW_LOG,
parent: &span,
Level::INFO,
shard_id,
"dropping message {} from {:?}",
msg,
peer_id,
);
continue;
};
tss.on_message(peer_id, msg)?;
self.poll_actions(&span, shard_id, n).await;
}
}
while let Some(n) = self.messages.keys().copied().next() {
if n > block_number {
break;
}
for (shard_id, peer_id, msg) in self.messages.remove(&n).unwrap() {
let Some(tss) = self.tss_states.get_mut(&shard_id) else {
event!(
target: TW_LOG,
parent: &span,
Level::INFO,
shard_id,
"dropping message {} from {:?}",
msg,
peer_id,
);
continue;
};
tss.on_message(peer_id, msg)?;
self.poll_actions(&span, shard_id, n).await;
}
}
Ok(())
Expand Down
2 changes: 1 addition & 1 deletion tss/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ where
if let Some(session) = signing_sessions.get_mut(&id) {
session.on_message(frost_id, msg);
} else {
anyhow::bail!("invalid signing session");
tracing::info!("invalid signing session {}", id);
}
},
(_, msg) => {
Expand Down
Loading