File tree Expand file tree Collapse file tree 1 file changed +16
-3
lines changed
turbopack/crates/turbo-tasks-backend/src Expand file tree Collapse file tree 1 file changed +16
-3
lines changed Original file line number Diff line number Diff line change @@ -667,9 +667,22 @@ fn serialize_task_type(
667
667
let deserialize: Result < CachedTaskType , _ > = serde_path_to_error:: deserialize (
668
668
& mut pot_de_symbol_list ( ) . deserializer_for_slice ( & * task_type_bytes) ?,
669
669
) ;
670
- if let Err ( err) = deserialize {
671
- println ! ( "Task type would not be deserializable {task_id}: {err:?}\n {task_type:#?}" ) ;
672
- panic ! ( "Task type would not be deserializable {task_id}: {err:?}" ) ;
670
+ match deserialize {
671
+ Ok ( value) => {
672
+ if & value != & * * task_type {
673
+ println ! (
674
+ "Task type would not round-trip {task_id}:\n Original: \
675
+ {task_type:#?}\n Round-tripped: {value:#?}"
676
+ ) ;
677
+ panic ! ( "Task type would not round-trip {task_id}" ) ;
678
+ }
679
+ }
680
+ Err ( err) => {
681
+ println ! (
682
+ "Task type would not be deserializable {task_id}: {err:?}\n {task_type:#?}"
683
+ ) ;
684
+ panic ! ( "Task type would not be deserializable {task_id}: {err:?}" ) ;
685
+ }
673
686
}
674
687
}
675
688
Ok ( ( ) )
You can’t perform that action at this time.
0 commit comments