Skip to content

Commit

Permalink
fix: intel build
Browse files Browse the repository at this point in the history
  • Loading branch information
0xArdi authored Aug 9, 2024
1 parent e4b794b commit b04a826
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 5 deletions.
19 changes: 14 additions & 5 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -154,10 +154,10 @@ jobs:
$CMD service deploy --name '${{ vars.SERVICE_NAME }}' --service-dir $SERVICE_PATH --service-ipfs-hash $IPFS_HASH --ingress-enabled true --keys '${{ vars.SERVICE_KEYS }}' --timeout 320
build-macos-pyinstaller:
runs-on: macos-latest
runs-on: ${{ matrix.os }}
strategy:
matrix:
arch: [ x64, arm64 ]
os: [ macos-14, macos-14-large ]

steps:
- uses: actions/checkout@v3
Expand All @@ -177,14 +177,23 @@ jobs:
- name: Install dependencies
run: poetry install

- name: Set arch environment variable for macos-latest-large
if: contains(matrix.os, 'large')
run: echo "OS_ARCH=x64" >> $GITHUB_ENV

- name: Set arch environment variable for other macOS versions
if: ${{ !contains(matrix.os, 'large') }}
run: echo "OS_ARCH=arm64" >> $GITHUB_ENV

- name: Build with PyInstaller
run: |
poetry run pyinstaller --collect-data eth_account --collect-all aea --collect-all autonomy --collect-all operate --collect-all aea_ledger_ethereum --collect-all aea_ledger_cosmos --collect-all aea_ledger_ethereum_flashbots --hidden-import aea_ledger_ethereum --hidden-import aea_ledger_cosmos --hidden-import aea_ledger_ethereum_flashbots --hidden-import grpc --hidden-import openapi_core --collect-all google.protobuf --collect-all openapi_core --collect-all openapi_spec_validator --collect-all asn1crypto --hidden-import py_ecc --hidden-import pytz --onefile pyinstaller/trader_bin.py --name trader_bin_${{ matrix.arch }}
poetry run pyinstaller --collect-data eth_account --collect-all aea --collect-all autonomy --collect-all operate --collect-all aea_ledger_ethereum --collect-all aea_ledger_cosmos --collect-all aea_ledger_ethereum_flashbots --hidden-import aea_ledger_ethereum --hidden-import aea_ledger_cosmos --hidden-import aea_ledger_ethereum_flashbots --hidden-import grpc --hidden-import openapi_core --collect-all google.protobuf --collect-all openapi_core --collect-all openapi_spec_validator --collect-all asn1crypto --hidden-import py_ecc --hidden-import pytz --onefile pyinstaller/trader_bin.py --name trader_bin_${{env.OS_ARCH}}
- name: Upload Release Assets
uses: actions/upload-artifact@v2
with:
name: trader_bin_${{ matrix.arch }}
path: dist/trader_bin_${{ matrix.arch }}
name: trader_bin_${{env.OS_ARCH}}
path: dist/trader_bin_${{env.OS_ARCH}}

upload-assets:
needs: build-macos-pyinstaller
runs-on: ubuntu-latest
Expand Down
2 changes: 2 additions & 0 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -636,3 +636,5 @@ pathable: ==0.4.3
; false positive
pyinstaller: ==6.8.0
pyinstaller-hooks-contrib: >=2024.6
; sub-dep of aiohttp, has PSF-2.0 License https://github.com/aio-libs/aiohappyeyeballs/blob/main/LICENSE
aiohappyeyeballs: >=2.3.4,<3.0.0

0 comments on commit b04a826

Please sign in to comment.