-
Notifications
You must be signed in to change notification settings - Fork 586
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
macos-latest and universal2 build error: cpython-312-darwin.so is not a fat binary! #993
Comments
Hello @dmitry-mightydevops , |
We have investigated the issue and were able to successfully run the script on our end without reproducing the error. To help us investigate further, could you please provide the following information:
Thank you! |
Hello @dmitry-mightydevops , Just a gentle reminder! Could you please let us know if there are any updates from your side regarding this issue? Thank you! |
Seconding @dmitry-mightydevops having this issue. Can't provide a public repo atm, though |
@lmvysakh sorry for the delay, it fails on this repo for me |
In case it helps here's my CI yaml: name: Build with PyInstaller
on:
release:
types: [published]
jobs:
build:
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.11' # Change to your required Python version
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install pyinstaller
pip install -r requirements.txt
- name: Build executable
if: runner.os != 'macOS'
run: |
pyinstaller --onefile --paths=app app/app.py
- name: Build macOS universal executable
if: runner.os == 'macOS'
run: |
pyinstaller --onefile --paths=app --target-arch universal2 app/app.py
- name: Archive executable (Linux)
if: runner.os == 'Linux'
run: tar -czvf dist/linux-build.tar.gz dist/app
- name: Archive executable (macOS)
if: runner.os == 'macOS'
run: tar -czvf dist/macos-build.tar.gz dist/app
- name: Archive executable (Windows)
if: runner.os == 'Windows'
run: Compress-Archive -Path dist\app.exe -DestinationPath dist\windows-build.zip
- name: Upload artifacts
uses: actions/upload-artifact@v4
with:
name: ${{ matrix.os }}-build
path: |
dist/linux-build.tar.gz
dist/macos-build.tar.gz
dist/windows-build.zip
- name: Upload Linux build as release asset
if: runner.os == 'Linux'
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: dist/linux-build.tar.gz
asset_name: linux-build.tar.gz
asset_content_type: application/gzip
- name: Upload macOS build as release asset
if: runner.os == 'macOS'
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: dist/macos-build.tar.gz
asset_name: macos-build.tar.gz
asset_content_type: application/gzip
- name: Upload Windows build as release asset
if: runner.os == 'Windows'
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: dist/windows-build.zip
asset_name: windows-build.zip
asset_content_type: application/zip |
Description:
🆘 Unable to produce universal2 build (x86 + arm64 combined into one) with pyinstaller on macos-latest runner
I'm getting the following error:
produces the error:
PyInstaller.utils.osx.IncompatibleBinaryArchError: /Users/runner/Library/Caches/pypoetry/virtualenvs/ksso-REv962lH-py3.12/lib/python3.12/site-packages/markupsafe/_speedups.cpython-312-darwin.so is not a fat binary! For details about this error message, see: https://pyinstaller.org/en/stable/feature-notes.html#macos-multi-arch-support
Action version:
ctions/setup-python@v4
Platform:
Runner type:
Tools version:
Repro steps:
A description with steps to reproduce the issue. If your have a public example or repo to share, please provide the link.
Pipeline code:
Expected behavior:
A universal2 build to be produced without errors on macos-latest runner
Actual behavior:
Build fails with the error
Error log
The text was updated successfully, but these errors were encountered: