Skip to content

CI: retry the Qt install on Windows - #2

Open
starlit-void wants to merge 1 commit into
developfrom
starlit/ci-retry-qt-install
Open

CI: retry the Qt install on Windows#2
starlit-void wants to merge 1 commit into
developfrom
starlit/ci-retry-qt-install

Conversation

@starlit-void

Copy link
Copy Markdown
Owner

Fork-internal PR, opened to exercise the changed workflow on real Windows runners before proposing it upstream.

aqt install-qt fails intermittently on Windows with Bad7zFile: Specified path is bad: <entry>. It is not a corrupt download: it is a false positive in py7zr's path traversal check, tightened for CVE-2026-23879, which rejects an output path that is genuinely inside the destination directory. The entry named in the error differs from run to run, so a repeat attempt usually succeeds. Open upstream as aqtinstall#995 and py7zr#714, with the aqt maintainer pointing at py7zr as the cause.

This routes the three install-qt calls through an :install_qt helper that retries up to three times. The fail-fast behaviour added in YACReader#579 is preserved: when all attempts fail, the step still fails at the install rather than surfacing later as a phantom build error.

Pinning py7zr below the version that introduced the check would also work, but reintroduces that CVE plus two other advisories fixed in the same release.

What this run is checking

The batch logic could not be tested locally (macOS). Specifically:

  • exit /b 0 breaking out of a for /l inside a called subroutine
  • || seeing the subroutine's exit code
  • goto :eof ending the main body with the correct errorlevel
  • YAML block-scalar indentation leaving the :install_qt label at column 0

A green Windows x64 and Windows ARM64 here confirms all four. Because the bug hits roughly half of Windows runs, a re-run or two may also exercise the retry path itself rather than just the happy path.

`aqt install-qt` fails intermittently on Windows with

    WARNING : Caught Bad7zFile, terminating installer workers
    ERROR   : Specified path is bad: lib/cmake/Qt6ShaderToolsPrivate

This is not a corrupt download. It is a false positive in py7zr's path
traversal check, which rejects an output path that is genuinely inside
the destination directory. The check was tightened for CVE-2026-23879,
and the archive entry named in the error differs from run to run, so the
same command succeeds on a later attempt.

Reported upstream, still open:
  miurahr/aqtinstall#995
  miurahr/py7zr#714

Route the three install-qt calls through a small `:install_qt` helper
that retries up to three times before giving up. Failures still surface
immediately when all attempts fail, so the fail-fast behaviour added
earlier is preserved.

Pinning py7zr below the version that introduced the check would also
work, but that reintroduces the CVE it fixed, along with two other
advisories fixed in the same release. Retrying costs a little CI time
only on the runs that would otherwise have failed outright.
@starlit-void
starlit-void force-pushed the starlit/ci-retry-qt-install branch 4 times, most recently from 975fe74 to e36357e Compare August 3, 2026 06:22
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