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

feat(statesync): add app version to snapshot #1477

Merged

Conversation

rootulp
Copy link
Collaborator

@rootulp rootulp commented Sep 12, 2024

@rootulp rootulp marked this pull request as ready for review September 26, 2024 20:44
@rootulp rootulp requested a review from a team as a code owner September 26, 2024 20:44
@rootulp rootulp requested review from cmwaters, evan-forbes, staheri14, rach-id and ninabarbakadze and removed request for a team September 26, 2024 20:44
@rootulp rootulp enabled auto-merge (squash) September 26, 2024 20:53
Comment on lines +37 to +39
stateProvider.On("State", mock.AnythingOfType("*context.timerCtx"), uint64(1)).Return(sm.State{}, nil)
stateProvider.On("State", mock.AnythingOfType("*context.timerCtx"), uint64(2)).Return(sm.State{}, nil)
stateProvider.On("State", mock.AnythingOfType("*context.timerCtx"), uint64(4)).Return(sm.State{}, nil)
Copy link
Member

Choose a reason for hiding this comment

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

why is this being called three times? if I understand correctly, only the uint64(4) will be provided, no?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

IIRC the test calls it a few times with different block heights.

@rootulp rootulp merged commit 66a9417 into celestiaorg:v0.34.x-celestia Sep 30, 2024
19 checks passed
@rootulp rootulp deleted the rp/state-sync-app-version branch September 30, 2024 18:01
rootulp added a commit to celestiaorg/celestia-app that referenced this pull request Oct 2, 2024
Closes #3818
~~Blocked on celestiaorg/celestia-core#1477

I had to bump the celestia-core depedency to get a feature that I
wanted. That implied upgrading Go and cosmos-sdk versions.

## Testing

I verified that logs added in this PR show up when state syncing on
Mocha. The logs show that the app version provided in the
`OfferSnapshot` ABCI method was plumbed through correctly.

```
./scripts/mocha.sh
...
2:44PM INF Offering snapshot to ABCI app format=2 hash="$�ڢ�\x1b� �zΊ\x15���`��왹\b^G:\x03+ߢޯ" height=2782000 module=statesync
2:44PM INF offering snapshot app_version=2 height=2782000
2:44PM INF mounting keys for snapshot app_version=2
```
mergify bot pushed a commit to celestiaorg/celestia-app that referenced this pull request Oct 2, 2024
Closes #3818
~~Blocked on celestiaorg/celestia-core#1477

I had to bump the celestia-core depedency to get a feature that I
wanted. That implied upgrading Go and cosmos-sdk versions.

## Testing

I verified that logs added in this PR show up when state syncing on
Mocha. The logs show that the app version provided in the
`OfferSnapshot` ABCI method was plumbed through correctly.

```
./scripts/mocha.sh
...
2:44PM INF Offering snapshot to ABCI app format=2 hash="$�ڢ�\x1b� �zΊ\x15���`��왹\b^G:\x03+ߢޯ" height=2782000 module=statesync
2:44PM INF offering snapshot app_version=2 height=2782000
2:44PM INF mounting keys for snapshot app_version=2
```

(cherry picked from commit 73793b9)

# Conflicts:
#	.github/workflows/lint.yml
#	Makefile
#	docker/txsim/Dockerfile
#	go.mod
#	go.sum
rootulp added a commit to celestiaorg/celestia-app that referenced this pull request Oct 4, 2024
…3936)

Closes #3818
~~Blocked on celestiaorg/celestia-core#1477

I had to bump the celestia-core depedency to get a feature that I
wanted. That implied upgrading Go and cosmos-sdk versions.

## Testing

I verified that logs added in this PR show up when state syncing on
Mocha. The logs show that the app version provided in the
`OfferSnapshot` ABCI method was plumbed through correctly.

```
./scripts/mocha.sh
...
2:44PM INF Offering snapshot to ABCI app format=2 hash="$�ڢ�\x1b� �zΊ\x15���`��왹\b^G:\x03+ߢޯ" height=2782000 module=statesync
2:44PM INF offering snapshot app_version=2 height=2782000
2:44PM INF mounting keys for snapshot app_version=2
```<hr>This is an automatic backport of pull request #3871 done by
[Mergify](https://mergify.com).

---------

Co-authored-by: Rootul P <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants