Skip to content
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

Merge/foundation release/1.12.2+spiral #561

Conversation

meowsbits
Copy link
Member

Implements the pending Spiral (ECIP-1109) network upgrade for ETC.

meowsbits and others added 27 commits August 18, 2023 08:00
Signed-off-by: meows <[email protected]>
…s/types/goethereum: install Shanghai=Spiral block number based iface methods

ETC plans to install most EIPs associated with
ETH's Shanghai fork, but ETC doesn't use PoS so activation
by block time, so this adds supporting block-based activation
methods for those features.
Still TODO is to actually implement the associated conditionals
where the Getters are used in the code to actually turn
the new features on.

Date: 2023-08-18 09:11:04-06:00
Signed-off-by: meows <[email protected]>
Date: 2023-08-18 19:28:32-06:00
Signed-off-by: meows <[email protected]>
Blocks are big ints.
Times are uint64s.

I am 73% certain this covers all cases.

Date: 2023-08-18 19:30:17-06:00
Signed-off-by: meows <[email protected]>
Date: 2023-08-18 19:50:22-06:00
Signed-off-by: meows <[email protected]>
Date: 2023-08-19 07:24:31-06:00
Signed-off-by: meows <[email protected]>
Date: 2023-08-19 07:29:40-06:00
Signed-off-by: meows <[email protected]>
Date: 2023-08-19 07:43:32-06:00
Signed-off-by: meows <[email protected]>
…ght: GetEIP3860Transition

Date: 2023-08-19 07:53:58-06:00
Signed-off-by: meows <[email protected]>
Date: 2023-08-19 07:55:11-06:00
Signed-off-by: meows <[email protected]>
…95Transition

Date: 2023-08-19 08:22:35-06:00
Signed-off-by: meows <[email protected]>
Date: 2023-08-19 08:23:35-06:00
Signed-off-by: meows <[email protected]>
Date: 2023-08-19 08:27:25-06:00
Signed-off-by: meows <[email protected]>
Date: 2023-08-19 08:30:24-06:00
Signed-off-by: meows <[email protected]>
Date: 2023-08-19 08:54:33-06:00
Signed-off-by: meows <[email protected]>
Date: 2023-08-19 09:13:58-06:00
Signed-off-by: meows <[email protected]>
…lock-based Shanghai config

Failing was TestCheckCompatible, which
converts Geth::CoreGeth configuration types;
CoreGeth's EIP3651 block transition was fatally
inapplicable to Geth's config.

So this patch sidesteps the issue by permitting
the conversion to quietly fail; expecting that users/developers
will be sane enough to configure upgrades with one pattern or the other
but not both.

Date: 2023-08-19 09:17:33-06:00
Signed-off-by: meows <[email protected]>
Date: 2023-08-25 08:55:58-06:00
Signed-off-by: meows <[email protected]>
…t_Features fails

Mismatched EIP3651 activations caused an
incompatibility between core-geth and go-ethereum
config types.

This is mostly just a problem of/with the tests
because of the disparate configuration TYPES
now (block vs. time).

This patches fixes the issue by implementing
a logical short-circut equivocating zero values
for time and block fields in core-geth
and go-ethereum configuration configurator
interfaces.

Probably these logical steps will only be followed
by tests or testnets or networks using time OR
block values.

Date: 2023-08-25 14:51:50-06:00
Signed-off-by: meows <[email protected]>
Conflicts:
      core/genesis.go
      core/txpool/txpool.go
      core/vm/jump_table.go
      params/types/genesisT/genesis.go
      tests/init.go
By Go conventions the Error method should
return a descriptive string.

When I was debugging the simulated beacon
test, the reported error was hardly usedful,
describing only that an error existed, but lacking
any contextual detail.

Now the engine api will return a more
detailed error and that will hopefully
help debuggers in the future.

Date: 2023-08-29 09:01:11-06:00
Signed-off-by: meows <[email protected]>
This logic was just wrong because of
misplaced negation.

Date: 2023-08-29 09:10:51-06:00
Signed-off-by: meows <[email protected]>
This reverts commit ae0efa1.

Reason: it caused a test failure TestGetBlockBodiesByRangeInvalidParams
where that test compares the have/want errors as strings
and I can't be bothered to adjust the test.

It would be better, probably, to use errors.Is with wrapped
errors.
core/genesis.go Outdated Show resolved Hide resolved
meowsbits and others added 4 commits September 1, 2023 10:18
… number

In order to check eip4895 features for ETC-style
block number-based activations, the attributes get
a block number field which is allowed to be nil.

As usual for core-geth, activation numbers are OR'd
with activation times.

Date: 2023-09-01 10:18:47-06:00
Signed-off-by: meows <[email protected]>
... but reference forks by name to
keep the important context.

Date: 2023-09-04 05:22:48-06:00
Signed-off-by: meows <[email protected]>
…oregeth,params/types/goethereum: problem: TestEquivalent_Features fails"

This reverts commit a5e0c62.
Copy link
Member

@ziogaschr ziogaschr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Nice work man

@ziogaschr
Copy link
Member

Oh actually, before we merge this, shall we set the block numbers for Spiral correctly?
Currently classic is set to 18_400_000, while Mordor is not at all.

@meowsbits
Copy link
Member Author

meowsbits commented Sep 4, 2023

Ah, important. I think we should unset all activation numbers for ETC until the ECIP gets more love and confidence. (ECIP 1109 currently specs impossible (past) values of 18000000 for mainnet, 9000000 for Mordor); https://github.com/ethereumclassic/ECIPs/blob/64423c73b7416c2f8e40d4c66bf40b715c458b8c/_specs/ecip-1109.md).

The ECIP does not specify valid activation
blocks yet, so we should not code them.
https://github.com/ethereumclassic/ECIPs/blob/64423c73b7416c2f8e40d4c66bf40b715c458b8c/_specs/ecip-1109.md

Date: 2023-09-04 10:34:38-06:00
Signed-off-by: meows <[email protected]>
@meowsbits meowsbits force-pushed the merge/foundation-release/1.12.2+spiral branch from 1749308 to 1c9478d Compare September 4, 2023 16:34
@meowsbits
Copy link
Member Author

Test was failing, but is another flaky one https://github.com/etclabscore/core-geth/actions/runs/6084737553/job/16507292035?pr=561#step:4:1218. Cannot reproduce locally. Merging.

@meowsbits meowsbits merged commit f1d9db7 into merge/foundation-release/1.12.2 Sep 5, 2023
3 of 4 checks passed
@meowsbits meowsbits deleted the merge/foundation-release/1.12.2+spiral branch September 5, 2023 14:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants