juno icon indicating copy to clipboard operation
juno copied to clipboard

`starknet_getTransactionReceipt` response doesn't conform to the 0.7.1 spec

Open fracek opened this issue 1 year ago • 0 comments

I noticed that in some cases the response to starknet_getTransactionReceipt doesn't follow the spec for RPC 0.7.1.

For example the following request on mainnet

{
	"id": 0,
	"jsonrpc": "2.0",
	"method": "starknet_getTransactionReceipt",
	"params": ["0x6b1e0c9f74d338fe8d992a6a67307275e9be9e311bfe5297c43bfd4ef16069e"]
}

Returns the following response

{
	"jsonrpc": "2.0",
	"result": {
		"type": "INVOKE",
		"transaction_hash": "0x6b1e0c9f74d338fe8d992a6a67307275e9be9e311bfe5297c43bfd4ef16069e",
		"actual_fee": {
			"amount": "0x1106f22bd5d36",
			"unit": "WEI"
		},
		"execution_status": "SUCCEEDED",
		"finality_status": "ACCEPTED_ON_L1",
		"block_hash": "0x2bf7e9abd8b35622f7bfdb8c7a8379766f80bd4e7009b146acb2ced0004d44c",
		"block_number": 500000,
		"messages_sent": [],
		"events": [/* skip events */],
		"execution_resources": {
			"steps": 36134,
			"memory_holes": 9031,
			"pedersen_builtin_applications": 67,
			"range_check_builtin_applications": 2241,
			"bitwise_builtin_applications": 29,
			"segment_arena_builtin": 6
		}
	},
	"id": 0
}

Notice how the execution_resources.data_availability field is missing, but it's marked as required in the spec.

fracek avatar Apr 08 '24 17:04 fracek