Skip to content

Conversation

nhussein11
Copy link
Collaborator

@nhussein11 nhussein11 commented Jun 27, 2025

This PR fixes the zero to hero:

  • Reorders the steps to add the pallet to the runtime before benchmarking, or it breaks
  • Fixes snippets and highlights accordingly
  • Pins the frame-omni-bencher to version 0.10.0 to prevent error[E0432]: unresolved import sc_network_types::kad

This is needed to work on #689

@nhussein11 nhussein11 requested a review from brunopgalvao June 27, 2025 14:21
@nhussein11 nhussein11 self-assigned this Jun 27, 2025
@nhussein11 nhussein11 added the B0 - Needs Review Pull request is ready for review label Jun 27, 2025
@Copilot Copilot AI review requested due to automatic review settings June 27, 2025 14:21
@nhussein11 nhussein11 added C1 - Medium Medium priority task A1 - Maintenance Major Pull request contains major updates to an existing page (i.e., adding a new section, reorgs, etc.) labels Jun 27, 2025
@nhussein11 nhussein11 requested a review from a team as a code owner June 27, 2025 14:21
Copy link
Contributor

@Copilot 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 ensures the Zero-to-Hero tutorials render correctly by pinning benchmark tooling, realigning code snippet references, and fixing navigation order.

  • Pin frame-omni-bencher to version 0.10.0
  • Update code snippet link ranges and highlight lines across tutorial markdowns
  • Remove a mis-indented duplicate entry in the tutorial navigation

Reviewed Changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated no comments.

Show a summary per file
File Description
pallet-unit-testing.md Adjusted snippet link line numbers by –1
pallet-benchmarking.md Pinned bencher version; updated highlight line ranges
build-custom-pallet.md Realigned snippet link ranges in examples
add-pallets-to-runtime.md Updated snippet ranges; clarified build command context
.pages Removed mis-indented duplicate navigation entry
Comments suppressed due to low confidence (1)

tutorials/polkadot-sdk/parachains/zero-to-hero/pallet-benchmarking.md:27

  • Consider adding a reminder before step 1 that the pallet must be added to the runtime and the runtime recompiled first, e.g.: “Ensure you’ve added your pallet to the runtime and run cargo build before benchmarking to prevent breakage.”
1. Install the [`frame-omni-bencher`](https://crates.io/crates/frame-omni-bencher){target=\_blank} command-line tool:

Copy link
Contributor

@brunopgalvao brunopgalvao left a comment

Choose a reason for hiding this comment

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

Screenshot 2025-07-01 at 10 04 48 AM
Where to Go Next in the Pallet Unit Testing section should point to Add Pallets to the Runtime otherwise users will get errors when running benchmarks.

Telucero
Telucero previously approved these changes Jul 1, 2025
Copy link
Contributor

@Telucero Telucero left a comment

Choose a reason for hiding this comment

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

Looks good!

Copy link

github-actions bot commented Jul 1, 2025

🔍 Documentation URL Checker

This PR modifies documentation files in ways that could potentially create broken links.

Deleted files:

develop/smart-contracts/dev-environments/foundry.md

🚨 Please review these changes carefully 🚨

If not handled properly, broken links (404 errors) could appear. To maintain a smooth user experience, consider:

  • Adding redirects in the mkdocs.yml file from the old URLs to the new ones
  • Updating internal references to these files

Copy link
Contributor

@Telucero Telucero left a comment

Choose a reason for hiding this comment

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

Checked and everything seems good to go.

@Telucero Telucero added B1 - Ready to Merge Pull request is ready to be merged and removed B0 - Needs Review Pull request is ready for review labels Jul 3, 2025
@nhussein11 nhussein11 merged commit 70aca9e into master Jul 7, 2025
3 checks passed
@nhussein11 nhussein11 deleted the nhussein11/fix-zero-to-hero-snippets branch July 7, 2025 18:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A1 - Maintenance Major Pull request contains major updates to an existing page (i.e., adding a new section, reorgs, etc.) B1 - Ready to Merge Pull request is ready to be merged C1 - Medium Medium priority task
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants