-
Notifications
You must be signed in to change notification settings - Fork 1.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update test suite, update Solidity version for compiling test contracts, remove deprecated JSON-RPC methods #3307
Update test suite, update Solidity version for compiling test contracts, remove deprecated JSON-RPC methods #3307
Conversation
1989108
to
b69d66a
Compare
v0.8.25
4465127
to
1994dfe
Compare
v0.8.25
747e932
to
8c52a4c
Compare
48b345a
to
cd23243
Compare
cd23243
to
bb82062
Compare
- Remove pending block reliance; set dev period to 1 second - Use the latest geth 1.14.5 for integration; re-generate fixture - Tweaks to the fixture generation based on geth updates - re-compile test contracts with Solidity v0.8.25 - Remove support for non-existent client properties: - ``eth_coinbase`` - ``eth_mining`` - ``eth_hashrate`` - ``eth_submitHashrate`` - ``eth_submitWork`` - ``eth_getWork`` - Update py-geth to use the newly released beta - quick lint fixes - Fix remaining tests that rely on mining: - newsfragment for ethereum#3307
fyi: I updated my gpg key so I had to squash all old commits into one large commit that was signed by the new gpg key. I would've used a bit more separation of concerns in the commits / messages otherwise. |
- Remove pending block reliance; set dev period to 1 second - Use the latest geth 1.14.5 for integration; re-generate fixture - Tweaks to the fixture generation based on geth updates - re-compile test contracts with Solidity v0.8.25 - Remove support for non-existent client properties: - ``eth_coinbase`` - ``eth_mining`` - ``eth_hashrate`` - ``eth_submitHashrate`` - ``eth_submitWork`` - ``eth_getWork`` - Update py-geth to use the newly released beta - quick lint fixes - Fix remaining tests that rely on mining: - newsfragment for ethereum#3307
50edf39
to
ab0436f
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good so far. Not sure what happened with the latest run in CI but I'll have another look with the next py-geth
release.
Circle CI was down EOD yesterday. I meant to re-run today.
I don't think we plan on releasing it while keeping this PR open. This is going in web3.py |
2d44a6f
to
832dd0f
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! I left a few inline nits, and then the only other thing is I wonder if we should think of a better name for accounts[0]
to reference it by. Maybe default_account
? Feel free to take or leave, I don't think it's a huge improvement and I don't really have a better idea at the moment ¯_(ツ)_/¯
Yeah, agreed. I think that might be a nice pytest fixture abstraction to have if anything. I'll take a peek while I'm in there. |
- Remove pending block reliance; set dev period to 1 second - Use the latest geth 1.14.5 for integration; re-generate fixture - Tweaks to the fixture generation based on geth updates - re-compile test contracts with Solidity v0.8.25 - Remove support for non-existent client properties: - ``eth_coinbase`` - ``eth_mining`` - ``eth_hashrate`` - ``eth_submitHashrate`` - ``eth_submitWork`` - ``eth_getWork`` - Update py-geth to use the newly released beta - quick lint fixes - Fix remaining tests that rely on mining: - newsfragment for ethereum#3307
- Set a timeout and loop over the latest block a few times until desired tx is included. - Some processing, such as async IPC, goes faster than others. There'stability not a great way to ensure if we are in the "pending" or "latest" state for blocks using geth --dev. The important thing for testing on our end is that the JSON-RPC method works the way it's expected. Whether or not it returns the expected result based on block number, etc, is on Geth's side to make sure. Test the JSON-RPC method and give it flexibility in this commit.
832dd0f
to
5096d35
Compare
This commit updates the tests to set ``w3.eth.default_account`` to the first account and use it in place of ``w3.eth.coinbase``, since ``eth_coinbase`` was removed in clients like geth. Using ``w3.eth.accounts[0]`` is not a very user-friendly API to keep calling across all tests.
5096d35
to
46a717a
Compare
@kclowes, I opted to make use of the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, I like that! 🚢
- Remove pending block reliance; set dev period to 1 second - Use the latest geth 1.14.5 for integration; re-generate fixture - Tweaks to the fixture generation based on geth updates - re-compile test contracts with Solidity v0.8.25 - Remove support for non-existent client properties: - ``eth_coinbase`` - ``eth_mining`` - ``eth_hashrate`` - ``eth_submitHashrate`` - ``eth_submitWork`` - ``eth_getWork`` - Update py-geth to use the newly released beta - quick lint fixes - Fix remaining tests that rely on mining: - newsfragment for #3307
What was wrong?
This PR was meant to update Solidity contract versions but it revealed that
geth --dev
was broken. Geth fixed this and this PR brings those changes in (v1.14.3
). Updated geth no longer has support foreth_mining
,eth_hashrate
,eth_submitWork
,eth_getWork
,eth_coinbase
. This PR gets our test suite updated with all of these changes as well as removes support for those methods altogether. We will have to issue a backport PR forv6
to deprecate all of these.v1.14.3
eth-tester[py-evm]
to0.10.0b.4
eth_mining
,eth_hashrate
,eth_submitHashrate
,eth_submitWork
,eth_getWork
,eth_coinbase
pending
blockThe goal here was to compile test contracts with Solidity
0.8.25
which broke because we needed to update geth. This PR was open for a while and0.8.26
came out as well. This build has everything working with0.8.25
and then the latest version should use0.8.26
.Todo:
Cute Animal Picture
0_o