solvcon / modmesh

Toolkit for solving partial differential equations
BSD 3-Clause "New" or "Revised" License
29 stars 35 forks source link

Dependency download became unstable #366

Closed yungyuc closed 2 weeks ago

yungyuc commented 2 weeks ago

Github Actions started to have a lot of false alarms due to download errors, e.g., https://github.com/solvcon/modmesh/actions/runs/9537805732/job/26290861151#step:5:429 :

WARNING : Caught ChecksumDownloadFailure, terminating installer workers
ERROR   : Failed to download checksum for the file '6.6.3-0-202403191846qtsvg-Linux-RHEL_8_8-GCC-Linux-RHEL_8_8-X86_64.7z' from mirrors '['https://download.qt.io/']
==============================Suggested follow-up:==============================
* Check your internet connection
* Consider modifying `requests.max_retries_to_retrieve_hash` in settings.ini
* Consider modifying `mirrors.trusted_mirrors` in settings.ini (see https://aqtinstall.readthedocs.io/en/stable/configuration.html#configuration)
usage: aqt [-h] [-c CONFIG]
           {install-qt,install-tool,install-doc,install-example,install-src,list-qt,list-tool,list-doc,list-example,list-src,install,tool,doc,examples,src,help,version}
           ...

Another unofficial Qt Installer.
aqt helps you install Qt SDK, tools, examples and others

options:
  -h, --help            show this help message and exit
  -c CONFIG, --config CONFIG
                        Configuration ini file.

subcommands:
  aqt accepts several subcommands:
  install-* subcommands are commands that install components
  list-* subcommands are commands that show available components

  commands {install|tool|src|examples|doc} are deprecated and marked for removal

  {install-qt,install-tool,install-doc,install-example,install-src,list-qt,list-tool,list-doc,list-example,list-src,install,tool,doc,examples,src,help,version}
                        Please refer to each help message by using '--help' with each subcommand
Error: Error: The process '/usr/bin/python3' failed with exit code 1

We need to stabilize the CI runs. Maybe one way to improve is to cache the downloaded dependency.

terrychan999 commented 2 weeks ago

I've found that download.qt.io is frequently down these days. Although the install-qt-action uses aqtinstall, which has fallback mirrors, it still crashes due to the missing SHA256 checksum, which is only provided on download.qt.io. Reference: https://github.com/miurahr/aqtinstall/issues/521

We can use a custom setting.ini for aqtinstall to loosen the hash algorithm from SHA256 to SHA1, which is often provided by fallback mirrors. https://aqtinstall.readthedocs.io/en/latest/configuration.html This may sacrifice some security, but I believe it will make CI more robust.

yungyuc commented 2 weeks ago

Thanks for the swift fix in #368, @terrychan999 !