-
Notifications
You must be signed in to change notification settings - Fork 8
decentralized computer #99
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: main
Are you sure you want to change the base?
Conversation
common/mixin.go
Outdated
@@ -150,6 +151,10 @@ func SendTransactionUntilSufficient(ctx context.Context, client *mixin.Client, m | |||
} | |||
utxos, sufficient := getEnoughUtxosToSpend(utxos, amount) | |||
if !sufficient { | |||
retry += 1 | |||
if retry == 10 { | |||
return nil, fmt.Errorf("unsufficient balance: %s %s", assetId, amount.String()) |
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.
why not just wait?
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.
it will be stuck here If no balance
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.
That's the purpose of this function.
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.
Pull Request Overview
This pull request implements a decentralized computer solution by introducing new functionalities across the system including Solana tests and operations, updated request handling, FROST-based keygen/signing, and various RPC and instruction builders across Solana, Ethereum, and Mixin.
- Added comprehensive tests and new functions in computer/solana_test.go for blockchain transactions.
- Introduced new interfaces, HTTP endpoints, and configuration updates in the computer package.
- Expanded support for token transfers and associated token account instructions in Solana and Ethereum integrations.
Reviewed Changes
Copilot reviewed 73 out of 73 changed files in this pull request and generated 2 comments.
Show a summary per file
File | Description |
---|---|
computer/solana_test.go | New tests for Solana operations, including FROST sign validation. |
computer/request.go | Request parsing and error handling improvements. |
computer/node.go | Node boot and member management logic. |
computer/interface.go | Configuration struct and interface for messenger, with some naming issues. |
computer/icon.go | Asset icon processing with image masking and webp encoding. |
computer/http.go | HTTP server endpoints for user, asset, and system call operations. |
computer/group.go | Group action processing and request validation logic. |
computer/frost.go | FROST keygen and signing implementations. |
computer/README.md | Documentation update reflecting recent changes and instructions. |
common/util.go | Utility function additions for mixin integration. |
common/mixin.go | Mixin-related RPC and asset functions revisions. |
cmd/computer.go | CLI command to boot up the computer node with configuration changes. |
apps/solana/token2022_transferChecked.go | New Solana instruction for Token2022 transfer with checks. |
apps/solana/token2022_ata.go | New instruction builder for creating associated token accounts. |
apps/solana/rpc.go | Extended Solana RPC client functions and address lookup handling. |
apps/mixin/common.go | ED25519 child key derivation functions. |
apps/ethereum/transaction.go | Updated Ethereum transaction creation and error messages. |
apps/ethereum/rpc.go | Consistency improvements in Ethereum RPC error messages. |
.github/workflows/test.yml | Added test job for the computer package. |
Comments suppressed due to low confidence (1)
cmd/computer.go:76
- [nitpick] Using 'computer' as both the package name and the variable name can be confusing; consider renaming the variable to something like 'nodeInstance' to improve clarity.
computer := computer.NewNode(kd, group, messenger, mc.Computer, client)
No description provided.