I’m using wagmi ^1.3.10
and
getting this error:
getTransaction.js:58 Uncaught (in promise) TransactionNotFoundError
at getTransaction (getTransaction.js:58:15)
at async delay.count.count (waitForTransactionReceipt.js:104:48)
at async attemptRetry (withRetry.js:17:30)
when calling this function:
export const createProposalInteraction = async (
ipfsHash: string,
formAddress: string
) => {
const { request: prepareConfig } = await prepareWriteContract({
address: mainContractAddress,
abi: MainContractAbi,
args: [formAddress, ipfsHash],
functionName: "createProposal",
});
const { hash } = await writeContract(prepareConfig);
const data = await waitForTransaction({
hash,
});
return data;
};
However, the transaction itself successfully passes.
Here is my wagmi config:
import {
RainbowKitProvider,
getDefaultWallets,
connectorsForWallets,
} from "@rainbow-me/rainbowkit";
import {
argentWallet,
trustWallet,
ledgerWallet,
} from "@rainbow-me/rainbowkit/wallets";
import { configureChains, createConfig, WagmiConfig } from "wagmi";
import { sepolia } from "wagmi/chains";
import { publicProvider } from "wagmi/providers/public";
const { chains, publicClient, webSocketPublicClient } = configureChains(
[
sepolia,
],
[
publicProvider(),
],
//{ retryDelay: 500 }
);
const projectId = "my project id";
const { wallets } = getDefaultWallets({
appName: "RainbowKit demo",
projectId,
chains,
});
const demoAppInfo = {
appName: "Rainbowkit Demo",
};
const connectors = connectorsForWallets([
...wallets,
{
groupName: "Other",
wallets: [
trustWallet({ projectId, chains }),
ledgerWallet({ projectId, chains }),
],
},
]);
export const wagmiConfig = createConfig({
autoConnect: true,
connectors,
publicClient,
webSocketPublicClient,
});
I’ve even tried to tinker with retryDelay
in wagmi config , but that doesn't seem to be the issue.
How to fix this?