-
Notifications
You must be signed in to change notification settings - Fork 34
feat(core): multisig Signers #349
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
base: releases/next
Are you sure you want to change the base?
Conversation
🦋 Changeset detectedLatest commit: a137473 The changes in this PR will be included in the next version bump. This PR includes changesets to release 20 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
✅ Deploy Preview for liveccc ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
✅ Deploy Preview for apiccc ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
✅ Deploy Preview for docsccc ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
Summary of ChangesHello @Hanssen0, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request significantly enhances the core library by introducing robust support for CKB multisig transactions. It provides new abstract and concrete signer classes, refactors existing signing mechanisms for better modularity, and improves transaction witness argument handling. The changes aim to make multisig operations more accessible and reliable for developers, complete with illustrative examples. Highlights
🧠 New Feature in Public Preview: You can now enable Memory to help Gemini Code Assist learn from your team's feedback. This makes future code reviews more consistent and personalized to your project's style. Click here to enable Memory in your admin console. Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code Review
This pull request introduces multisig signer capabilities, which is a significant feature. The changes include new SignerMultisigCkbPrivateKey and SignerMultisigCkbReadonly classes, along with a new SignerMultisig abstract class. The implementation looks mostly correct, but I've found a few issues:
- A critical bug in
getSignaturesCountthat would cause incorrect signature counting. - A misleading example in
transaction.tsfor a new method. - Some minor issues like a
console.logand an incorrect error message. - I've also pointed out a potential API inconsistency in one of the new example files.
Please address these points to improve the quality and correctness of the code. Overall, good work on adding this complex feature.
✅ Deploy Preview for appccc ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
2d37e11 to
7e47bbe
Compare
|
Related to #196 @ashuralyk, please review. |
|
/gemini review |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code Review
This pull request introduces a significant feature: support for multisig signers in @ckb-ccc/core. It also includes a major dependency upgrade for @noble packages and a migration of the build system to tsdown. The core logic for creating, signing, and aggregating multisig transactions is well-implemented, and the refactoring to accommodate the new dependency versions is clean. My review includes a few suggestions to improve type safety and error message clarity.
7e47bbe to
5cd022e
Compare
|
/gemini review |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code Review
This pull request introduces significant new functionality by adding multisig signer support for CKB, a major feature for the core package. It also includes a substantial dependency upgrade for all @noble packages to their latest major versions and a migration of the build system to tsdown. The implementation of the multisig feature is well-structured, separating read-only and private key signing logic, and is accompanied by new tests and examples. The breaking changes from the dependency upgrades seem to be handled correctly throughout the codebase. My review includes a few suggestions to enhance maintainability and correct a minor documentation error.
5cd022e to
858410d
Compare
|
/gemini review |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code Review
This pull request introduces significant new functionality for multisig signers in the core package, which is a valuable addition. The implementation is well-structured, with clear abstractions for multisig signers and thorough handling of CKB-specific multisig logic, including witness encoding, signature aggregation, and transaction preparation.
The PR also includes a major version bump for @noble dependencies, and the necessary code adaptations for the new APIs are correctly implemented across the affected modules. The migration of the build process to tsdown is a good modernization step.
I have one suggestion for a minor refactoring to reduce code duplication. Overall, this is a high-quality contribution with good test coverage and examples for the new features.
902967f to
87e10d9
Compare
87e10d9 to
a137473
Compare

This PR should be reviewed one by one according to the commits.