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

Remove decommissioned networks #1880

Open
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

pnowosie
Copy link
Contributor

@pnowosie pnowosie commented May 24, 2024

Remove decommissioned networks: Goerli, Goerli2 and Integration.

Fixes #1753 , #1758

@pnowosie pnowosie force-pushed the pnowosie/1753-Remove_dependency_on_Goerli_testnets branch from a5493cb to 3cecdca Compare May 24, 2024 08:51
Copy link

codecov bot commented May 24, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 78.15%. Comparing base (692bd49) to head (8742d96).
Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1880      +/-   ##
==========================================
- Coverage   78.39%   78.15%   -0.25%     
==========================================
  Files         100      100              
  Lines        9041     9073      +32     
==========================================
+ Hits         7088     7091       +3     
- Misses       1327     1345      +18     
- Partials      626      637      +11     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@pnowosie pnowosie force-pushed the pnowosie/1753-Remove_dependency_on_Goerli_testnets branch 3 times, most recently from 18d12b6 to 84d71ff Compare May 29, 2024 09:08
@pnowosie pnowosie force-pushed the pnowosie/1753-Remove_dependency_on_Goerli_testnets branch 2 times, most recently from dccfc48 to ac1a6eb Compare May 29, 2024 14:34
@pnowosie pnowosie marked this pull request as ready for review May 29, 2024 14:34
@pnowosie pnowosie force-pushed the pnowosie/1753-Remove_dependency_on_Goerli_testnets branch from ac1a6eb to feedd25 Compare June 4, 2024 11:34
@pnowosie pnowosie force-pushed the pnowosie/1753-Remove_dependency_on_Goerli_testnets branch from feedd25 to 0d6bdf8 Compare July 3, 2024 13:29
@pnowosie pnowosie force-pushed the pnowosie/1753-Remove_dependency_on_Goerli_testnets branch 3 times, most recently from 0887b2c to 6de2b42 Compare July 15, 2024 09:44
@pnowosie pnowosie force-pushed the pnowosie/1753-Remove_dependency_on_Goerli_testnets branch 2 times, most recently from 9eda3bc to 3510edd Compare July 26, 2024 13:21
@pnowosie pnowosie requested review from kirugan and removed request for wojciechos and rianhughes July 26, 2024 14:51
@pnowosie pnowosie force-pushed the pnowosie/1753-Remove_dependency_on_Goerli_testnets branch from 3510edd to 7383569 Compare August 22, 2024 12:25
@@ -443,125 +443,6 @@ func TestState(t *testing.T) {
})
}

func TestEvents(t *testing.T) {
Copy link
Contributor

Choose a reason for hiding this comment

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

Is this test obsolete?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I moved it into a possibly better place

func TestEvents(t *testing.T) {

number: 1,
chain: utils.Goerli,
name: "goerli network (pre 0.7.0 without sequencer address)",
},
Copy link
Contributor

Choose a reason for hiding this comment

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

are you sure that these tests should be removed? because sequencerFallback is part of our logic in old hashes, maybe there is an alternative in mainnet ?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I've found already 2 mainnet examples in this test if I am not mistaken

juno/core/block_test.go

Lines 31 to 44 in 7383569

{
// block 0: main
// https://alpha-mainnet.starknet.io/feeder_gateway/get_block?blockNumber=0
number: 0,
chain: utils.Mainnet,
name: "mainnet (pre 0.7.0 without sequencer address)",
},
{
// block 833: main
// https://alpha-mainnet.starknet.io/feeder_gateway/get_block?blockNumber=833
number: 833,
chain: utils.Mainnet,
name: "mainnet 833 (post 0.7.0 without sequencer address)",
},

{
number: 283364,
chain: utils.Integration,
name: "Block 283364 with Declare v2",
Copy link
Contributor

Choose a reason for hiding this comment

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

same, specific tx type with version

Copy link
Contributor Author

Choose a reason for hiding this comment

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

These one I looked for but found only version v3 - let me run my scripts over the weekend 🤔

Copy link
Contributor Author

@pnowosie pnowosie Aug 23, 2024

Choose a reason for hiding this comment

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

added Sepolia block #7

@@ -204,12 +126,12 @@ func TestBlockHash(t *testing.T) {
})

t.Run("no error if block is unverifiable", func(t *testing.T) {
Copy link
Contributor

Choose a reason for hiding this comment

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

new version of this test doesn't test what it was intended to. Here is metadata of goerli:

UnverifiableRange:        []uint64{119802, 148428},

119801 is beginning of unverifiable range

Copy link
Contributor

Choose a reason for hiding this comment

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

If we don't need this logic anymore it's even better, but I'm not sure. cc @IronGauntlets

gw := adaptfeeder.New(client)
tests := []struct {
classHash string
checkNoCompiled bool
}{
{
// https://external.integration.starknet.io/feeder_gateway/get_class_by_hash?classHash=0x1cd2edfb485241c4403254d550de0a097fa76743cd30696f714a491a454bad5
classHash: "0x1cd2edfb485241c4403254d550de0a097fa76743cd30696f714a491a454bad5",
// https://alpha-mainnet.starknet.io/feeder_gateway/get_class_by_hash?classHash=<calss_hash>
Copy link
Contributor

Choose a reason for hiding this comment

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

missing class_hash

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The url will be the same besides the class_hash parameter. I moved the comment above, and fixed the typo.

sync/sync_test.go Outdated Show resolved Hide resolved
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.

Remove dependency on Goerli testnets from Juno environments
4 participants