add a procedure for dealing with known-good differences#2689
add a procedure for dealing with known-good differences#2689bradgrantham-lunarg wants to merge 1 commit intoLunarG:devfrom
Conversation
* Generated with this series of prompts:
prompt: We have test cases in https://github.com/LunarG/gfxreconstruct/tree/dev/test/test_cases and known good GFXR outputs in "known_good". Our CI runs and captures the test_cases through Mock driver and captures and complains when the output doesn't match the known good .gfxr. Please generate a README.md I can put in .../test for how to proceed with fixing a .gfxr file when the comparison fails. A sample comparison failure is attached.
And a link with the full failure if desired is https://productionresultssa4.blob.core.windows.net/actions-results/f7fe19d3-7952-4a36-a7c8-b4117617ae1a/workflow-job-run-40c56dfc-694b-525e-a86c-9e41a08894c4/logs/job/job-logs.txt?rsct=text%2Fplain&se=2026-02-13T17%3A31%3A05Z&sig=4Ip2gaBbPdVal9uIO0Y8n6lRBO5pJYfiW26P6M3%2BOWU%3D&ske=2026-02-13T20%3A27%3A25Z&skoid=ca7593d4-ee42-46cd-af88-8b886a2f84eb&sks=b&skt=2026-02-13T16%3A27%3A25Z&sktid=398a6654-997b-47e9-b12b-9515b896b4de&skv=2025-11-05&sp=r&spr=https&sr=b&st=2026-02-13T17%3A21%3A00Z&sv=2025-11-05
prompt: Rather than running the file locally to get the results, please suggest getting the artifacts from the failing GitHub Action.
|
CI gfxreconstruct build queued with queue ID 648581. |
|
CI gfxreconstruct build # 648581 cancelled. |
|
@MarkY-LunarG I added this because you just worked through this. Could you take a look, please? |
|
|
||
| The comparison is performed by `verify-gfxr.cpp`, which converts both the captured and | ||
| known-good `.gfxr` files to JSON, then produces a JSON Patch (RFC 6902) diff. A test | ||
| passes when the diff is empty (`diff.size() == 0`). |
There was a problem hiding this comment.
Might be worth noting what's ignored by the verify-gfxr.cpp tool
| The comparison is performed by `verify-gfxr.cpp`, which converts both the captured and | ||
| known-good `.gfxr` files to JSON, then produces a JSON Patch (RFC 6902) diff. A test | ||
| passes when the diff is empty (`diff.size() == 0`). | ||
|
|
There was a problem hiding this comment.
You can reproduce these failures typically locally by running the run_tests.sh script. Is it worth mentioning that they could pre-emptively fix issues by doing this locally, running the compare, and then if all is well replacing the "known_good" version with the newly generated version?
| ```bash | ||
| # Convert the new capture from the downloaded artifact to JSON | ||
| gfxrecon-convert --format json pipeline-binaries.gfxr | ||
|
|
||
| # Convert the known-good reference to JSON | ||
| gfxrecon-convert --format json test/known_good/pipeline-binaries.gfxr | ||
|
|
||
| # Diff the JSON outputs | ||
| diff <(jq . pipeline-binaries.jsonl) \ | ||
| <(jq . test/known_good/pipeline-binaries.jsonl) | ||
| ``` |
There was a problem hiding this comment.
My artifacts file contained the JSON files already, no conversion needed
MarkY-LunarG
left a comment
There was a problem hiding this comment.
A few points of clarification
Generated with this series of prompts:
prompt: We have test cases in https://github.com/LunarG/gfxreconstruct/tree/dev/test/test_cases and known good GFXR outputs in "known_good". Our CI runs and captures the test_cases through Mock driver and captures and complains when the output doesn't match the known good .gfxr. Please generate a README.md I can put in .../test for how to proceed with fixing a .gfxr file when the comparison fails. A sample comparison failure is attached.
And a link with the full failure if desired is https://productionresultssa4.blob.core.windows.net/actions-results/f7fe19d3-7952-4a36-a7c8-b4117617ae1a/workflow-job-run-40c56dfc-694b-525e-a86c-9e41a08894c4/logs/job/job-logs.txt?rsct=text%2Fplain&se=2026-02-13T17%3A31%3A05Z&sig=4Ip2gaBbPdVal9uIO0Y8n6lRBO5pJYfiW26P6M3%2BOWU%3D&ske=2026-02-13T20%3A27%3A25Z&skoid=ca7593d4-ee42-46cd-af88-8b886a2f84eb&sks=b&skt=2026-02-13T16%3A27%3A25Z&sktid=398a6654-997b-47e9-b12b-9515b896b4de&skv=2025-11-05&sp=r&spr=https&sr=b&st=2026-02-13T17%3A21%3A00Z&sv=2025-11-05
prompt: Rather than running the file locally to get the results, please suggest getting the artifacts from the failing GitHub Action.