TE-4262: Releasing SDK version 25.12.1 #5
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Build SDK | |
| on: | |
| pull_request: | |
| paths: | |
| - 'graphiant_sdk/**' | |
| - 'setup.py' | |
| - 'pyproject.toml' | |
| - 'MANIFEST.in' | |
| - '.github/workflows/build.yml' | |
| push: | |
| branches: | |
| - main | |
| - develop | |
| paths: | |
| - 'graphiant_sdk/**' | |
| - 'setup.py' | |
| - 'pyproject.toml' | |
| - 'MANIFEST.in' | |
| - '.github/workflows/build.yml' | |
| workflow_dispatch: | |
| jobs: | |
| build: | |
| name: Build Package | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v4 | |
| - name: Set up Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: '3.12' | |
| cache: 'pip' | |
| - name: Install build dependencies | |
| run: | | |
| python -m pip install --upgrade pip | |
| pip install build wheel | |
| - name: Create build directory | |
| run: | | |
| mkdir -p ${{ github.workspace }}/dist | |
| - name: Build package | |
| run: | | |
| python -m build | |
| - name: Upload build artifacts | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: python-package | |
| path: dist/* | |
| retention-days: 7 | |
| - name: Verify build artifacts | |
| run: | | |
| if [ ! -f dist/*.whl ] && [ ! -f dist/*.tar.gz ]; then | |
| echo "Error: Package files not found in dist directory" | |
| exit 1 | |
| fi | |
| echo "✅ Package built successfully" | |
| ls -lh dist/ |