Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Gtad generating. BaseJob. #15

Merged
merged 21 commits into from
Jul 16, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 17 additions & 11 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,8 @@ jobs:
max-parallel: 1
matrix:
os: [ubuntu-20.04, macos-10.15]
qt-version: [ '6.1.1' ]
qt-version: [ '6.1.2' ]
python-version: [ '3.8' ]

steps:
- uses: actions/checkout@v2
Expand All @@ -34,36 +35,39 @@ jobs:
with:
version: ${{ matrix.qt-version }}
cached: ${{ steps.cache-qt.outputs.cache-hit }}
aqtversion: ==1.2.0b3 # <1.2.0 has problem with osx installation of Qt 6
aqtversion: ==1.2.4 # <1.2.0 has problem with osx installation of Qt 6

- name: Cache Python dependencies
if: ${{ runner.os == 'Linux' }}
uses: actions/cache@v2
with:
path: /home/runner/.cache/pypoetry/
key: ${{ hashFiles('**/poetry.lock') }}
key: ${{ matrix.python-version }}-${{ hashFiles('**/poetry.lock') }}

- name: Cache Python dependencies
if: ${{ runner.os == 'macOS' }}
uses: actions/cache@v2
with:
path: /Users/runner/Library/Caches/pypoetry/
key: ${{ hashFiles('**/poetry.lock') }}
key: ${{ matrix.python-version }}-${{ hashFiles('**/poetry.lock') }}

- name: Set up Python 3.9
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: 3.9
python-version: ${{ matrix.python-version }}

- name: Install dependencies
run: |
if [ "${{ matrix.os }}" == "ubuntu-20.04" ]; then
sudo apt-get install llvm
fi

python -m pip install --upgrade pip
curl -sSL https://raw.githubusercontent.com/python-poetry/poetry/master/install-poetry.py > poetry.py
python3 poetry.py --version 1.2.0a1
python${{ matrix.python-version }} -m pip install --upgrade pip
git clone --depth 1 --single-branch --branch 1.2.0a1 https://github.com/python-poetry/poetry.git
pushd poetry
python${{ matrix.python-version }} install-poetry.py --version 1.2.0a1
popd
rm -r poetry
echo "$HOME/.local/bin" >> $GITHUB_PATH

if [ "${{ runner.os }}" == "macOS" ]; then
Expand All @@ -75,20 +79,22 @@ jobs:
ln -sf $Qt6_DIR/lib/QtGui.framework/Versions/A/Headers/* $Qt6_DIR/lib/QtGui.framework/Versions/A/Headers/${{ matrix.qt-version }}/QtGui/
ln -sf $Qt6_DIR/lib/QtNetwork.framework/Versions/A/Headers/* $Qt6_DIR/lib/QtNetwork.framework/Versions/A/Headers/${{ matrix.qt-version }}/QtNetwork/
fi

poetry env use ${{ matrix.python-version }}
poetry install --verbose
poetry run pip3 install PySide6 # temporary workaround, poetry can't install PySide6. TODO: investigate
# git clone https://github.com/quotient-im/libQuotient.git PyQuotient/libQuotient
git clone https://github.com/Aksem/libQuotient.git -b qt-6.1 PyQuotient/libQuotient

- name: Build
run: |
poetry env use ${{ matrix.python-version }}
mkdir -p build
pushd build
cmake -DBUILD_TESTING=OFF -DBUILD_WITH_QT6=ON -DQT_PATH=$Qt6_DIR -DPYTHON_ENV_VERSION=3.9 ../
cmake -DBUILD_TESTING=OFF -DBUILD_WITH_QT6=ON -DQT_PATH=$Qt6_DIR -DPYTHON_ENV_VERSION=${{ matrix.python-version }} ../
make
popd

- name: Run unit tests
run: |
poetry env use ${{ matrix.python-version }}
poetry run python3 -m pytest
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,5 @@ PyQuotient/libQuotient.a

__pycache__
.pytest_cache

.vscode
17 changes: 0 additions & 17 deletions .vscode/c_cpp_properties.json

This file was deleted.

17 changes: 0 additions & 17 deletions .vscode/cmake-variants.yaml

This file was deleted.

40 changes: 0 additions & 40 deletions .vscode/settings.json

This file was deleted.

Loading