Repository navigation
Verify the Gradle distribution that the wrapper downloads against its SHA-256, and keep it current on upgrades - #799
Merged
Conversation
… SHA-256, and keep it current on upgrades gradle-wrapper.properties gets distributionSha256Sum for Gradle 9.9.2, Gradle's published gradle-9.9.2-bin.zip.sha256, so ./gradlew refuses a downloaded distribution that doesn't match. CI's wrapper validation checks the committed gradle-wrapper.jar, not the distribution that it downloads. With a checksum in the file, the wrapper task refuses to run without one, so bin/gradle-upgrade.sh fetches the target version's published checksum, gives it to both of its wrapper task runs, and writes it when it rewrites the properties. --check fails when a wrapper's checksum is missing or isn't the published one for its version. The script upgrades the sibling repositories too, which get the same checksum in xtclang/examples#34, xtclang/platform#31 and xtclang/xtc-app-template#14. Validated: - The upgrade that #798 made, replayed with this script from master before #798, with 9.9.1's checksum added: bin/gradle-upgrade.sh 9.9.2 --skip-build-validation writes the same gradle-wrapper.properties as this commit, and the same wrapper jar, gradlew, gradlew.bat, XtcProjectCreator and gradle-daemon-jvm.properties as master. - bin/gradle-upgrade.sh --check passes on this commit; on master it fails with "gradle/wrapper/ gradle-wrapper.properties must set distributionSha256Sum to the published checksum of Gradle 9.9.2". - ./gradlew --version with an empty GRADLE_USER_HOME downloads, verifies and runs Gradle 9.9.2. - bash -n and shellcheck: no warnings, as on master. The replay's wrapper runs found Gradle 9.9.2 already unpacked, so the wrapper didn't verify it there; the run with an empty Gradle home did.
ggleyzer
approved these changes
Nov 23, 2026
…ly --check of gradle-upgrade.sh run there The wrapper verifies distributionSha256Sum only when it downloads the distribution, and CI's comes from a cache, so CI never tried the checksum. setup-xvm-project now compares it with the checksum that services.gradle.org publishes for the wrapper's version, next to the wrapper validation, on every build that the action sets up. The step reads gradle-wrapper.properties and fetches the checksum; it changes no file and runs neither Gradle nor bin/gradle-upgrade.sh, whose --check also fails on an exact Gradle version mentioned anywhere in the repository. bin/gradle-upgrade.sh refuses every mode but --check when CI or GITHUB_ACTIONS is true, before it reads or changes anything: an upgrade rewrites files, and its branch modes commit and push, which only a person does. Validated: - The step's script, taken from action.yml and run as GitHub runs it (bash -eo pipefail): this branch's gradle-wrapper.properties passes; master's, without a checksum, a wrong checksum, and a version that services.gradle.org has no checksum for each fail with an error annotation that names the expected checksum. - With CI=true or GITHUB_ACTIONS=true, gradle-upgrade.sh 9.9.3, with no arguments, --all-xtclang-repos and --repo=platform each fail with "Only --check runs in CI"; --check passes; no run changes a file. - bash -n and shellcheck: no warnings; action.yml parses.
ggleyzer
approved these changes
Nov 24, 2026
lagergren
added a commit
that referenced
this pull request
Nov 25, 2026
Both branches were backed up as backup/lagergren-errs-2026-11-25 (c8c6d6f) and backup/693-2026-11-25 (49b5f8a), and tags of those names, then rebased onto master's 8b5257f, past #792, #798 (Gradle 9.9.2), #797, #796, #799, #800, #790, #793 and #803 (the JIT milestone's JitInfo). errs-rebase-2026-11-25.tsv maps errs' 1746 commits (from 60d36426eb, the remote's c8c6d6f with the commit that aligns errs' code to #693's): 1739 replayed, six with a resolved conflict, and a2e343c dropped, which master has as #800. errs-693-rebase-2026-11-25.tsv maps #693's 468 (from 49b5f8a): 466 replayed, one resolved, and its #800 copy 09e61bd dropped. Every conflict was in TypeConstant.java, where #803 moved the JIT class names into JitInfo, removing getJitCCType(), getJitICType() and the CD_Class and CD_Ctx imports. Each is resolved keeping master's change and the branch's: - errs' 1a5a748, 3f272ef, 7becf17, a500b09 and ac92dcf edit getJitICType()'s assert (its listener, BLACKHOLE to PROBE to silent(PROBE)) or the two methods' javadoc. Those methods are gone, so those hunks keep master's side; the commits' other changes apply. - errs' 23faf03 moves the ErrorListener static imports up beside CD_Class and CD_Ctx, and #693's 29029a8 adds them there; both keep the ErrorListener imports there, without the two imports #803 removed. #693's 29029a8 also has errs' getJitICType() hunk, resolved the same way. The rebase broke javatools' compile without a conflict: #803's three new newable checks say ErrorListener.BLACKHOLE, which errs no longer has. The commit that removes BLACKHOLE (errs e2e53f3, #693 1ddea3e) now also makes those checks say silent(PROBE), so that every commit after it compiles, as javatools' compileJava there and halfway to the tip shows on both branches; the commit before this one (#693 ef37030) drops TypeConstant's import of PROBE, whose only use went with getJitICType(). The two tables' new commits are those of this history. Checks: - Outside the 83 files master's nine commits changed, both rebased trees are identical to the trees they were rebased from (60d36426eb, 49b5f8a). Each of the ten files that master and the branches both changed equals a three-way merge of the old tree's file and master's, except TypeConstant.java, whose two conflicts are the ones above. - errs' and #693's code is identical: git diff of the two heads outside doc/errs, *.md and lang/doc/plans is empty. - On errs, after :xdk:installDist: :javatools:test 648 tests, 0 failures, 42 skipped (all @disabled, Windows-only or RUN_INTEGRATION_TESTS); :plugin:validatePlugins, and :plugin:test 83, 0 failures, 14 skipped; :xdk:testXtc, which has no test modules of its own, and the XDK's two, :xdk:lib-json:testXtc (179 passed) and :xdk:lib-metrics:testXtc (4 passed); :lang:lsp-server:test with -PlspTests=default 2593, 0 failures, 773 skipped (the default tier's later parameterized cases); :lang:intellij-plugin:test 233, 0 failures, 0 skipped, and compileIntegrationTestKotlin; :lang:dap-server:test 61, 0 failures, 0 skipped. spotlessCheck passes and git status is clean.
lagergren
added a commit
that referenced
this pull request
Nov 25, 2026
Both branches were backed up as backup/lagergren-errs-2026-11-25 (c8c6d6f) and backup/693-2026-11-25 (49b5f8a), and tags of those names, then rebased onto master's 8b5257f, past #792, #798 (Gradle 9.9.2), #797, #796, #799, #800, #790, #793 and #803 (the JIT milestone's JitInfo). errs-rebase-2026-11-25.tsv maps errs' 1746 commits (from 60d36426eb, the remote's c8c6d6f with the commit that aligns errs' code to #693's): 1739 replayed, six with a resolved conflict, and a2e343c dropped, which master has as #800. errs-693-rebase-2026-11-25.tsv maps #693's 468 (from 49b5f8a): 466 replayed, one resolved, and its #800 copy 09e61bd dropped. Every conflict was in TypeConstant.java, where #803 moved the JIT class names into JitInfo, removing getJitCCType(), getJitICType() and the CD_Class and CD_Ctx imports. Each is resolved keeping master's change and the branch's: - errs' 1a5a748, 3f272ef, 7becf17, a500b09 and ac92dcf edit getJitICType()'s assert (its listener, BLACKHOLE to PROBE to silent(PROBE)) or the two methods' javadoc. Those methods are gone, so those hunks keep master's side; the commits' other changes apply. - errs' 23faf03 moves the ErrorListener static imports up beside CD_Class and CD_Ctx, and #693's 29029a8 adds them there; both keep the ErrorListener imports there, without the two imports #803 removed. #693's 29029a8 also has errs' getJitICType() hunk, resolved the same way. The rebase broke javatools' compile without a conflict: #803's three new newable checks say ErrorListener.BLACKHOLE, which errs no longer has. The commit that removes BLACKHOLE (errs e2e53f3, #693 1ddea3e) now also makes those checks say silent(PROBE), so that every commit after it compiles, as javatools' compileJava there and halfway to the tip shows on both branches; the commit before this one (#693 ef37030) drops TypeConstant's import of PROBE, whose only use went with getJitICType(). The two tables' new commits are those of this history. Checks: - Outside the 83 files master's nine commits changed, both rebased trees are identical to the trees they were rebased from (60d36426eb, 49b5f8a). Each of the ten files that master and the branches both changed equals a three-way merge of the old tree's file and master's, except TypeConstant.java, whose two conflicts are the ones above. - errs' and #693's code is identical: git diff of the two heads outside doc/errs, *.md and lang/doc/plans is empty. - On errs, after :xdk:installDist: :javatools:test 648 tests, 0 failures, 42 skipped (all @disabled, Windows-only or RUN_INTEGRATION_TESTS); :plugin:validatePlugins, and :plugin:test 83, 0 failures, 14 skipped; :xdk:testXtc, which has no test modules of its own, and the XDK's two, :xdk:lib-json:testXtc (179 passed) and :xdk:lib-metrics:testXtc (4 passed); :lang:lsp-server:test with -PlspTests=default 2593, 0 failures, 773 skipped (the default tier's later parameterized cases); :lang:intellij-plugin:test 233, 0 failures, 0 skipped, and compileIntegrationTestKotlin; :lang:dap-server:test 61, 0 failures, 0 skipped. spotlessCheck passes and git status is clean.
lagergren
added a commit
that referenced
this pull request
Nov 25, 2026
Both branches were backed up as backup/lagergren-errs-2026-11-25 (c8c6d6f) and backup/693-2026-11-25 (49b5f8a), and tags of those names, then rebased onto master's 8b5257f, past #792, #798 (Gradle 9.9.2), #797, #796, #799, #800, #790, #793 and #803 (the JIT milestone's JitInfo). errs-rebase-2026-11-25.tsv maps errs' 1746 commits (from 60d36426eb, the remote's c8c6d6f with the commit that aligns errs' code to #693's): 1739 replayed, six with a resolved conflict, and a2e343c dropped, which master has as #800. errs-693-rebase-2026-11-25.tsv maps #693's 468 (from 49b5f8a): 466 replayed, one resolved, and its #800 copy 09e61bd dropped. Every conflict was in TypeConstant.java, where #803 moved the JIT class names into JitInfo, removing getJitCCType(), getJitICType() and the CD_Class and CD_Ctx imports. Each is resolved keeping master's change and the branch's: - errs' 1a5a748, 3f272ef, 7becf17, a500b09 and ac92dcf edit getJitICType()'s assert (its listener, BLACKHOLE to PROBE to silent(PROBE)) or the two methods' javadoc. Those methods are gone, so those hunks keep master's side; the commits' other changes apply. - errs' 23faf03 moves the ErrorListener static imports up beside CD_Class and CD_Ctx, and #693's 29029a8 adds them there; both keep the ErrorListener imports there, without the two imports #803 removed. #693's 29029a8 also has errs' getJitICType() hunk, resolved the same way. The rebase broke javatools' compile without a conflict: #803's three new newable checks say ErrorListener.BLACKHOLE, which errs no longer has. The commit that removes BLACKHOLE (errs e2e53f3, #693 1ddea3e) now also makes those checks say silent(PROBE), so that every commit after it compiles, as javatools' compileJava there and halfway to the tip shows on both branches; the commit before this one (#693 ef37030) drops TypeConstant's import of PROBE, whose only use went with getJitICType(). The two tables' new commits are those of this history. Checks: - Outside the 83 files master's nine commits changed, both rebased trees are identical to the trees they were rebased from (60d36426eb, 49b5f8a). Each of the ten files that master and the branches both changed equals a three-way merge of the old tree's file and master's, except TypeConstant.java, whose two conflicts are the ones above. - errs' and #693's code is identical: git diff of the two heads outside doc/errs, *.md and lang/doc/plans is empty. - On errs, after :xdk:installDist: :javatools:test 648 tests, 0 failures, 42 skipped (all @disabled, Windows-only or RUN_INTEGRATION_TESTS); :plugin:validatePlugins, and :plugin:test 83, 0 failures, 14 skipped; :xdk:testXtc, which has no test modules of its own, and the XDK's two, :xdk:lib-json:testXtc (179 passed) and :xdk:lib-metrics:testXtc (4 passed); :lang:lsp-server:test with -PlspTests=default 2593, 0 failures, 773 skipped (the default tier's later parameterized cases); :lang:intellij-plugin:test 233, 0 failures, 0 skipped, and compileIntegrationTestKotlin; :lang:dap-server:test 61, 0 failures, 0 skipped. spotlessCheck passes and git status is clean.
lagergren
added a commit
that referenced
this pull request
Nov 26, 2026
Both branches were backed up as backup/lagergren-errs-2026-11-25 (c8c6d6f) and backup/693-2026-11-25 (49b5f8a), and tags of those names, then rebased onto master's 8b5257f, past #792, #798 (Gradle 9.9.2), #797, #796, #799, #800, #790, #793 and #803 (the JIT milestone's JitInfo). errs-rebase-2026-11-25.tsv maps errs' 1746 commits (from 60d36426eb, the remote's c8c6d6f with the commit that aligns errs' code to #693's): 1739 replayed, six with a resolved conflict, and a2e343c dropped, which master has as #800. errs-693-rebase-2026-11-25.tsv maps #693's 468 (from 49b5f8a): 466 replayed, one resolved, and its #800 copy 09e61bd dropped. Every conflict was in TypeConstant.java, where #803 moved the JIT class names into JitInfo, removing getJitCCType(), getJitICType() and the CD_Class and CD_Ctx imports. Each is resolved keeping master's change and the branch's: - errs' 1a5a748, 3f272ef, 7becf17, a500b09 and ac92dcf edit getJitICType()'s assert (its listener, BLACKHOLE to PROBE to silent(PROBE)) or the two methods' javadoc. Those methods are gone, so those hunks keep master's side; the commits' other changes apply. - errs' 23faf03 moves the ErrorListener static imports up beside CD_Class and CD_Ctx, and #693's 29029a8 adds them there; both keep the ErrorListener imports there, without the two imports #803 removed. #693's 29029a8 also has errs' getJitICType() hunk, resolved the same way. The rebase broke javatools' compile without a conflict: #803's three new newable checks say ErrorListener.BLACKHOLE, which errs no longer has. The commit that removes BLACKHOLE (errs e2e53f3, #693 1ddea3e) now also makes those checks say silent(PROBE), so that every commit after it compiles, as javatools' compileJava there and halfway to the tip shows on both branches; the commit before this one (#693 ef37030) drops TypeConstant's import of PROBE, whose only use went with getJitICType(). The two tables' new commits are those of this history. Checks: - Outside the 83 files master's nine commits changed, both rebased trees are identical to the trees they were rebased from (60d36426eb, 49b5f8a). Each of the ten files that master and the branches both changed equals a three-way merge of the old tree's file and master's, except TypeConstant.java, whose two conflicts are the ones above. - errs' and #693's code is identical: git diff of the two heads outside doc/errs, *.md and lang/doc/plans is empty. - On errs, after :xdk:installDist: :javatools:test 648 tests, 0 failures, 42 skipped (all @disabled, Windows-only or RUN_INTEGRATION_TESTS); :plugin:validatePlugins, and :plugin:test 83, 0 failures, 14 skipped; :xdk:testXtc, which has no test modules of its own, and the XDK's two, :xdk:lib-json:testXtc (179 passed) and :xdk:lib-metrics:testXtc (4 passed); :lang:lsp-server:test with -PlspTests=default 2593, 0 failures, 773 skipped (the default tier's later parameterized cases); :lang:intellij-plugin:test 233, 0 failures, 0 skipped, and compileIntegrationTestKotlin; :lang:dap-server:test 61, 0 failures, 0 skipped. spotlessCheck passes and git status is clean.
lagergren
added a commit
that referenced
this pull request
Nov 26, 2026
Both branches were backed up as backup/lagergren-errs-2026-11-25 (c8c6d6f) and backup/693-2026-11-25 (49b5f8a), and tags of those names, then rebased onto master's 8b5257f, past #792, #798 (Gradle 9.9.2), #797, #796, #799, #800, #790, #793 and #803 (the JIT milestone's JitInfo). errs-rebase-2026-11-25.tsv maps errs' 1746 commits (from 60d36426eb, the remote's c8c6d6f with the commit that aligns errs' code to #693's): 1739 replayed, six with a resolved conflict, and a2e343c dropped, which master has as #800. errs-693-rebase-2026-11-25.tsv maps #693's 468 (from 49b5f8a): 466 replayed, one resolved, and its #800 copy 09e61bd dropped. Every conflict was in TypeConstant.java, where #803 moved the JIT class names into JitInfo, removing getJitCCType(), getJitICType() and the CD_Class and CD_Ctx imports. Each is resolved keeping master's change and the branch's: - errs' 1a5a748, 3f272ef, 7becf17, a500b09 and ac92dcf edit getJitICType()'s assert (its listener, BLACKHOLE to PROBE to silent(PROBE)) or the two methods' javadoc. Those methods are gone, so those hunks keep master's side; the commits' other changes apply. - errs' 23faf03 moves the ErrorListener static imports up beside CD_Class and CD_Ctx, and #693's 29029a8 adds them there; both keep the ErrorListener imports there, without the two imports #803 removed. #693's 29029a8 also has errs' getJitICType() hunk, resolved the same way. The rebase broke javatools' compile without a conflict: #803's three new newable checks say ErrorListener.BLACKHOLE, which errs no longer has. The commit that removes BLACKHOLE (errs e2e53f3, #693 1ddea3e) now also makes those checks say silent(PROBE), so that every commit after it compiles, as javatools' compileJava there and halfway to the tip shows on both branches; the commit before this one (#693 ef37030) drops TypeConstant's import of PROBE, whose only use went with getJitICType(). The two tables' new commits are those of this history. Checks: - Outside the 83 files master's nine commits changed, both rebased trees are identical to the trees they were rebased from (60d36426eb, 49b5f8a). Each of the ten files that master and the branches both changed equals a three-way merge of the old tree's file and master's, except TypeConstant.java, whose two conflicts are the ones above. - errs' and #693's code is identical: git diff of the two heads outside doc/errs, *.md and lang/doc/plans is empty. - On errs, after :xdk:installDist: :javatools:test 648 tests, 0 failures, 42 skipped (all @disabled, Windows-only or RUN_INTEGRATION_TESTS); :plugin:validatePlugins, and :plugin:test 83, 0 failures, 14 skipped; :xdk:testXtc, which has no test modules of its own, and the XDK's two, :xdk:lib-json:testXtc (179 passed) and :xdk:lib-metrics:testXtc (4 passed); :lang:lsp-server:test with -PlspTests=default 2593, 0 failures, 773 skipped (the default tier's later parameterized cases); :lang:intellij-plugin:test 233, 0 failures, 0 skipped, and compileIntegrationTestKotlin; :lang:dap-server:test 61, 0 failures, 0 skipped. spotlessCheck passes and git status is clean.
lagergren
added a commit
that referenced
this pull request
Nov 27, 2026
Both branches were backed up as backup/lagergren-errs-2026-11-25 (c8c6d6f) and backup/693-2026-11-25 (49b5f8a), and tags of those names, then rebased onto master's 8b5257f, past #792, #798 (Gradle 9.9.2), #797, #796, #799, #800, #790, #793 and #803 (the JIT milestone's JitInfo). errs-rebase-2026-11-25.tsv maps errs' 1746 commits (from 60d36426eb, the remote's c8c6d6f with the commit that aligns errs' code to #693's): 1739 replayed, six with a resolved conflict, and a2e343c dropped, which master has as #800. errs-693-rebase-2026-11-25.tsv maps #693's 468 (from 49b5f8a): 466 replayed, one resolved, and its #800 copy 09e61bd dropped. Every conflict was in TypeConstant.java, where #803 moved the JIT class names into JitInfo, removing getJitCCType(), getJitICType() and the CD_Class and CD_Ctx imports. Each is resolved keeping master's change and the branch's: - errs' 1a5a748, 3f272ef, 7becf17, a500b09 and ac92dcf edit getJitICType()'s assert (its listener, BLACKHOLE to PROBE to silent(PROBE)) or the two methods' javadoc. Those methods are gone, so those hunks keep master's side; the commits' other changes apply. - errs' 23faf03 moves the ErrorListener static imports up beside CD_Class and CD_Ctx, and #693's 29029a8 adds them there; both keep the ErrorListener imports there, without the two imports #803 removed. #693's 29029a8 also has errs' getJitICType() hunk, resolved the same way. The rebase broke javatools' compile without a conflict: #803's three new newable checks say ErrorListener.BLACKHOLE, which errs no longer has. The commit that removes BLACKHOLE (errs e2e53f3, #693 1ddea3e) now also makes those checks say silent(PROBE), so that every commit after it compiles, as javatools' compileJava there and halfway to the tip shows on both branches; the commit before this one (#693 ef37030) drops TypeConstant's import of PROBE, whose only use went with getJitICType(). The two tables' new commits are those of this history. Checks: - Outside the 83 files master's nine commits changed, both rebased trees are identical to the trees they were rebased from (60d36426eb, 49b5f8a). Each of the ten files that master and the branches both changed equals a three-way merge of the old tree's file and master's, except TypeConstant.java, whose two conflicts are the ones above. - errs' and #693's code is identical: git diff of the two heads outside doc/errs, *.md and lang/doc/plans is empty. - On errs, after :xdk:installDist: :javatools:test 648 tests, 0 failures, 42 skipped (all @disabled, Windows-only or RUN_INTEGRATION_TESTS); :plugin:validatePlugins, and :plugin:test 83, 0 failures, 14 skipped; :xdk:testXtc, which has no test modules of its own, and the XDK's two, :xdk:lib-json:testXtc (179 passed) and :xdk:lib-metrics:testXtc (4 passed); :lang:lsp-server:test with -PlspTests=default 2593, 0 failures, 773 skipped (the default tier's later parameterized cases); :lang:intellij-plugin:test 233, 0 failures, 0 skipped, and compileIntegrationTestKotlin; :lang:dap-server:test 61, 0 failures, 0 skipped. spotlessCheck passes and git status is clean.
lagergren
added a commit
that referenced
this pull request
Nov 28, 2026
Both branches were backed up as backup/lagergren-errs-2026-11-25 (c8c6d6f) and backup/693-2026-11-25 (49b5f8a), and tags of those names, then rebased onto master's 8b5257f, past #792, #798 (Gradle 9.9.2), #797, #796, #799, #800, #790, #793 and #803 (the JIT milestone's JitInfo). errs-rebase-2026-11-25.tsv maps errs' 1746 commits (from 60d36426eb, the remote's c8c6d6f with the commit that aligns errs' code to #693's): 1739 replayed, six with a resolved conflict, and a2e343c dropped, which master has as #800. errs-693-rebase-2026-11-25.tsv maps #693's 468 (from 49b5f8a): 466 replayed, one resolved, and its #800 copy 09e61bd dropped. Every conflict was in TypeConstant.java, where #803 moved the JIT class names into JitInfo, removing getJitCCType(), getJitICType() and the CD_Class and CD_Ctx imports. Each is resolved keeping master's change and the branch's: - errs' 1a5a748, 3f272ef, 7becf17, a500b09 and ac92dcf edit getJitICType()'s assert (its listener, BLACKHOLE to PROBE to silent(PROBE)) or the two methods' javadoc. Those methods are gone, so those hunks keep master's side; the commits' other changes apply. - errs' 23faf03 moves the ErrorListener static imports up beside CD_Class and CD_Ctx, and #693's 29029a8 adds them there; both keep the ErrorListener imports there, without the two imports #803 removed. #693's 29029a8 also has errs' getJitICType() hunk, resolved the same way. The rebase broke javatools' compile without a conflict: #803's three new newable checks say ErrorListener.BLACKHOLE, which errs no longer has. The commit that removes BLACKHOLE (errs e2e53f3, #693 1ddea3e) now also makes those checks say silent(PROBE), so that every commit after it compiles, as javatools' compileJava there and halfway to the tip shows on both branches; the commit before this one (#693 ef37030) drops TypeConstant's import of PROBE, whose only use went with getJitICType(). The two tables' new commits are those of this history. Checks: - Outside the 83 files master's nine commits changed, both rebased trees are identical to the trees they were rebased from (60d36426eb, 49b5f8a). Each of the ten files that master and the branches both changed equals a three-way merge of the old tree's file and master's, except TypeConstant.java, whose two conflicts are the ones above. - errs' and #693's code is identical: git diff of the two heads outside doc/errs, *.md and lang/doc/plans is empty. - On errs, after :xdk:installDist: :javatools:test 648 tests, 0 failures, 42 skipped (all @disabled, Windows-only or RUN_INTEGRATION_TESTS); :plugin:validatePlugins, and :plugin:test 83, 0 failures, 14 skipped; :xdk:testXtc, which has no test modules of its own, and the XDK's two, :xdk:lib-json:testXtc (179 passed) and :xdk:lib-metrics:testXtc (4 passed); :lang:lsp-server:test with -PlspTests=default 2593, 0 failures, 773 skipped (the default tier's later parameterized cases); :lang:intellij-plugin:test 233, 0 failures, 0 skipped, and compileIntegrationTestKotlin; :lang:dap-server:test 61, 0 failures, 0 skipped. spotlessCheck passes and git status is clean.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Adds
distributionSha256Sumfor Gradle 9.9.2 togradle/wrapper/gradle-wrapper.properties../gradlewthen verifies the distribution it downloads against Gradle's published checksum,gradle-9.9.2-bin.zip.sha256, and refuses one that doesn't match. That applies to every download, locally and in CI. A distribution already unpacked in a Gradle home isn't checked again.CI's wrapper validation (
gradle/actions/wrapper-validationinsetup-xvm-project) stays as it is. It compares the committedgradle-wrapper.jarwith Gradle's checksums, and doesn't cover the distribution that the JAR then downloads.bin/gradle-upgrade.sh: once the file has a checksum, thewrappertask refuses to run without one (gradle-wrapper.properties contains distributionSha256Sum property, but the wrapper configuration does not have one). So the script now:wrappertask runs (--gradle-distribution-sha256-sum);distributionSha256Sumwhen it rewrites the properties with the wrapper's policy.--checknow fails when a wrapper's checksum is missing or isn't the published one for its version. The script upgrades the sibling repositories too; they get the same checksum in xtclang/examples#34, xtclang/platform#31 and xtclang/xtc-app-template#14.CI checks the checksum, read-only. The wrapper verifies
distributionSha256Sumonly when it downloads the distribution, and CI's distribution comes from a cache, so CI never exercised the checksum.setup-xvm-projectnow has a step next to the wrapper validation, on every build that the action sets up. The step:gradle-wrapper.properties;The step changes no file, and runs neither Gradle nor
bin/gradle-upgrade.sh. The script's--checkwould also fail on an exact Gradle version mentioned anywhere in the repository.Only a person upgrades Gradle.
bin/gradle-upgrade.shnow refuses every mode but--checkwhenCIorGITHUB_ACTIONSistrue, before it reads or changes anything. An upgrade rewrites files, and its branch modes commit and push.Type of change
How Has This Been Tested?
The upgrade that Upgrade Gradle to 9.9.2 #798 made, replayed with this script. I started from master before Upgrade Gradle to 9.9.2 #798, which is on Gradle 9.9.1, with 9.9.1's checksum added, as the next upgrade will find it.
bin/gradle-upgrade.sh 9.9.2 --skip-build-validationthen wrote:gradle-wrapper.propertiesas this PR;gradle-wrapper.jar,gradlew,gradlew.bat,XtcProjectCreator.javaandgradle-daemon-jvm.propertiesas master.bin/gradle-upgrade.sh --checkpasses on this branch. On master it fails with gradle/wrapper/gradle-wrapper.properties must set distributionSha256Sum to the published checksum of Gradle 9.9.2../gradlew --versionwith an emptyGRADLE_USER_HOMEdownloadsgradle-9.9.2-bin.zip, verifies it and runs Gradle 9.9.2. In the sibling repositories, the same run with the checksum's last digit changed fails with Verification of Gradle distribution failed!The CI step's script, taken from
action.ymland run as GitHub runs it (bash -eo pipefail):gradle-wrapper.propertiespasses;master's, with no checksum, fails;Each failure gives an error annotation that names the expected checksum.
With
CI=trueorGITHUB_ACTIONS=true,gradle-upgrade.sh 9.9.3,gradle-upgrade.shwith no arguments,--all-xtclang-reposand--repo=platformeach fail with Only --check runs in CI.--checkstill passes, and no run changes a file.bash -nandshellcheckreport no warnings, as on master.The replay's
wrapperruns found Gradle 9.9.2 already unpacked, so the wrapper didn't verify it there; the run with an empty Gradle home did.