Skip to content

Conversation

@mcelrath
Copy link
Collaborator

@mcelrath mcelrath commented Sep 9, 2025

No description provided.

Copilot AI review requested due to automatic review settings September 9, 2025 18:03
Copy link

Copilot AI left a 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 PR fixes the position of the "cpunet" prefix in the block hash calculation, moving it from the beginning to the end of the preimage data as indicated by the title.

  • Moves the "cpunet\0" string from before the header fields to after them in the hash calculation
  • Corrects the order of data being hashed to match the expected protocol specification

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@Sansh2356 Sansh2356 assigned Sansh2356 and unassigned Sansh2356 Sep 9, 2025
@Sansh2356 Sansh2356 self-requested a review September 9, 2025 18:17
Copy link

@Sansh2356 Sansh2356 left a comment

Choose a reason for hiding this comment

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

Indeed causing the block hash mismatch on server side .

@Sansh2356 Sansh2356 merged commit 156f317 into cpunet Sep 9, 2025
10 of 24 checks passed
@Sansh2356 Sansh2356 deleted the cpunet_fixpreimage branch September 9, 2025 18:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants