I'm encountering difficulties retrieving a random number using the VRF Direct Funding method in my Truffle framework project with pragma solidity ^0.8.9. During unit testing on a local Ganache network, I've followed the Chainlink docs meticulously. However, the "success" property in the "RandomWordsFulfilled" event consistently returns false. I suspect a potential gas-related issue, particularly in the following code snippet:
(bool success, ) = _consumer.call{gas: req.callbackGasLimit}(callReq);
Any insights or suggestions on resolving this issue would be greatly appreciated.
Remix Environment:
Local Environment:
Gas Adjustment:
Despite replicating the steps in both Remix and the local environment and attempting gas adjustments, the problem persists. Seeking guidance on the correct gas configurations or any additional troubleshooting steps to resolve the issue.
Ok so the problem was between the laptop and the chair, I was calling the wrong consumer address, it was the wrapper address not the contract who consumes vrf