From 8c58efc92126eb6c58fb189081cc126bb8b765f9 Mon Sep 17 00:00:00 2001 From: AMATH <116212274+amathxbt@users.noreply.github.com> Date: Fri, 3 Apr 2026 22:43:00 +0100 Subject: [PATCH] fix: add missing chainId to infer() transaction in _send_tx_with_revert_handling MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Every other transaction built in alpha.py (new_workflow, run_workflow, _register_with_scheduler) correctly includes chainId in the transaction dict. _send_tx_with_revert_handling — which handles the primary infer() path — was the only method missing it. Without chainId, Web3.py signs transactions without EIP-155 replay protection. This can cause RPC nodes to reject the transaction or behave unexpectedly in multi-chain/testnet environments. --- src/opengradient/client/alpha.py | 1 + 1 file changed, 1 insertion(+) diff --git a/src/opengradient/client/alpha.py b/src/opengradient/client/alpha.py index d2957c2..80327da 100644 --- a/src/opengradient/client/alpha.py +++ b/src/opengradient/client/alpha.py @@ -164,6 +164,7 @@ def _send_tx_with_revert_handling(self, run_function): "nonce": nonce, "gas": gas_limit, "gasPrice": self._blockchain.eth.gas_price, + "chainId": self._blockchain.eth.chain_id, } )