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

[Block] Generate block and provide block-related RPC #2967

Open
baichuan3 opened this issue Nov 27, 2024 · 3 comments
Open

[Block] Generate block and provide block-related RPC #2967

baichuan3 opened this issue Nov 27, 2024 · 3 comments
Assignees
Labels
area:rpc RPC relative issues feature New feature skill::rust Need the rust language skill to complete the issue
Milestone

Comments

@baichuan3
Copy link
Collaborator

baichuan3 commented Nov 27, 2024

Proposal Details

  1. Processing block generation logic
  2. Providing an RPC API for querying the latest block height
  3. Providing an RPC API for querying block Meta information, querying by height
  4. Providing an RPC API for batch acquisition of block info, pagination by height
@baichuan3 baichuan3 added feature New feature skill::rust Need the rust language skill to complete the issue area:rpc RPC relative issues labels Nov 27, 2024
@baichuan3 baichuan3 added this to Rooch Nov 27, 2024
@popcnt1
Copy link
Collaborator

popcnt1 commented Nov 27, 2024

#2960

@popcnt1
Copy link
Collaborator

popcnt1 commented Nov 28, 2024

Is it possible to finalize the required data structures?Submit a PR for the interface to be implemented, and then I'll see if it needs to be tweaked on the SCC side or if it can be implemented directly. @baichuan3

@popcnt1 popcnt1 added this to the Rooch v0.9 milestone Nov 28, 2024
@popcnt1 popcnt1 moved this to In Progress in Rooch Nov 28, 2024
@baichuan3
Copy link
Collaborator Author

The block field is required for finality, and other fields do not need to be processed by finality. @popcnt1

#[derive(Debug, Serialize, Deserialize)]
pub struct Block {
    #[serde(rename = "block_hash")]
    pub block_hash: String,
    #[serde(rename = "block_height")]
    pub block_height: u64,
    #[serde(rename = "block_timestamp")]
    pub block_timestamp: u64,
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:rpc RPC relative issues feature New feature skill::rust Need the rust language skill to complete the issue
Projects
Status: In Progress
Development

No branches or pull requests

2 participants