我正试图设置一个Github操作来测试我的使用wxPython的python应用程序,但我不知道如何在没有wxPython情况下进行设置
这是操作文件:
on:
pull_request:
branches:
- development
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- name: Set up Python 3.7
uses: actions/setup-python@v1
with:
python-version: 3.7
# pip install wheel
- name: Install Requirements
run: |
sudo apt-get update -q && sudo apt-get install
sudo apt-get install python-wxgtk3.0
python -m pip install --upgrade pip
pip install jsonschema
pip install pylint
pip install twisted
pip install wheel
pip install -U wxpython
run: |
cd src
export PYTHONPATH=`pwd`/keypad_controller
python ../pipelines/lint.py --path keypad_controller --threshold 10
我得到的错误是:1(
Building wheels for collected packages: wxpython
Building wheel for wxpython (setup.py): started
Building wheel for wxpython (setup.py): finished with status 'error'
Running setup.py clean for wxpython
ERROR: Command errored out with exit status 1:
command: /opt/hostedtoolcache/Python/3.7.9/x64/bin/python -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-uietf6rb/wxpython/setup.py'"'"'; __file__='"'"'/tmp/pip-install-uietf6rb/wxpython/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'rn'"'"', '"'"'n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' bdist_wheel -d /tmp/pip-wheel-05g1i2nj
cwd: /tmp/pip-install-uietf6rb/wxpython/
- 检查GTK+-版本>=3.0.0…在pkg配置搜索路径中找不到软件包gtk+-3.0。也许您应该添加包含"gtk+-3.0.pc"的目录到PKG_CONFIG_PATH环境变量未找到包"gtk+-3.0">
是否有一个Github操作"使用"wxPython,这样我就不必每次都安装它了?
通过在Install Requirements
步骤中添加以下行来安装python-wxgtk3.0-dev
:
sudo apt-get install python-wxgtk3.0-dev