Skip to content

Commit

Permalink
fix verify install steps... again
Browse files Browse the repository at this point in the history
  • Loading branch information
wey-gu committed Jan 5, 2025
1 parent f8a1016 commit 82554b5
Show file tree
Hide file tree
Showing 2 changed files with 61 additions and 19 deletions.
74 changes: 57 additions & 17 deletions .github/workflows/package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -110,11 +110,17 @@ jobs:
- name: Create dist directory
run: mkdir -p dist

- name: Download main package
uses: actions/download-artifact@v3
with:
name: dist-main
path: dist/
- name: Install build dependencies
run: pip install maturin

- name: Build service package (debug)
run: |
cd crates/service-${{ matrix.service }}
maturin build --release --out ../../dist
echo "=== Build directory contents ==="
find ../../dist -type f
echo "=== Target wheels contents ==="
find ../../target/wheels -type f || true
- name: Build service package
id: build-service
Expand All @@ -123,12 +129,26 @@ jobs:
target: ${{ matrix.target }}
manylinux: ${{ matrix.platform }}
container: quay.io/pypa/manylinux2014_x86_64
args: --release --out dist
args: --release --out dist --interpreter python3.11
command: build
working-directory: crates/service-${{ matrix.service }}

- name: List dist contents
run: ls -la dist/
run: |
echo "=== Service build output ==="
ls -la dist/
echo "=== Wheel details ==="
find dist -name "*.whl" -exec sh -c 'echo "$1"; unzip -l "$1"' _ {} \;
echo "=== All possible wheel locations ==="
find . -name "*.whl"
- name: Copy wheels to dist
run: |
# Ensure all wheels are in dist directory
mkdir -p dist
find . -name "*.whl" -exec cp {} dist/ \;
echo "=== Final dist contents ==="
ls -la dist/
- name: Upload service artifact
uses: actions/upload-artifact@v3
Expand Down Expand Up @@ -157,29 +177,49 @@ jobs:

- name: List downloaded artifacts
run: |
echo "=== All artifacts ==="
find dist -type f
echo "=== Service artifacts ==="
find dist/dist-ubuntu-24.04-x86_64-memory dist/dist-ubuntu-24.04-x86_64-s3 -type f
- name: Prepare dist directory
run: |
mkdir -p dist_combined
# First copy service packages
cp -r dist/dist-ubuntu-24.04-x86_64-memory/* dist_combined/
cp -r dist/dist-ubuntu-24.04-x86_64-s3/* dist_combined/
# Then copy main package
cp -r dist/dist-main/* dist_combined/
# Copy service wheels first (only cp311 wheels)
cp dist/dist-ubuntu-24.04-x86_64-memory/*cp311*.whl dist_combined/
cp dist/dist-ubuntu-24.04-x86_64-s3/*cp311*.whl dist_combined/
# Copy main package
cp dist/dist-main/*.whl dist_combined/
cp dist/dist-main/*.tar.gz dist_combined/
echo "=== Contents of dist_combined ==="
ls -la dist_combined/
- name: Install packages in correct order
run: |
python -m pip install --upgrade pip
# First install service packages
pip install dist_combined/*service_memory*.whl
pip install dist_combined/*service_s3*.whl
# Then install main package
pip install dist_combined/opendalfs*.whl
echo "=== Installing service packages ==="
# Install memory service (only cp311 wheels)
for whl in dist_combined/opendalfs_service_memory*cp311*.whl; do
if [ -f "$whl" ]; then
echo "Installing memory service: $whl"
pip install "$whl"
fi
done
# Install s3 service (only cp311 wheels)
for whl in dist_combined/opendalfs_service_s3*cp311*.whl; do
if [ -f "$whl" ]; then
echo "Installing s3 service: $whl"
pip install "$whl"
fi
done
echo "=== Installing main package ==="
pip install dist_combined/opendalfs-*.whl
- name: Verify imports
run: |
echo "=== Installed packages ==="
pip list | grep opendalfs
echo "=== Verifying imports ==="
python -c "import opendalfs"
python -c "import opendalfs_service_memory"
python -c "import opendalfs_service_s3"
Expand Down
6 changes: 4 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,15 @@ name = "opendalfs"
version = "0.0.1"
classifiers = [
"Development Status :: 4 - Beta",
"Intended Audience :: Developers",
"Intended Audience :: Developers",
"License :: OSI Approved :: Apache Software License",
"Operating System :: OS Independent",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
]
dependencies = [
"fsspec",
]

[project.optional-dependencies]
# Runtime optional dependencies
Expand All @@ -28,7 +31,6 @@ test = [
"pytest", # Test framework
"pytest-asyncio", # Async test support
"pytest-cov", # Coverage reporting
"fsspec", # Filesystem interface
"s3fs", # S3 filesystem support
"boto3", # AWS S3 client for environment provision
]
Expand Down

0 comments on commit 82554b5

Please sign in to comment.