Add conditional logic to use getBlock rather than getBlockInfo.
getBlock is used for nodeos chains under 2.1.0 and getBlockInfo is used for 2.1.0+
TransactionConfig has a new member called chainVersionString that contains the target chain ID that the transaction is meant for. This value is unset by default. The user may set the value manually if they desire. Semantic versioning is used for the parsing and comparison of the versions. If the value is unset, TransactionProcessor will use the return from getInfo in order to determine the server version and set chainVersionString appropriately. If the value cannot be found or parsed a default of 2.0.0 will be used, causing getBlock to be called for TAPOS rather than getBlockInfo. This should allow the SDK to work transparently on 2.0.0 and 2.1.0+ nodes.
TransactionProcessorTest updated to be parameterized to run one pass with 2.0.0 and another with 2.1.0.
why I get this URL: http://192.168.182.4:8888/v1/chain/get_block_info I use SDK 1.0 & eosio version=v1.8.14... how to resolve this issue? Thanks.
For now you will have to use the older version of the SDKs until this PR can be merged and a new release deployed. 1.0.0 was originally designed to be released with nodeos 2.1 which replaced get_block in the transaction signing process with get_block_info. 2.1 has been delayed to this PR adds backward compatibility. @GonnaGitYou FYI