diff --git a/api/goldens/aptos_api__tests__call_trace_test__test_get_call_trace_by_hash.json b/api/goldens/aptos_api__tests__call_trace_test__test_get_call_trace_by_hash.json index 4f4ca6b58c3bc..a3e7da111e3a8 100644 --- a/api/goldens/aptos_api__tests__call_trace_test__test_get_call_trace_by_hash.json +++ b/api/goldens/aptos_api__tests__call_trace_test__test_get_call_trace_by_hash.json @@ -132,7 +132,9 @@ "outputs": [ "0x34bf7e2d17674feb234371a7ea58efd715f0e56ba20ebf13789480d9d643afaf" ], - "type_args": [], + "type_args": [ + "0x1::aptos_coin::AptosCoin" + ], "sub_traces": [] }, { @@ -145,7 +147,9 @@ "outputs": [ "false" ], - "type_args": [], + "type_args": [ + "0x1::aptos_coin::AptosCoin" + ], "sub_traces": [] }, { @@ -156,7 +160,9 @@ "0x34bf7e2d17674feb234371a7ea58efd715f0e56ba20ebf13789480d9d643afaf" ], "outputs": [], - "type_args": [], + "type_args": [ + "0x1::aptos_coin::AptosCoin" + ], "sub_traces": [ { "pc": 0, @@ -167,7 +173,9 @@ "" ], "outputs": [], - "type_args": [], + "type_args": [ + "0x1::aptos_coin::AptosCoin" + ], "sub_traces": [] } ] @@ -182,7 +190,9 @@ "outputs": [ "struct[0u64, struct[struct[2u64, 0x34bf7e2d17674feb234371a7ea58efd715f0e56ba20ebf13789480d9d643afaf]]]" ], - "type_args": [], + "type_args": [ + "0x1::aptos_coin::AptosCoin" + ], "sub_traces": [ { "pc": 0, @@ -194,7 +204,9 @@ "outputs": [ "struct[struct[2u64, 0x34bf7e2d17674feb234371a7ea58efd715f0e56ba20ebf13789480d9d643afaf]]" ], - "type_args": [], + "type_args": [ + "0x1::coin::DepositEvent" + ], "sub_traces": [ { "pc": 0, @@ -235,7 +247,9 @@ "outputs": [ "struct[0u64, struct[struct[2u64, 0x34bf7e2d17674feb234371a7ea58efd715f0e56ba20ebf13789480d9d643afaf]]]" ], - "type_args": [], + "type_args": [ + "0x1::coin::DepositEvent" + ], "sub_traces": [] } ] @@ -250,7 +264,9 @@ "outputs": [ "struct[0u64, struct[struct[3u64, 0x34bf7e2d17674feb234371a7ea58efd715f0e56ba20ebf13789480d9d643afaf]]]" ], - "type_args": [], + "type_args": [ + "0x1::aptos_coin::AptosCoin" + ], "sub_traces": [ { "pc": 0, @@ -262,7 +278,9 @@ "outputs": [ "struct[struct[3u64, 0x34bf7e2d17674feb234371a7ea58efd715f0e56ba20ebf13789480d9d643afaf]]" ], - "type_args": [], + "type_args": [ + "0x1::coin::WithdrawEvent" + ], "sub_traces": [ { "pc": 0, @@ -303,7 +321,9 @@ "outputs": [ "struct[0u64, struct[struct[3u64, 0x34bf7e2d17674feb234371a7ea58efd715f0e56ba20ebf13789480d9d643afaf]]]" ], - "type_args": [], + "type_args": [ + "0x1::coin::WithdrawEvent" + ], "sub_traces": [] } ] diff --git a/third_party/move/move-vm/runtime/src/interpreter.rs b/third_party/move/move-vm/runtime/src/interpreter.rs index 823315dd344e9..434d10426e503 100644 --- a/third_party/move/move-vm/runtime/src/interpreter.rs +++ b/third_party/move/move-vm/runtime/src/interpreter.rs @@ -319,7 +319,9 @@ impl Interpreter { inputs: args_1.into_iter().enumerate().map(|(_, i)| i.to_string()).collect(), outputs: vec![], // TODO(pcxu): add type args - type_args: vec![], + type_args: current_frame.ty_args().into_iter().map(|ty| { + loader.type_to_type_tag(ty).unwrap().to_string() + }).collect(), sub_traces: vec![], }).map_err(|_e| { let err = PartialVMError::new(StatusCode::ABORTED); @@ -449,7 +451,9 @@ impl Interpreter { Ok(value.as_move_value(&layout).to_string()) }).map(|v: Result| v.unwrap_or("".to_string())).collect(), outputs: vec![], - type_args: vec![], + type_args: current_frame.ty_args().into_iter().map(|ty| { + loader.type_to_type_tag(ty).unwrap().to_string() + }).collect(), sub_traces: vec![], }).map_err(|_e| { let err = PartialVMError::new(StatusCode::ABORTED); @@ -535,7 +539,9 @@ impl Interpreter { Ok(value.as_move_value(&layout).to_string()) }).map(|v: Result| v.unwrap_or("".to_string())).collect(), outputs: vec![], - type_args: vec![], + type_args: current_frame.ty_args().into_iter().map(|ty| { + loader.type_to_type_tag(ty).unwrap().to_string() + }).collect(), sub_traces: vec![], }).map_err(|_e| { let err = PartialVMError::new(StatusCode::ABORTED);