@@ -381,26 +381,25 @@ impl Task {
381381
382382 // Process actions and collect deliveries.
383383 while let Some ( action) = actions. pop_front ( ) {
384- if let Action :: Deliver ( payload) = action {
385- match payload. data ( ) . decode :: < MAX_MESSAGE_SIZE > ( ) {
386- Ok ( data) => {
387- if let Some ( dkg) = data. dkg_bundle ( ) {
388- dkg_bundles. push_back ( dkg. clone ( ) ) ;
384+ match self . sailfish . execute ( action) . await {
385+ Ok ( Some ( CoordinatorEvent :: Deliver ( payload) ) ) => {
386+ match payload. data ( ) . decode :: < MAX_MESSAGE_SIZE > ( ) {
387+ Ok ( data) => {
388+ if let Some ( dkg) = data. dkg_bundle ( ) {
389+ dkg_bundles. push_back ( dkg. clone ( ) ) ;
390+ }
391+ payloads. push ( ( payload, data) ) ;
392+ }
393+ Err ( err) => {
394+ warn ! (
395+ node = %self . label,
396+ err = %err,
397+ src = %payload. source( ) ,
398+ "failed to deserialize candidate list"
399+ ) ;
389400 }
390- payloads. push ( ( payload, data) ) ;
391- }
392- Err ( err) => {
393- warn ! (
394- node = %self . label,
395- err = %err,
396- src = %payload. source( ) ,
397- "failed to deserialize candidate list"
398- ) ;
399401 }
400402 }
401- continue ;
402- }
403- match self . sailfish . execute ( action) . await {
404403 Ok ( Some ( CoordinatorEvent :: Gc ( r) ) ) => {
405404 if let Err ( err) = self . decrypter . gc ( r. num ( ) ) . await {
406405 warn ! ( node = %self . label, %err, "decrypt gc error" ) ;
@@ -426,7 +425,7 @@ impl Task {
426425 warn ! ( node = %self . label, id = %r. committee( ) , "committee not found" ) ;
427426 }
428427 }
429- Ok ( Some ( CoordinatorEvent :: Deliver ( _ ) ) | None ) => { }
428+ Ok ( None ) => { }
430429 Err ( err) => {
431430 error ! ( node = %self . label, %err, "coordinator error" ) ;
432431 return Err ( err. into ( ) ) ;
0 commit comments