Skip to content

fix: Fix setup error occurring on Windows and added Windows ci tests #85

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

Merged
merged 8 commits into from
Dec 19, 2022
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
51 changes: 36 additions & 15 deletions .github/workflows/python-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,23 +13,44 @@ on:
- main

jobs:
build:
test-ubuntu:
runs-on: ubuntu-latest

strategy:
matrix:
python-version: ['3.7', '3.8', '3.9', '3.10', '3.11']
python-version: ["3.7", "3.8", "3.9", "3.10", "3.11"]

steps:
- uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install -r requirements.txt -e ".[dev]"
python -m pip install --pre tox-gh-actions
- name: Test with pytest
run: |
# remove '.' in python-version and prepend with 'py' to get the correct tox env
tox -e py$(echo ${{ matrix.python-version }} | sed 's/\.//g')

test-windows:
runs-on: windows-latest

steps:
- uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install -r requirements.txt -e ".[dev]"
- name: Test with pytest
run: |
# remove '.' in python-version and prepend with 'py' to get the correct tox env
tox -e py$(echo ${{ matrix.python-version }} | sed 's/\.//g')
- uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: "3.7"
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install -r requirements.txt -e ".[dev]"
python -m pip install --pre tox-gh-actions
- name: Test with pytest
run: tox
env:
PLATFORM: windows-latest
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ def long_description():
# check if README.md exists
if not os.path.exists("README.md"):
return ""
with open("README.md", "r") as fh:
with open("README.md", "r", encoding="utf-8") as fh:
return fh.read()


Expand Down