Closed bug report

Board page with no declared symbol/footprint renders a guessed Symbol & Footprint panel from the design library

Drew Owens · 1mo ago ·closed by Colby Knox

A board page with NO declared symbol or footprint still renders a "Symbol & Footprint" panel, filled by guessing from the design library. The two parts it shows are unrelated to each other and to the board.

Reported by Ray on adom/feeder-reader#4.

The page (adom/feeder-reader, private):

  • type: "hardware", and metadata_json.path_b_board: true, so it declares itself a board (a 130 x 50 mm 4-layer PCBA).
  • symbol, footprint and assets are all null. The page declares no component-level assets at all.

What renders in the Symbol & Footprint section on Overview:

  • Schematic Symbol: AMS1117-3.3 (a 3-pin LDO regulator, shown with VI, VO, GND)
  • PCB Footprint: A2001WV-S-6P (a 6-pin connector, 8 pads)

Those are two different components, neither of which is the board.

Where the values come from. The repo ships the board's own KiCad design library, and the picks are simply the first entry in each:

  • feeder-reader-hardware/libraries/Feeder-Reader_KiCAD.pretty/ holds 10 footprints; A2001WV-S-6P.kicad_mod sorts first alphabetically.
  • feeder-reader-hardware/libraries/Feeder-Reader_KiCAD.kicad_sym holds 24 symbols; AMS1117-3.3 is the first one in the file.

So the panel is pairing the alphabetically-first footprint with the file-order-first symbol out of a multi-part library, and presenting the result as if it were this page's component.

Why it is wrong regardless of the picks. A PCBA has no single schematic symbol or PCB footprint; those are component properties. Shipping a design library is the normal thing for a board page to do, so any inference from that library will keep producing a wrong answer. Ray's own phrasing in the report was "should not show at all?", and that is the right instinct.

Suggested fix, in preference order:

  1. Render the Symbol & Footprint panel only when the page EXPLICITLY declares a symbol or footprint. Absent a declaration, show nothing.
  2. Additionally suppress it for board pages (path_b_board: true) even if a declaration exists, or at least stop treating a multi-symbol .kicad_sym library as a source for a single-symbol panel.
  3. If some inference is wanted for genuine component pages, only infer when the library contains exactly one symbol and one footprint, and never pair entries that come from different parts.

Happy to test on adom/feeder-reader once there is something to look at, since that page reproduces it directly.

5 Replies

Colby Knox · 1mo ago

Fixed on staging (git-wiki 072a3be; rides the next prod tag), per your first preference where it matters.

The panel's symbol and footprint came from the first .kicad_sym and .kicad_mod in the repo tree whenever the page declared none. Now:

  • A page whose kind is board, project, molecule or equipment, or whose metadata says path_b_board, gets no inference at all. Only a declared symbol or footprint renders. feeder-reader is a board, so the panel disappears there.
  • A plain component page that ships several symbols or footprints (a library) only takes the file named after the page; anything else is a guess and is left empty.
  • A component page with a single symbol and footprint still renders them, since that is the factory's shape and inference is right there.
Colby Knox · 1mo ago

On prod as of git-wiki aba6ac4 (18:25 today). Board, project, molecule and equipment pages get no symbol/footprint inference; a multi-part library only yields the file named after the page. Closing; reopen if it does not hold for you.

Drew Owens · 1mo ago

Reopening: this does not hold on adom/feeder-reader. Checked today, well after your prod tag aba6ac4 (Sep 3 18:25).

The gate inputs are satisfied. The live page still reports type: "hardware", metadata_json.path_b_board: true, and symbol: null / footprint: null. So by your rule it should get no inference and no panel.

What the page actually serves now:

  1. The section still renders in full: a TOC entry "Symbol & Footprint", and <section id="sec-data-symbol-footprint"> with <h2>Symbol & Footprint</h2> and two viewer cards.
  2. Both cards are iframes pointing at the viewer endpoints, and note the literal component segment in the paths the page emits:
    • /viewer/symbol/adom/component/feeder-reader?embed=1
    • /viewer/footprint/adom/component/feeder-reader?embed=1
  3. Those endpoints still infer AND render the same wrong parts. Fetching them directly returns real SVG, not an empty state:
    • symbol: <title>Schematic symbol of AMS1117-3.3, 3 pins</title>, download link .../Feeder-Reader_KiCAD.kicad_sym
    • footprint: <title>PCB footprint of A2001WV-S-6P, 8 pads</title>, download link .../Feeder-Reader_KiCAD.pretty/A2001WV-S-6P.kicad_mod

So AMS1117-3.3 no longer appears in the page HTML itself, which may be why it looked fixed, but it is still rendered inside the iframe.

My guess at the cause: the board gate landed on the page-level inference, while /viewer/<surface>/<owner>/component/<slug> is a second path that does its own inference, and the page hands it component as the kind regardless of the page actually being a board. Two code paths, one gated.

A third surface has the same guess, if you want to catch it in the same pass: the section's web-control action bar still stages the guessed files. Its data-actions for "Open in Footprint Editor" carries Feeder-Reader_KiCAD.pretty/A2001WV-S-6P.kicad_mod paired with Feeder-Reader_KiCAD.3dshapes/FTSH-107-01-L-DV-K.step, which are two unrelated parts.

One design note either way: even with inference fully suppressed, the section shell and its TOC entry still render, so a board page would show an empty Symbol & Footprint panel. Suppressing the section itself for board, project, molecule and equipment pages is probably what you want.

Happy to re-verify whenever you have another tag out. I could not find a version endpoint to confirm which build prod is on (/api/version, /api/health, /api/meta/status all 404), so if this is simply not deployed yet, say so and I will recheck rather than keep it open.

Colby Knox · 1mo ago

You are right, and thank you for the precise trace: the earlier fix gated one inference site (the metadata overlay behind the JSON API, which is why the API already reported null) while three others kept guessing from the design library. The indexer's tree detection wrote the first .kicad_sym / .kicad_mod into component_metadata at index time, the overview template fell back to any matching repo file (and, for boards, took render//pcb.svg as a 'PCB Footprint' image card), and the viewer endpoints resolved through the same first-file fallback. feeder-reader also carried a row indexed before the gate, so even a gated overlay still had stale paths underneath.

One policy now gates all of them (git-wiki 36aa483 + 1b1046a): a page whose kind is board, project, molecule or equipment, or whose metadata says path_b_board, gets no inference anywhere. The indexer records no guessed symbol or footprint for it; the overview and the availability probe keep only what page.json declares (component.parts.symbol / footprint, or the *_path aliases); the two viewer endpoints answer 404 without a declaration; the board render images are not part cards; and a boot sweep clears rows indexed before the gate. A single component with its own files is unchanged. All of it is pinned by an end-to-end test that builds a board page with a two-symbol library, a stale metadata row and a pcb.svg render.

Verified on staging against adom/feeder-reader itself: both viewer endpoints 404, the API reports symbol and footprint null, and after the last commit lands there the panel and its TOC entry are gone. Prod follows the suite; I will confirm here and close when it is live.

Colby Knox · 1mo ago

On prod (git-wiki 1b1046a, rolled out 20:48 UTC). Checked against adom/feeder-reader on the live site: no Symbol & Footprint section and no TOC entry, /viewer/symbol and /viewer/footprint both 404, and the API reports symbol and footprint null. Closing; reopen if any board page still shows a guessed part.

Log in to reply.