Skip to content

docs: add troubleshooting guide and expand setup instructions - #1990

Open
efekrbas wants to merge 19 commits into
midnightntwrk:mainfrom
efekrbas:docs/improve-setup-troubleshooting
Open

docs: add troubleshooting guide and expand setup instructions#1990
efekrbas wants to merge 19 commits into
midnightntwrk:mainfrom
efekrbas:docs/improve-setup-troubleshooting

Conversation

@efekrbas

@efekrbas efekrbas commented Aug 5, 2026

Copy link
Copy Markdown

Overview

This PR improves the developer onboarding experience and fixes broken documentation links. Specifically, it:

  • Expands docs/rust-setup.md into a comprehensive Prerequisites & Setup guide, adding missing setup steps for Earthly, Just, and Nix which are critical for the node build.
  • Creates a new docs/troubleshooting.md guide that aggregates common build and setup errors (WASM memmove compilation error, ledger upgrade issues, Earthly build failures, SSL connection errors).
  • Fixes a broken link to testing-upgrades.md in docs/development-workflow.md by pointing to the correct fork-testing.md guide for hardfork upgrades.
  • Updates the main README.md to reflect the new Troubleshooting guide and the renamed Setup section.

🗹 TODO before merging

  • Ready

📌 Submission Checklist

  • All commits are signed off (git commit -s) for the DCO
  • Changes are backward-compatible (or flagged if breaking)
  • Pull request description explains why the change is needed
  • Self-reviewed the diff
  • I have included a change file, or skipped for this reason: docs only
  • If the changes introduce a new feature, I have bumped the node minor version
  • Update documentation (if relevant)
  • Updated AGENTS.md if build commands, architecture, or workflows changed
  • No new todos introduced

🧪 Testing Evidence

N/A - Documentation updates only.

🔱 Fork Strategy

  • Node Runtime Update
  • Node Client Update
  • Other:
  • N/A

@efekrbas
efekrbas requested a review from a team as a code owner August 5, 2026 08:03

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 214f2708ae

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment thread docs/rust-setup.md Outdated
Comment thread docs/troubleshooting.md Outdated
@efekrbas

efekrbas commented Aug 5, 2026

Copy link
Copy Markdown
Author

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 2901d3b907

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment thread docs/troubleshooting.md Outdated
Assisted-by: Gemini:gemini-3.1-pro
@efekrbas

efekrbas commented Aug 5, 2026

Copy link
Copy Markdown
Author

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Nice work!

Reviewed commit: 47c72d8d1d

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 26ce4945c7

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment thread docs/troubleshooting.md Outdated
@efekrbas

efekrbas commented Aug 9, 2026

Copy link
Copy Markdown
Author

@codex review

I, Efe Kýrbaþ <efekrbass@gmail.com>, hereby add my Signed-off-by to this commit: 214f270
I, Efe Kýrbaþ <efekrbass@gmail.com>, hereby add my Signed-off-by to this commit: 2901d3b
I, Efe Kýrbaþ <efekrbass@gmail.com>, hereby add my Signed-off-by to this commit: 47c72d8
I, Efe Kýrbaþ <efekrbass@gmail.com>, hereby add my Signed-off-by to this commit: bd84c39

Signed-off-by: Efe Kýrbaþ <efekrbass@gmail.com>
I, Efe Kırbaş <efekrbass@gmail.com>, hereby add my Signed-off-by to this commit: 214f270
I, Efe Kırbaş <efekrbass@gmail.com>, hereby add my Signed-off-by to this commit: 2901d3b
I, Efe Kırbaş <efekrbass@gmail.com>, hereby add my Signed-off-by to this commit: 47c72d8
I, Efe Kırbaş <efekrbass@gmail.com>, hereby add my Signed-off-by to this commit: bd84c39
I, Efe Kırbaş <efekrbass@gmail.com>, hereby add my Signed-off-by to this commit: 9abf549

Signed-off-by: Efe Kırbaş <efekrbass@gmail.com>

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: bd84c39738

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment thread docs/troubleshooting.md Outdated
Assisted-by: Antigravity:Gemini-3.1-Pro
Signed-off-by: Efe Kırbaş <efekrbass@gmail.com>
@efekrbas

efekrbas commented Aug 9, 2026

Copy link
Copy Markdown
Author

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 786b3bee89

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment thread docs/rust-setup.md
## Midnight-Specific Setup
### 2. Earthly (Containerized Builds)

Earthly is required for building Docker images, regenerating metadata, and rebuilding genesis state.

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Include Docker before Earthly-only setup

On a clean macOS/Linux machine following this setup page, installing only the Earthly binary is not enough for the repo targets this paragraph sends developers to use: the Earthfile builds images and runs containerized targets, so earthly +... fails unless Docker or another supported container backend is installed and running. The WSL note mentions Docker Desktop, but the macOS/Linux paths never add the same prerequisite, so add a Docker/podman install step before verifying Earthly.

Useful? React with 👍 / 👎.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: aeaf9398cd

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment thread docs/rust-setup.md Outdated
@efekrbas

Copy link
Copy Markdown
Author

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 13ef2cf9fd

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment thread docs/rust-setup.md Outdated
Comment thread docs/rust-setup.md Outdated
@efekrbas

Copy link
Copy Markdown
Author

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 2bfd91495d

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment thread docs/rust-setup.md Outdated
@efekrbas

Copy link
Copy Markdown
Author

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 9ba9b08a4a

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment thread docs/rust-setup.md Outdated
@efekrbas

Copy link
Copy Markdown
Author

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: dd18f6e2d9

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment thread docs/rust-setup.md
A bare `cargo test` fails on fresh setups because midnight-node-toolkit depends on generated toolkit-js npm artifacts. The Earthfile +test target explicitly excludes it. Replace with `cargo check` as the smoke test and document proper test commands.

Assisted-by: Claude:claude-opus-4-20250514
Signed-off-by: Efe Kırbaş <efekrbass@gmail.com>
The earthly +test target requires --secret DOCKERHUB_USER= --secret DOCKERHUB_TOKEN= flags even for local runs. The direct cargo command now uses cargo nextest with the full -E filter from the Earthfile to skip fixture-dependent pallet tests (test_get_contract_state, test_send_mn_transaction, test_validation_works).

Assisted-by: Claude:claude-opus-4-20250514
Signed-off-by: Efe Kırbaş <efekrbass@gmail.com>
…ation

cargo-nextest is only installed inside the Earthly CI image, not available on a fresh local setup. Switch to plain `cargo test` with --skip flags for the fixture-dependent tests.

Assisted-by: Claude:claude-opus-4-20250514
Signed-off-by: Efe Kırbaş <efekrbass@gmail.com>
The hardcoded earthly-linux-amd64 URL fails on ARM64 Linux hosts. Use uname -m to detect the architecture and download the correct binary (amd64 or arm64).

Assisted-by: Claude:claude-opus-4-20250514
Signed-off-by: Efe Kırbaş <efekrbass@gmail.com>
@efekrbas
efekrbas force-pushed the docs/improve-setup-troubleshooting branch from dd18f6e to 5601477 Compare August 11, 2026 03:05
Earthly's WITH DOCKER feature (used in targets like +test) requires rootful Podman. Clarify this requirement in the setup instructions and add the command to start the rootful podman socket on Linux.

Assisted-by: Claude:claude-opus-4-20250514
Signed-off-by: Efe Kırbaş <efekrbass@gmail.com>
@efekrbas

Copy link
Copy Markdown
Author

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Another round soon, please!

Reviewed commit: d4755cce1b

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 4b43b88a1c

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment thread docs/rust-setup.md
> and the fixture-dependent tests:
>
> ```bash
> cargo test --workspace --locked \

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Run the direct test fallback in release mode

When developers choose the direct Cargo path here on a normal workstation, this runs the workspace tests in the debug profile, but the repo's Earthfile documents that debug/opt-level=1 test binaries can OOM the linker (>24GB) and the +test target instead sets opt-level 2 and runs cargo nextest ... --release (Earthfile:1110-1134). This fallback can therefore still fail for memory reasons unrelated to setup; mirror the release/RUSTFLAGS settings or avoid recommending a direct whole-workspace Cargo run.

Useful? React with 👍 / 👎.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant