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

chore: use v19 binaries in upgrade tests #2689

Merged
merged 1 commit into from
Sep 9, 2024
Merged

Conversation

gartnera
Copy link
Member

@gartnera gartnera commented Aug 12, 2024

Blocked by: https://github.com/zeta-chain/infrastructure/issues/1523
Blocked by: #2827

Running with the v19 state export now (state-export-v19-H4699407-2024-09-04_23-27.json)

Summary by CodeRabbit

  • New Features

    • Upgraded the application to utilize the latest version of zetanode (v19.1.1), enhancing functionality and compatibility.
  • Bug Fixes

    • Streamlined the upgrade handling process by removing unnecessary complexity in the setup handlers, potentially improving performance and reliability during upgrades.

@gartnera gartnera added no-changelog Skip changelog CI check UPGRADE_LIGHT_TESTS Run make start-upgrade-test-light labels Aug 12, 2024
Copy link
Contributor

coderabbitai bot commented Aug 12, 2024

Walkthrough

Walkthrough

The changes involve an update to the Makefile to upgrade the version of zetanode from v18 to v19, affecting both source builds and binary downloads. Additionally, significant modifications were made to the SetupHandlers function in app/setup_handlers.go, where code related to parameter key table management and forced migration logic was removed, streamlining the upgrade handling process.

Changes

File Change Summary
Makefile Updated OLD_VERSION from release/v18 to release/v19 for source builds and binary URLs.
app/setup_handlers.go Removed code for parameter key table management and forced migration, simplifying the upgrade process.

Sequence Diagram(s)

sequenceDiagram
    participant User
    participant App
    participant ZetaNode

    User->>App: Initiate Upgrade
    App->>ZetaNode: Build from Source (v19)
    App->>ZetaNode: Download Binary (v19.1.1)
    ZetaNode-->>App: Upgrade Complete
    App-->>User: Notify Upgrade Success
Loading

Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?

Share
Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai generate interesting stats about this repository and render them as a table.
    • @coderabbitai show all the console.log statements in this repository.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

@gartnera gartnera mentioned this pull request Aug 29, 2024
11 tasks
@gartnera gartnera added UPGRADE_IMPORT_MAINNET_TESTS Run make start-upgrade-import-mainnet-test blocked labels Sep 4, 2024
@gartnera gartnera removed the blocked label Sep 5, 2024
@gartnera gartnera marked this pull request as ready for review September 5, 2024 16:33
Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

Outside diff range, codebase verification and nitpick comments (1)
app/setup_handlers.go (1)

Line range hint 47-47: Improve error handling strategy.

The use of panic for handling errors retrieved from getIncrementalUpgrades might not be the best approach in a production environment. Consider implementing a more graceful error handling mechanism that could include:

  • Logging the error and continuing with a default or safe operation.
  • Returning the error to the caller if the function's design allows for it, enabling the caller to decide on the appropriate action.

Also applies to: 50-50

Review details

Configuration used: .coderabbit.yaml
Review profile: CHILL

Commits

Files that changed from the base of the PR and between 274c1bf and 4803c8a.

Files selected for processing (2)
  • Makefile (1 hunks)
  • app/setup_handlers.go (2 hunks)
Additional context used
Path-based instructions (1)
app/setup_handlers.go (1)

Pattern **/*.go: Review the Go code, point out issues relative to principles of clean code, expressiveness, and performance.

Additional comments not posted (3)
app/setup_handlers.go (1)

Line range hint 58-58: Upgrade handler setup appears robust, suggest thorough testing.

The setup of the upgrade handler and the integration with the application's lifecycle are well-implemented. However, given the critical nature of upgrade processes, it is recommended to ensure that this setup is thoroughly tested. This includes:

  • Unit tests covering various scenarios and edge cases.
  • Integration tests that simulate actual upgrade processes from previous versions to the current one.

Also applies to: 68-68

Makefile (2)

296-296: Update to v19 binaries for building from source.

The change to use release/v19 for the OLD_VERSION argument when building from source aligns with the PR's objective to update the upgrade tests to utilize v19 binaries. This ensures that the tests are run against the latest version, which is crucial for maintaining the integrity and performance of the upgrade tests.


301-301: Update to v19.1.1 binaries for building from binaries.

The update to point to the v19.1.1 binaries via the URL https://github.com/zeta-chain/node/releases/download/v19.1.1 is a critical change. This ensures that the binaries used in the upgrade tests are the latest, reflecting the changes and improvements made in the new version. It is important to verify that all dependencies and configurations are compatible with this new version to avoid potential integration issues.

Run the following script to verify the compatibility of the new binaries with existing configurations:

app/setup_handlers.go Show resolved Hide resolved
@gartnera gartnera enabled auto-merge September 6, 2024 18:33
@gartnera gartnera added this pull request to the merge queue Sep 9, 2024
Merged via the queue into develop with commit 38dd989 Sep 9, 2024
37 checks passed
@gartnera gartnera deleted the upgrade-tests-v19 branch September 9, 2024 10:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
no-changelog Skip changelog CI check UPGRADE_IMPORT_MAINNET_TESTS Run make start-upgrade-import-mainnet-test UPGRADE_LIGHT_TESTS Run make start-upgrade-test-light
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants