[codex] warn when layout is missing Board macro#802
Open
lucia3e8 wants to merge 1 commit into
Open
Conversation
fd17b69 to
0b6e0a0
Compare
0b6e0a0 to
c69899f
Compare
Build Performance
Measured with hyperfine. Times show median ±stddev. |
akhilles
approved these changes
May 13, 2026
akhilles
left a comment
Contributor
There was a problem hiding this comment.
--- STDERR ---
Warning: layout generation needs a root `Board` macro with `layout_path`
╭─[ bad_layout_path.zen:6:24 ]
│
6 │ signal = Net("SIGNAL")
│ │
│ ╰─ insert the board declaration here
│
│ Help: add this to bad_layout_path.zen:
│ Board(name="bad_layout_path", layers=4, layout_path="layout/bad_layout_path")
───╯
span should probably point to a new line
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
pcb layoutbuilds a schematic that has no rootBoard/layout_path, instead of silently doing nothing.Board(...)suggestion derived from the.zenfilename.Why
Without a root board declaration, layout generation has no destination directory, so
pcb layoutreturns successfully without producing files. The new warning explains that requirement and gives the user a directly usable board declaration.Validation
cargo fmtcargo test -p pcb --test layoutcargo run -p pcb -- layout --no-open boost_5v.zenfromexamples/os_13_4Note
Low Risk
Low risk: adds a non-fatal CLI warning path when layout generation produces no output, plus tests; minimal impact on core layout sync behavior.
Overview
pcb layoutnow emits an Ariadne-rendered warning when layout generation returns no result and the schematic lacks a rootBoardmacro with a stringlayout_path, including a suggestedBoard(...)insertion derived from the.zenfilename.Adds
ariadneas a dependency, updates the changelog entry, and introduces snapshot tests covering missing/invalidlayout_pathcases.Reviewed by Cursor Bugbot for commit c69899f. Bugbot is set up for automated code reviews on this repo. Configure here.