Skip to content

Rename to hre.network.create() in markdown docs#1273

Open
ericglau wants to merge 1 commit into
OpenZeppelin:masterfrom
ericglau:renamehrecreate
Open

Rename to hre.network.create() in markdown docs#1273
ericglau wants to merge 1 commit into
OpenZeppelin:masterfrom
ericglau:renamehrecreate

Conversation

@ericglau
Copy link
Copy Markdown
Member

@ericglau ericglau commented Jun 3, 2026

Use hre.network.create() instead of the deprecated hre.network.connect() in the README, MIGRATION guide, and changelog.

Summary by CodeRabbit

  • Documentation
    • Updated Hardhat 3 migration documentation (CHANGELOG, MIGRATION guide, and README) with corrected network connection setup examples throughout. All code samples across scripts, tasks, tests, and proxy deployment scenarios now demonstrate the accurate API method for properly creating and managing shared network connections.

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Jun 3, 2026

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 46e0f8f4-38b1-4e40-b4b1-98a28141b503

📥 Commits

Reviewing files that changed from the base of the PR and between a4562e9 and 817fab9.

📒 Files selected for processing (3)
  • packages/plugin-hardhat/CHANGELOG.md
  • packages/plugin-hardhat/MIGRATION.md
  • packages/plugin-hardhat/README.md

Walkthrough

All documentation files in the Hardhat plugin package are updated to reflect the correct Hardhat 3 network API. The single change pattern—replacing hre.network.connect() with await hre.network.create()—is applied consistently across CHANGELOG, MIGRATION, and README to ensure users follow the correct connection-creation pattern.

Changes

Hardhat Network API Documentation Update

Layer / File(s) Summary
Changelog breaking-change notice
packages/plugin-hardhat/CHANGELOG.md
CHANGELOG entry updated to document the correct Hardhat 3 network API for creating and sharing a network connection using await hre.network.create().
Migration guide with updated connection examples
packages/plugin-hardhat/MIGRATION.md
Migration guide examples updated across update-usage snippet, scripts, tasks, test before-hook, top-level-await test, and checklist to use async hre.network.create() for connection creation.
README proxy deployment examples
packages/plugin-hardhat/README.md
README examples for transparent-proxy and beacon-proxy script and test creation updated to use await hre.network.create() for shared network connection setup.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

Poem

🐰 Through Hardhat's fields, the API grew,
hre.network.create() now shines so true,
A simpler dance, both clean and bright,
These docs now guide each dev right!

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately and specifically describes the main change: updating markdown documentation files to use hre.network.create() instead of the deprecated hre.network.connect().
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Comment @coderabbitai help to get the list of available commands and usage tips.

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.

1 participant