Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

💚 ci: pin ubuntu to 22.04 #364

Merged
merged 2 commits into from
Oct 12, 2024
Merged

💚 ci: pin ubuntu to 22.04 #364

merged 2 commits into from
Oct 12, 2024

Conversation

SigureMo
Copy link
Member

动机

暂时将 ubuntu-latest 降级到 22.04,目前有两处因为 ubuntu-latest 升级到 24.04 挂掉

解决方案

  1. codspeed 明确尚未支持 24.04,见 Support for ubuntu 24.04 CodSpeedHQ/runner#42
______            __ _____                         __
  / ____/____   ____/ // ___/ ____   ___   ___   ____/ /
 / /    / __ \ / __  / \__ \ / __ \ / _ \ / _ \ / __  /
/ /___ / /_/ // /_/ / ___/ // /_/ //  __//  __// /_/ /
\____/ \____/ \__,_/ /____// .___/ \___/ \___/ \__,_/
  https://codspeed.io/     /_/          runner v3.0.0

Error: Error: Only Ubuntu 20.04 and 22.04 are supported at the moment
Error: Process completed with exit code 1.
  1. maturin sdist build 会挂掉,见 'error: externally-managed-environment' when building source distribution PyO3/maturin-action#291
Installing 'maturin' from tag 'v1.7.4'
  /usr/bin/tar xz --warning=no-unknown-keyword --overwrite -C /home/runner/work/_temp/60704b39-958a-466b-96dd-076018ffce2a -f /home/runner/work/_temp/cf93b7da-458b-430d-95d9-1dd5ecd8bc82
  Installed 'maturin' to /home/runner/work/_temp/60704b39-958a-466b-96dd-076018ffce2a/maturin
  /home/runner/work/_temp/60704b39-958a-466b-96dd-076018ffce2a/maturin --version
  maturin 1.7.4
  /usr/bin/python3 -m pip install cffi
  error: externally-managed-environment
  
  × This environment is externally managed
  ╰─> To install Python packages system-wide, try apt install
      python3-xyz, where xyz is the package you are trying to
      install.
      
      If you wish to install a non-Debian-packaged Python package,
      create a virtual environment using python3 -m venv path/to/venv.
      Then use path/to/venv/bin/python and path/to/venv/bin/pip. Make
      sure you have python3-full installed.
      
      If you wish to install a non-Debian packaged Python application,
      it may be easiest to use pipx install xyz, which will manage a
      virtual environment for you. Make sure you have pipx installed.
      
      See /usr/share/doc/python3.12/README.venv for more information.
  
  note: If you believe this is a mistake, please contact your Python installation or OS distribution provider. You can override this, at the risk of breaking your Python installation or OS, by passing --break-system-packages.
  hint: See PEP 668 for the detailed specification.
  /usr/bin/python3 -m pip install patchelf
  error: externally-managed-environment
  
  × This environment is externally managed
  ╰─> To install Python packages system-wide, try apt install
      python3-xyz, where xyz is the package you are trying to
      install.
      
      If you wish to install a non-Debian-packaged Python package,
      create a virtual environment using python3 -m venv path/to/venv.
      Then use path/to/venv/bin/python and path/to/venv/bin/pip. Make
      sure you have python3-full installed.
      
      If you wish to install a non-Debian packaged Python application,
      it may be easiest to use pipx install xyz, which will manage a
      virtual environment for you. Make sure you have pipx installed.
      
      See /usr/share/doc/python3.12/README.venv for more information.
  
  note: If you believe this is a mistake, please contact your Python installation or OS distribution provider. You can override this, at the risk of breaking your Python installation or OS, by passing --break-system-packages.
  hint: See PEP 668 for the detailed specification.
  Error: The process '/usr/bin/python3' failed with exit code 1
      at ExecState._setResult (/home/runner/work/_actions/PyO3/maturin-action/v1/dist/index.js:1702:25)
      at ExecState.CheckComplete (/home/runner/work/_actions/PyO3/maturin-action/v1/dist/index.js:1685:18)
      at ChildProcess.<anonymous> (/home/runner/work/_actions/PyO3/maturin-action/v1/dist/index.js:[15](https://github.com/yutto-dev/yutto/actions/runs/11305888881/job/31445873638?pr=363#step:3:17)79:27)
      at ChildProcess.emit (node:events:519:28)
      at maybeClose (node:internal/child_process:1105:[16](https://github.com/yutto-dev/yutto/actions/runs/11305888881/job/31445873638?pr=363#step:3:18))
      at ChildProcess._handle.onexit (node:internal/child_process:305:5)

后续待全部支持后会重新改回 ubuntu-latest

类型

  • ✨ feat: 添加新功能
  • 🐛 fix: 修复 bug
  • 📝 docs: 对文档进行修改
  • ♻️ refactor: 代码重构(既不是新增功能,也不是修改 bug 的代码变动)
  • ⚡ perf: 提高性能的代码修改
  • 🧑‍💻 dx: 优化开发体验
  • 🔨 workflow: 工作流变动
  • 🏷️ types: 类型声明修改
  • 🚧 wip: 工作正在进行中
  • ✅ test: 测试用例添加及修改
  • 🔨 build: 影响构建系统或外部依赖关系的更改
  • 👷 ci: 更改 CI 配置文件和脚本
  • ❓ chore: 其它不涉及源码以及测试的修改
  • ⬆️ deps: 依赖项修改
  • 🔖 release: 发布新版本

Copy link

codspeed-hq bot commented Oct 12, 2024

CodSpeed Performance Report

Merging #364 will not alter performance

Comparing pin-ubuntu-to-2204 (33d6228) with main (22d9df2)

Summary

✅ 30 untouched benchmarks

@SigureMo SigureMo merged commit fefef57 into main Oct 12, 2024
30 checks passed
@SigureMo SigureMo deleted the pin-ubuntu-to-2204 branch October 12, 2024 13:27
SigureMo added a commit that referenced this pull request Oct 20, 2024
github-merge-queue bot pushed a commit that referenced this pull request Oct 20, 2024
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: SigureMo <sigure.qaq@gmail.com>
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