Skip to content

Conversation

ldionne
Copy link
Member

@ldionne ldionne commented Oct 3, 2025

The code representing reports (and related entities like machines, runs, etc) was greatly complicated by the presence of multiple input format versions.

In particular, the "v2" input format was introduced but several parts of the codebase (e.g. lnt importreport) were never switched to it and were still producing reports in the "old" format.

This patch simplifies the code by un-versionning the Python objects that represent Report-related entities and moving tests and other tools to produce the latest input format.

However, old input formats are still supported in the sense that lnt import and the various importation methods still support old JSON formats, which are
upgraded to the latest format before actually being submitted.

TODO:

  • Fix the tests so they use the latest input format.
  • Look through anything that is still producing the old format (hint, search for elements of the old format like old classes e.g. TestSamples)
  • Fix remaining mentions of report_version
  • Look for other mentions of the report version format
  • Look through https://reviews.llvm.org/D65751 and https://reviews.llvm.org/D34584
  • Add tests for the JSON upgrade from V1 to V2 instead of having all kinds of tests for each Python class
  • Is TestSamples still used? If not, remove it

The code representing reports (and related entities
like machines, runs, etc) was greatly complicated by
the presence of multiple input format versions.

In particular, the "v2" input format was introduced
but several parts of the codebase (e.g. `lnt importreport`)
were never switched to it and were still producing
reports in the "old" format.

This patch simplifies the code by un-versionning the
Python objects that represent Report-related entities
and moving tests and other tools to produce the latest
input format.

However, old input formats are still supported in the
sense that `lnt import` and the various importation
methods still support old JSON formats, which are
upgraded to the latest format before actually being
submitted.

TODO:
- Fix the tests so they use the latest input format.
- Look through anything that is still producing the old format (hint, search for elements of the old format like old classes e.g. TestSamples)
- Fix remaining mentions of report_version
- Look for other mentions of the report version format
- Look through https://reviews.llvm.org/D65751 and https://reviews.llvm.org/D34584
- Add tests for the JSON upgrade from V1 to V2 instead of having all kinds of tests for each Python class
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