Open nwbrettski opened 1 month ago
Blocked until Thor v2.1.3 is released.
@nwbrettski it's very important to only use next
if the thor version is v2.1.2, otherwise the API call fails
API version can be extracted from the headers (suggest maybe getting the genesis block when thor client is constructed)
example:
curl -I https://mainnet.vechain.org/blocks/0
Output (see the last line)
HTTP/2 405
date: Fri, 26 Jul 2024 10:35:22 GMT
set-cookie: AWSALB=dLZ4sagS6AQxeHl4iDDygphi5sJaukT9Wi+KNPOHgaH0LpJWcAkilcWFXrC2xHnjdJfY9b3SDi9k+Ljq960qgC/wj9gzObvbPr8pST/8Boc0rFux8uiERS3oeMLL; Expires=Fri, 02 Aug 2024 10:35:22 GMT; Path=/
set-cookie: AWSALBCORS=dLZ4sagS6AQxeHl4iDDygphi5sJaukT9Wi+KNPOHgaH0LpJWcAkilcWFXrC2xHnjdJfY9b3SDi9k+Ljq960qgC/wj9gzObvbPr8pST/8Boc0rFux8uiERS3oeMLL; Expires=Fri, 02 Aug 2024 10:35:22 GMT; Path=/; SameSite=None; Secure
vary: Accept-Encoding
x-genesis-id: 0x00000000851caf3cfdb6e899cf5958bfb1ac3413d346d43539627e6be7ec1b4a
x-thorest-ver: 2.1.2
Thor v2.1.3 introduces support for a newly supported revision
next
which is thebest block
+ 1. It should be used when estimating clauses.POST /accounts/*
should now bePOST /accounts/*?revision=next
.The
next
revision is only available on nodes that are running v2.1.3 and later, older nodes will not be aware of the revisionnext
. Error handling should be in place to work around this limitation.Tasks:
next
Acceptance Criteria:
next
revision.