Skip to content

Commit 8bacc5d

Browse files
committed
Fix CI
Signed-off-by: Tsuyoshi Hombashi <tsuyoshi.hombashi@gmail.com>
1 parent b1363da commit 8bacc5d

File tree

5 files changed

+22
-74
lines changed

5 files changed

+22
-74
lines changed

.github/workflows/ci.yml

Lines changed: 18 additions & 70 deletions
Original file line numberDiff line numberDiff line change
@@ -88,83 +88,31 @@ jobs:
8888
- run: make setup-ci
8989

9090
- name: Run tests
91-
run: tox -e py
91+
run: tox -e cov
9292

93-
run-coverage:
94-
runs-on: ${{ matrix.os }}
95-
strategy:
96-
fail-fast: false
97-
matrix:
98-
python-version: ["3.13"]
99-
os: [ubuntu-latest, macos-latest, windows-latest]
100-
timeout-minutes: 20
101-
defaults:
102-
run:
103-
shell: bash
104-
105-
steps:
106-
- uses: actions/checkout@v4
107-
108-
- name: Setup Python ${{ matrix.python-version }}
109-
uses: actions/setup-python@v5
110-
with:
111-
python-version: ${{ matrix.python-version }}
112-
cache: pip
113-
cache-dependency-path: |
114-
setup.py
115-
**/*requirements.txt
116-
tox.ini
117-
118-
- name: Setup env
119-
run: echo "COVERAGE_FILE=.coverage_${{ matrix.os }}_${{ matrix.python-version }} " >> $GITHUB_ENV
120-
121-
- run: make setup-ci
93+
- name: Install coveralls
94+
run: python -m pip install --upgrade --disable-pip-version-check coveralls tomli
12295

123-
- name: Run tests
96+
- name: Upload coverage data to coveralls.io
12497
env:
125-
PYTEST_DISCORD_WEBHOOK: ${{ secrets.PYTEST_DISCORD_WEBHOOK }}
126-
run: tox -e cov -- --discord-verbose=0
127-
128-
- run: ls -a
129-
130-
- uses: actions/upload-artifact@v4
131-
with:
132-
name: coverage
133-
path: .coverage_*
98+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
99+
COVERALLS_FLAG_NAME: ${{ matrix.os }}-${{ matrix.python-version }}
100+
COVERALLS_PARALLEL: true
101+
run: coveralls
134102

135-
upload-coverage:
136-
needs: run-coverage
103+
coveralls:
104+
name: Indicate completion to coveralls.io
105+
needs: unit-test
137106
runs-on: ubuntu-latest
138-
timeout-minutes: 20
107+
container: python:3-slim
139108

140109
steps:
141-
- uses: actions/checkout@v4
142-
143-
- uses: actions/download-artifact@v4
144-
with:
145-
name: coverage
146-
path: artifact
110+
- run: python -m pip install --upgrade coveralls
147111

148-
- name: List
149-
working-directory: artifact
150-
run: |
151-
set -x
152-
153-
pwd
154-
ls -alR
155-
156-
- name: Install packages
157-
run: python -m pip install --upgrade --disable-pip-version-check coveralls tomli
158-
159-
- name: Combine coverage reports
160-
run: |
161-
coverage combine artifact/.coverage_*
162-
ls -alR
163-
164-
- name: Upload coverage report
165-
env:
166-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
167-
run: coveralls --service=github
112+
- name: Finished
113+
env:
114+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
115+
run: coveralls --finish
168116

169117
run-sample:
170118
runs-on: ubuntu-latest
@@ -188,7 +136,7 @@ jobs:
188136
189137
- name: Install packages
190138
run: |
191-
make setup
139+
make setup-dev
192140
python -m pip install --upgrade --disable-pip-version-check pandas pytablereader[excel] XlsxWriter
193141
194142
- run: make run-sample

requirements/test_requirements.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
pytablereader>=0.31.3
22
pytablewriter>=0.50
33
pytest>=6.0.1
4-
pytest-discord>=0.1.6
4+
# pytest-discord>=0.1.6
55
pytest-md-report>=0.6.2
66
beautifulsoup4>=4.10

simplesqlite/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
.. codeauthor:: Tsuyoshi Hombashi <tsuyoshi.hombashi@gmail.com>
33
"""
44

5-
import simplesqlite.query # type: ignore
5+
import simplesqlite.query # noqa: F401
66

77
from .__version__ import __author__, __copyright__, __email__, __license__, __version__
88
from ._func import append_table, copy_table

simplesqlite/error.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
import sqlite3
66
from typing import Any, Optional
77

8-
from tabledata import NameValidationError # noqa: W0611
8+
from tabledata import NameValidationError # noqa: F401
99

1010

1111
class DatabaseError(sqlite3.DatabaseError):

tox.ini

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ commands =
7272
pyright simplesqlite setup.py
7373
codespell simplesqlite docs/pages test -q2 --check-filenames --ignore-words-list te -x "test/data/python - Wiktionary.html"
7474
ruff format --check setup.py test simplesqlite
75-
ruff check setup.py test simplesqlite
75+
ruff check setup.py simplesqlite
7676

7777
[testenv:lint-examples]
7878
extras =

0 commit comments

Comments
 (0)