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 rebased go-tss library #2514

Merged
merged 2 commits into from
Jul 19, 2024
Merged

chore: use rebased go-tss library #2514

merged 2 commits into from
Jul 19, 2024

Conversation

gartnera
Copy link
Member

@gartnera gartnera commented Jul 18, 2024

Description

Use rebased go-tss library which has all upstream fixes and most of our updates. This branch is passing all unit tests in CI unlike master. If/when this PR is approved/merged I will force push this new branch to master.

Related to:

How Has This Been Tested?

  • Tested CCTX in localnet
  • Tested in development environment
  • Go unit tests
  • Go integration tests
  • Tested via GitHub Actions

Summary by CodeRabbit

  • Chores
    • Updated import paths for various TSS-related packages to reflect new repository locations.
    • Removed deprecated imports and updated function signatures to ensure compatibility with the new package versions.

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

coderabbitai bot commented Jul 18, 2024

Walkthrough

The updates primarily involve changing import paths for various TSS-related packages to new locations in the gitlab.com/thorchain namespace. These modifications affect multiple files across different directories, ensuring consistency with the new repository structure. Additionally, some type adjustments were made to accommodate the updated packages.

Changes

File Path Change Summary
cmd/zetaclientd/gen_pre_params.go Updated import path for keygen from github.com/binance-chain/tss-lib/ecdsa/keygen to gitlab.com/thorchain/tss/tss-lib/ecdsa/keygen.
cmd/zetaclientd/keygen_tss.go Changed import paths for TSS-related packages to gitlab.com/thorchain/tss/go-tss.
cmd/zetaclientd/main.go Modified import path for ecdsakeygen to gitlab.com/thorchain/tss/tss-lib/ecdsa/keygen.
cmd/zetaclientd/p2p_diagnostics.go Removed import of github.com/zeta-chain/go-tss/p2p and updated function signatures to use []maddr.Multiaddr.
cmd/zetaclientd/start.go Removed core and p2p import paths, and replaced Multiaddr with []maddr.Multiaddr.
go.mod Made various package replacements and additions.
x/observer/client/cli/tx_vote_blame.go Updated import path for blame to gitlab.com/thorchain/tss/go-tss/blame.
x/observer/types/utils.go Updated import path for blame to gitlab.com/thorchain/tss/go-tss/blame.
x/observer/types/utils_test.go Changed import path for blame to gitlab.com/thorchain/tss/go-tss/blame.
zetaclient/chains/interfaces/interfaces.go Updated import path for blame to gitlab.com/thorchain/tss/go-tss/blame.
zetaclient/testutils/mocks/zetacore_client.go Updated import path for blame to gitlab.com/thorchain/tss/go-tss/blame.
zetaclient/tss/tss_signer.go Modified import paths for TSS-related packages to gitlab.com/thorchain/tss/go-tss.
zetaclient/zetacore/client_vote.go Updated import path for blame to gitlab.com/thorchain/tss/go-tss/blame.
zetaclient/zetacore/tx_test.go Changed import path for blame to gitlab.com/thorchain/tss/go-tss/blame.

Poem

In the code a shift so bright,
Paths now change, a new insight.
From GitHub to GitLab's shore,
New journeys for our code to explore.
With every line and every byte,
Our software gains a new flight.
🎉✨


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 as 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.

Additionally, you can add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

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 force-pushed the use-rebased-go-tss branch from b6f14b1 to ec0a9f9 Compare July 18, 2024 21:47
@gartnera gartnera marked this pull request as ready for review July 18, 2024 22:16
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: 0

Review details

Configuration used: .coderabbit.yaml
Review profile: CHILL

Commits

Files that changed from the base of the PR and between 8019ea2 and 0057453.

Files ignored due to path filters (1)
  • go.sum is excluded by !**/*.sum
Files selected for processing (14)
  • cmd/zetaclientd/gen_pre_params.go (1 hunks)
  • cmd/zetaclientd/keygen_tss.go (1 hunks)
  • cmd/zetaclientd/main.go (1 hunks)
  • cmd/zetaclientd/p2p_diagnostics.go (4 hunks)
  • cmd/zetaclientd/start.go (3 hunks)
  • go.mod (7 hunks)
  • x/observer/client/cli/tx_vote_blame.go (1 hunks)
  • x/observer/types/utils.go (1 hunks)
  • x/observer/types/utils_test.go (1 hunks)
  • zetaclient/chains/interfaces/interfaces.go (1 hunks)
  • zetaclient/testutils/mocks/zetacore_client.go (1 hunks)
  • zetaclient/tss/tss_signer.go (2 hunks)
  • zetaclient/zetacore/client_vote.go (1 hunks)
  • zetaclient/zetacore/tx_test.go (1 hunks)
Additional context used
Path-based instructions (13)
x/observer/types/utils.go (1)

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

cmd/zetaclientd/gen_pre_params.go (1)

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

cmd/zetaclientd/main.go (1)

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

x/observer/types/utils_test.go (1)

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

x/observer/client/cli/tx_vote_blame.go (1)

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

zetaclient/zetacore/client_vote.go (1)

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

cmd/zetaclientd/p2p_diagnostics.go (1)

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

zetaclient/chains/interfaces/interfaces.go (1)

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

cmd/zetaclientd/keygen_tss.go (1)

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

cmd/zetaclientd/start.go (1)

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

zetaclient/zetacore/tx_test.go (1)

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

zetaclient/testutils/mocks/zetacore_client.go (1)

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

zetaclient/tss/tss_signer.go (1)

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

Additional comments not posted (25)
x/observer/types/utils.go (2)

3-3: Update import path due to repository migration.

The import path has been updated to reflect the new repository location.


Line range hint 5-14:
LGTM!

The ConvertNodes function is correct and efficient.

cmd/zetaclientd/gen_pre_params.go (2)

10-10: Update import path due to repository migration.

The import path has been updated to reflect the new repository location.


Line range hint 12-34:
LGTM!

The command GenPrePramsCmd is correctly defined and handles file operations and error handling appropriately.

cmd/zetaclientd/main.go (2)

11-11: Update import path due to repository migration.

The import path has been updated to reflect the new repository location.


Line range hint 13-23:
LGTM!

The main function is correctly defined and handles command execution and error handling appropriately.

x/observer/types/utils_test.go (2)

7-7: Update import path due to repository migration.

The import path has been updated to reflect the new repository location.


Line range hint 10-43:
LGTM!

The test cases for ConvertNodes are comprehensive and correctly defined.

x/observer/client/cli/tx_vote_blame.go (1)

15-15: LGTM! Import path update is correct.

The import path change aligns with the PR objective to use the rebased go-tss library.

zetaclient/zetacore/client_vote.go (1)

7-7: LGTM! Import path update is correct.

The import path change aligns with the PR objective to use the rebased go-tss library.

cmd/zetaclientd/p2p_diagnostics.go (3)

30-30: Change in parameter type for peers is correct.

The change from p2p.AddrList to []maddr.Multiaddr aligns with the updated import paths and types.


62-62: Change in variable type for externalAddr is correct.

The change from Multiaddr to maddr.Multiaddr aligns with the updated import paths and types.


74-76: Change in parameter type for AddrsFactory function is correct.

The change from []Multiaddr to []maddr.Multiaddr aligns with the updated import paths and types.

zetaclient/chains/interfaces/interfaces.go (1)

19-19: LGTM! Import path update is correct.

The import path change aligns with the PR objective to use the rebased go-tss library.

cmd/zetaclientd/keygen_tss.go (1)

12-14: LGTM!

The import paths have been correctly updated to reflect the repository migration.

cmd/zetaclientd/start.go (2)

Line range hint 1-1:
LGTM!

The import paths for core and p2p packages have been correctly removed.


360-367: LGTM!

The function signature of initPeers has been correctly updated to return a slice of maddr.Multiaddr.

go.mod (4)

22-22: LGTM!

The dependency gitlab.com/thorchain/tss/go-tss has been correctly added.


22-22: LGTM!

The dependency github.com/zeta-chain/go-tss has been correctly removed.


68-68: LGTM!

The dependency gitlab.com/thorchain/tss/tss-lib has been correctly added.


354-354: LGTM!

The replacement for github.com/binance-chain/tss-lib with gitlab.com/thorchain/tss/tss-lib v0.1.5 has been correctly added.

zetaclient/zetacore/tx_test.go (1)

23-23: LGTM!

The import path for the blame package has been correctly updated to reflect the repository migration.

zetaclient/testutils/mocks/zetacore_client.go (1)

6-6: Update import path for blame package.

The import path for the blame package has been updated to gitlab.com/thorchain/tss/go-tss/blame. Ensure this path is correct and consistent with the new repository structure.

zetaclient/tss/tss_signer.go (2)

23-23: Add new import for go-multiaddr.

The go-multiaddr package has been added as a new import. Ensure this is necessary and correctly used in the code.


26-29: Update import paths for TSS-related packages.

The import paths for common, keysign, tss, and keygen packages have been updated to the new repository locations in the gitlab.com/thorchain namespace. Ensure these paths are correct and consistent with the new repository structure.

@gartnera gartnera added this pull request to the merge queue Jul 19, 2024
Merged via the queue into develop with commit 129c99b Jul 19, 2024
33 checks passed
@gartnera gartnera deleted the use-rebased-go-tss branch July 19, 2024 16:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
breaking:cli no-changelog Skip changelog CI check UPGRADE_LIGHT_TESTS Run make start-upgrade-test-light
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants