Skip to content

[Another nit] Opening an empty image would crash in python space #153

[Another nit] Opening an empty image would crash in python space

[Another nit] Opening an empty image would crash in python space #153

Workflow file for this run

# This workflow will build a gopy project
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-go
name: Gopy
on:
push:
branches: ["main"]
pull_request:
branches: ["main"]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install linux deps
run: |
sudo apt-get update
sudo apt-get -y install libvips-dev libjpeg-turbo8-dev
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: "1.23"
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.11.10"
- name: Install pybindgen
run: |
python3 -m pip install pybindgen
go install golang.org/x/tools/cmd/goimports@latest
go install github.com/go-python/gopy@latest
- name: Build python module
run: |
cd pkg
gopy pkg -author="Photoroom" -email="[email protected]" -vm="python3" -name="datago" .
export DESTINATION="../build"
mkdir -p $DESTINATION/datago
mv datago/* $DESTINATION/datago/.
mv setup.py $DESTINATION/.
mv Makefile $DESTINATION/.
mv README.md $DESTINATION/.
rm LICENSE MANIFEST.in
ls
cd ../build
- name: Install python module
run: |
ls
cd build
python3 -m pip install --user -v -e .
- name: Run the python unit tests
env:
DATAROOM_API_KEY: ${{ secrets.DATAROOM_API_KEY }}
DATAROOM_TEST_SOURCE: ${{ secrets.DATAROOM_TEST_SOURCE }}
DATAROOM_API_URL: ${{ secrets.DATAROOM_API_URL }}
run: |
ls
python3 -m pip install -r requirements-tests.txt
pytest -xv python/*