diff --git a/.github/workflows/package.yml b/.github/workflows/package.yml index 4a0e362..6c36f58 100644 --- a/.github/workflows/package.yml +++ b/.github/workflows/package.yml @@ -97,19 +97,12 @@ jobs: exclude: - os: macos-latest target: aarch64 - - os: ubuntu-24.04 - target: aarch64 # It's too slow in non-native environment in github actions include: - os: ubuntu-24.04 target: x86_64 platform: manylinux2014 container: quay.io/pypa/manylinux2014_x86_64 docker_platform: linux/amd64 - # - os: ubuntu-24.04 - # target: aarch64 - # platform: manylinux2014 - # container: quay.io/pypa/manylinux2014_aarch64 - # docker_platform: linux/arm64 - os: macos-latest target: x86_64 platform: native @@ -120,16 +113,6 @@ jobs: - name: Checkout repository uses: actions/checkout@v4 - # - name: Set up QEMU - # if: matrix.target == 'aarch64' - # uses: docker/setup-qemu-action@v3 - # with: - # platforms: arm64 - - # - name: Set up Docker Buildx - # if: matrix.target == 'aarch64' - # uses: docker/setup-buildx-action@v3 - - name: Set up Python 3.11 uses: actions/setup-python@v4 with: @@ -142,7 +125,12 @@ jobs: uses: actions/download-artifact@v3 with: name: dist-main - path: dist/ + path: dist/main-pkg/ + + - name: Install main package + run: | + python -m pip install --upgrade pip + pip install dist/main-pkg/opendalfs-*.whl - name: Build service package id: build-service @@ -156,14 +144,26 @@ jobs: working-directory: crates/service-${{ matrix.service }} docker-options: --platform ${{ matrix.docker_platform }} - - name: List dist contents - run: ls -la dist/ + - name: List all dist directories + run: | + echo "Current directory contents:" + ls -la + echo "\nDist directory contents:" + ls -la dist/ || true + echo "\nTarget directory contents:" + ls -la target/wheels/ || true + echo "\nCrates service directory contents:" + ls -la crates/service-${{ matrix.service }}/target/wheels/ || true + find . -name "*.whl" - name: Upload service artifact uses: actions/upload-artifact@v3 with: name: dist-${{ matrix.os }}-${{ matrix.target }}-${{ matrix.service }} - path: dist/*.whl + path: | + dist/*.whl + target/wheels/*.whl + crates/service-${{ matrix.service }}/target/wheels/*.whl if-no-files-found: error verify-install: @@ -194,16 +194,22 @@ jobs: # Copy main package first cp -r dist/dist-main/* dist_combined/ - # List what we have so far echo "Main package contents:" ls -la dist_combined/ - # Now copy service wheels, being careful about naming + # Now copy service wheels with error handling + echo "Copying service wheels:" for os in ubuntu-24.04 macos-latest; do for service in memory s3; do - echo "Copying $os $service service:" - find "dist/dist-$os-x86_64-$service" -name "*.whl" -exec ls -la {} \; - find "dist/dist-$os-x86_64-$service" -name "*.whl" -exec cp {} dist_combined/ \; + echo "Processing $os $service service:" + wheel=$(find "dist/dist-$os-x86_64-$service" -name "*.whl") + if [ -n "$wheel" ]; then + echo "Found wheel: $wheel" + cp "$wheel" "dist_combined/opendalfs_service_${service}-0.0.1-py3-none-any.whl" + else + echo "No wheel found for $os $service" + exit 1 + fi done done @@ -216,10 +222,8 @@ jobs: # Install main package first pip install dist_combined/opendalfs-*.whl # Then install service packages - for wheel in dist_combined/*service*.whl; do - echo "Installing $wheel" - pip install "$wheel" - done + pip install dist_combined/opendalfs_service_memory*.whl + pip install dist_combined/opendalfs_service_s3*.whl - name: Verify imports run: |