You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
EIP-3668 recommends the following for CCIP Read support:
Client libraries should disable CCIP read for transactions (but not for calls) by default, and require the caller to explicitly enable this functionality. Enablement should be possible both on a per-contract, per-domain, or global basis.
We currently enable it by default for calls and don't handle this at all automatically for transactions but do provide documentation on how to properly handle offchain lookup for transactions. However, if a user is not interested in enabling CCIP Read at all, even for calls, we could allow this to happen on the provider level and they wouldn't have to worry about disabling it at the eth_call level with each call.
How can it be fixed?
Add a provider ccip_read_calls_enabled flag and account for this value at the w3.eth.call() level.
This should be implemented so that the flag on eth.call() can override whatever is set on the global provider flag. This would allow for call-specific control for CCIP read.
i.e. for Eth (and similarly AsyncEth):
defcall(self, ..., ccip_read_enabled: Optional[bool] =None):
ccip_read_enabled_on_provider=self.w3.provider.ccip_read_calls_enabledif (
# default conditions:ccip_read_enabled_on_providerandccip_read_enabledisnotFalse# explicit call flag overrides provider flag, enabling ccip read for specific calls:ornotccip_read_enabled_on_providerandccip_read_enabledisTrue
):
returnself._durin_call(...)
returnself._call(...)
The text was updated successfully, but these errors were encountered:
What was wrong?
EIP-3668 recommends the following for CCIP Read support:
We currently enable it by default for calls and don't handle this at all automatically for transactions but do provide documentation on how to properly handle offchain lookup for transactions. However, if a user is not interested in enabling CCIP Read at all, even for calls, we could allow this to happen on the provider level and they wouldn't have to worry about disabling it at the
eth_call
level with each call.How can it be fixed?
ccip_read_calls_enabled
flag and account for this value at thew3.eth.call()
level.This should be implemented so that the flag on
eth.call()
can override whatever is set on the global provider flag. This would allow for call-specific control for CCIP read.i.e. for
Eth
(and similarlyAsyncEth
):The text was updated successfully, but these errors were encountered: