ApeWorX / ApeWorX/ape-optimism

Optimism `TransactionNotFound` Error

Open
#14 3 comments 1 reaction 0 assignees View on GitHub
category: bug
Dominant language
Python
Stars
13
Forks
8
PR merge metrics
No merged PRs in 30d

Description

### Environment information

- OS: macOS
- Python Version: 3.9.15
- `ape` and plugin versions:
- `ape`: 0.5.9
- `ape-optimism`: 0.5.2

```sh
$ ape --version
0.5.9

$ ape plugins list
Installed Plugins:
etherscan 0.5.4
ens 0.5.1
optimism 0.5.2
infura 0.5.3
solidity 0.5.4
```

- Contents of your `ape-config.yaml` (NOTE: do not post anything private like RPC urls or secrets!):

```sh
$ cat ape-config.yaml
name: ape-interact

plugins:
- name: solidity
- name: etherscan
- name: infura
- name: optimism
- name: ens

optimism:
mainnet:
transaction_acceptance_timeout: 180
```

### What went wrong?

When running two subsequent transactions, the second transaction always fails with the error `TransactionNotFound`. However, this transaction is actually submitted and confirmed onchain. It fails to receive the receipt for the transaction hash of my second transaction.

Here is some pseudocode for the transactions:
```
from ape import project, accounts

def main():
# import account
account = accounts.load('account')

# create contract
contract = project.Contract.at("0x00000000")

# run functions
receipt_1 = contract.functionOne(sender=account)
receipt_2 = contract.functionTwo(sender=account)
```

This script fails on the line which starts with `receipt_2 =` when I run it using `ape-optimism`

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.