Skip to content

charly-internals rows point at emptied files: libvirt_yaml.go claims LibvirtDomain +30 types and is 3 lines; the types moved to spec, RenderDomainXML to plugin-vm #339

Closed

Description

@atrawog

plugins#212's validator found one stale size cell as a non-blocking finding and correctly routed it here — the projection is faithful, so the defect is in the candy source, and hand-editing the generated page would be the very thing that PR existed to avoid.

Sweeping rather than fixing the one cell it landed on found a second, worse instance of the same class.

Measured

cell in candy/charly-internals/charly.yml claims actual non-comment lines
sdk/vmshared/libvirt_yaml.go ~480 3 1
sdk/vmshared/libvirt_yaml_listen.go ~130 24 1

Both files have been gutted to near-stubs while the table still advertises their former size. libvirt_yaml.go is now three lines:

package vmshared

// --- Per-device structs ---

~480 against 3 lines is not drift, it is a number with no remaining relationship to its subject.

Not a general rot — the neighbours are accurate

Re-derived independently, confirming plugins#212's validator:

cell claims actual verdict
spec/schema/vm.cue ~720 722 fine
sdk/vmshared/libvirt_helpers.go ~160 158 fine
sdk/vmshared/qemu_render.go ~340 342 fine

So the convention works and is maintained. What fails is the case where a file is emptied rather than edited: the size cell is not updated because nothing about the row's prose changed, and a ~N next to a one-line stub reads as authoritative.

Honest limit on this measurement

My sweep matched only the exact cell shape | `path` | text | ~N | and examined 6 cells. Two of six are stale. Other tables in that file state sizes in different shapes, and this repo's candy prose carries line-count claims elsewhere; this is a sample, not a census. Anyone fixing it should widen the pattern before claiming the population is closed — the same trap as counting the short form of a sha and reporting the full-form count.

Why it is filed rather than fixed in charly#309

#309 deliberately does not touch candy/charly-internals/charly.yml — its own validator brief names that file's separator census as a value that must be preserved, not tracked, and the PR proves the file is absent from its diff. Adding an unrelated table edit there would widen a PR that is already large and would put a claim into the one file #309 asserts it does not modify.

The fix is a candy edit plus one plugins regeneration, and it should carry the widened sweep rather than these two cells.

Related

  • charly#305 — that same file is past GitHub's 1 MiB contents-API cap, which is why measurements against it need local reads.
  • charly#318 — the projection gate that surfaces this class of source/projection divergence.

Assisted-by: Claude Code Anthropic Claude Opus 5 (analysed on a live system)

Activity

  1. atrawog commented on Aug 19, 2026

    @atrawog
    ContributorAuthor

    Sharper diagnosis: these are stale POINTERS, not stale numbers — and a size-only fix would close this issue wrongly

    Raised by plugins#212's validator after the original filing, and re-derived here before folding in.

    Rewriting ~480 → ~3 would make the cell truthful and still useless: it would accurately point at an empty file. The real defect is that the named path no longer contains what its own description says it contains.

    Row 1 — sdk/vmshared/libvirt_yaml.go

    Claims: "LibvirtDomain + 30+ sub-types (features, CPU, clock, memory backing, memtune, numatune, cputune, devices, seclabel, launch security, resource, sysinfo)", ~480.

    The entire file at the pinned sdk:

    package vmshared
    
    // --- Per-device structs ---

    Three lines, one non-comment. The types are gone from it — LibvirtDomain is now an alias in sdk/vmshared/spec_aliases.go:80 (= spec.LibvirtDomain), i.e. the real definitions moved to spec. And the renderer the row's neighbourhood implies lives here, func RenderDomainXML, is now at candy/plugin-vm/libvirt_yaml_bridge.go:47.

    Row 2 — sdk/vmshared/libvirt_yaml_listen.go

    Claims: "structured <listen> support for LibvirtGraphics", ~130. Actual: 24 lines, one non-comment. LibvirtGraphics also resolves through spec_aliases.go.

    So it is two-of-two on the pointer reading, not merely two-of-two on size — a doc stub left behind after its types relocated, exactly as the validator predicted before I checked.

    What this changes about the fix

    The reviewable question per row is not "is the number right" but "does the named path still contain the thing the description says it contains." A wildly oversized ~N is only the symptom that makes the row findable; a row can be equally wrong with a plausible number.

    That also makes the widened sweep greppable in a useful way: look for rows whose named file is a stub or whose named symbols resolve elsewhere, not just for size ratios. My original sample of six cells was selected by size-cell shape, which finds this class only when the size happens to be wildly off.

    A correction to a claim that was nearly filed here

    The same validator initially measured git -C sdk cat-file -e f0127778:vmshared/libvirt_yaml.go from the main tree, got "path exists on disk, but not in f0127778", and read it as "the row points at a path absent from the pinned sdk" — a much larger claim. It is false: the main tree's sdk checkout is at 91cc241d and simply lacks that object, so git's message was about a missing object, not a missing path. Re-run where the object exists, the file is present, tracked and clean.

    Recording it because it is the third instance in this cutover of an error message read as a measurement, and it was caught by re-reading rather than by any gate. The two-of-six numbers in the original report are unaffected and stand as stated.

    Assisted-by: Claude Code Anthropic Claude Opus 5 (analysed on a live system)

  2. changed the title [-]Two size cells in charly-internals advertise gutted files: libvirt_yaml.go claims ~480 and is 3 lines, libvirt_yaml_listen.go claims ~130 and is 24[/-] [+]charly-internals rows point at emptied files: libvirt_yaml.go claims LibvirtDomain +30 types and is 3 lines; the types moved to spec, RenderDomainXML to plugin-vm[/+] on Aug 19, 2026
  3. atrawog commented on Aug 28, 2026

    @atrawog
    ContributorAuthor

    Validation (2026-08-28) — RESOLVED

    Verified against current marketplace main. The stale size cells were corrected: marketplace/internals/skills/go/references/source-map.md:202 now reads "stub — the per-device structs moved to #LibvirtDomain in spec/schema/vm.cue", and libvirt_yaml_bridge.go (~1800) / libvirt_yaml_listen.go (~24) are listed with their real sizes. Landed via the batch-2.1 prose fix (marketplace 437dd28).

    Closing as resolved.

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions