I am encountering an "execution reverted" error when trying to perform a token swap using the PancakeSwap V3 router via a Web3.py script. The issue does not occur when swapping directly on the PancakeSwap interface, suggesting there might be a discrepancy or an issue with how the transaction is being handled or constructed in the script.
Steps to Reproduce
Set up a Web3.py environment with connection to Binance Smart Chain (BSC).
Use the following code snippet to perform a token swap:
I am encountering an "execution reverted" error when trying to perform a token swap using the PancakeSwap V3 router via a Web3.py script. The issue does not occur when swapping directly on the PancakeSwap interface, suggesting there might be a discrepancy or an issue with how the transaction is being handled or constructed in the script.
Steps to Reproduce Set up a Web3.py environment with connection to Binance Smart Chain (BSC). Use the following code snippet to perform a token swap:
Additional Information I have verified that the smart contract has sufficient allowances, and the account has enough USDT to perform the swap.