Skip to content

project upgrade writes a machine-readable findings file for agents and other tools #1314

Closed as duplicate

Description

User story

As a developer using an AI coding agent, I want upgrade findings in a stable machine-readable file, so that the agent works from version-correct facts instead of inventing Shopware APIs.

Problem

#1255 states the problem: Agent training data can mix incompatible Shopware versions and produce plausible code whose identifiers, registrations, or build configuration do not actually match the selected target.

The CLI knows the target version, the installed core, which findings are real, and which are already automated. None of it is reachable by anything except a human reading a terminal.

The upgrade wizard MVP #1167 already asks for this: scan findings should be available "as a simple Markdown file/list so a developer, vendor, support person, or AI agent can work from the same information."

shopware/deployment-helper#93 is building the same thing on the deploy side: JSON on stdout, logs on stderr, one line per step. It states the split plainly: CLI owns the rendering / TUI, and DH only produces the data. The CLI should speak the same language for its own findings.

Implementation decisions

  • Write .shopware-cli/upgrade/findings.json next to the existing report: file, line, rule, owner, fixability, resolved source and target versions.
  • Match the field names and status vocabulary used by Make deploy output friendly for Datadog, Grafana, and other logging tools deployment-helper#93, so the wizard consumes CLI findings and DH steps in one shape.
  • Version and publish the schema the same way the existing config schemas are published (project config schema, extension config schema), so agents and third-party tools can validate against it.
  • Ship a companion skill file that tells an agent to run the CLI for facts and never guess a Shopware API. The CLI stays a fact provider. No model calls in the binary.
  • Findings marked auto + cli carry the exact command. The correct agent action is to call the CLI, not to hand-write the change.
  • Generate the human report and the machine file from the same result set, so they cannot disagree.

Out of scope

  • Calling an LLM from the CLI.
  • Agents fixing things automatically.
  • Classifying or migrating CMS elements to the new component system. That is not statically determinable today.

Acceptance criteria

  • Every findings file produced across the 5-project test set validates against the published schema. Zero violations.
  • Blind evaluation on 10 or more known 6.6 → 6.7 breakages: an agent given findings.json produces at least 2× the rate of correct, version-appropriate fixes compared to an agent given only the repository.
  • Zero invented Shopware API references in the grounded run. Removing them is the point of the file.

Readiness checklist

  • Acceptance criteria are clearly defined.
  • Backward compatibility impact addressed.
  • Documentation written.
  • Tests added or adjusted accordingly.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    Fields

    No fields configured for Story.

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions