-
-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
35 changed files
with
1,023 additions
and
392 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
<!doctype html> | ||
<html> | ||
<head> | ||
<title>This is the title of the webpage!</title> | ||
</head> | ||
<body> | ||
<p>This is an example paragraph. Anything in the <strong>body</strong> tag will appear on the page, just like this <strong>p</strong> tag and its contents.</p> | ||
</body> | ||
</html> |
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -33,16 +33,19 @@ jobs: | |
- | ||
name: Install Hatch | ||
run: | | ||
pip3 --quiet install --upgrade hatch | ||
pip3 --quiet install --upgrade hatch uv | ||
hatch --version | ||
uv --version | ||
- | ||
name: Lint project | ||
run: | | ||
hatch run lint:all | ||
hatch fmt --check | ||
- | ||
name: Check files with pre-commit | ||
uses: pre-commit/[email protected] | ||
uses: pre-commit/[email protected] | ||
|
||
test: | ||
name: Python ${{ matrix.python-version }} | ||
name: Test (Python ${{ matrix.python-version }}) | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: read | ||
|
@@ -52,7 +55,7 @@ jobs: | |
fail-fast: false | ||
matrix: | ||
# No pikepdf wheels for pypy3.8 | ||
python-version: ['3.8', '3.9', '3.10', '3.11', '3.12', 'pypy3.9'] | ||
python-version: ['3.8', '3.9', '3.10', '3.11', '3.12', 'pypy3.9', 'pypy3.10'] | ||
|
||
steps: | ||
- | ||
|
@@ -79,15 +82,22 @@ jobs: | |
- | ||
name: Install Hatch | ||
run: | | ||
python3 -m pip install --upgrade pip | ||
pip install --upgrade hatch | ||
pip3 --quiet install --upgrade hatch uv | ||
hatch --version | ||
uv --version | ||
- | ||
name: Show environment | ||
run: | | ||
hatch test --show --python ${{ matrix.python-version }} | ||
- | ||
name: Run tests | ||
run: hatch run cov | ||
run: | | ||
hatch test --cover --python ${{ matrix.python-version }} | ||
ls -ahl . | ||
- | ||
name: Upload coverage to Codecov | ||
if: matrix.python-version == '3.10' | ||
uses: codecov/codecov-action@v3 | ||
uses: codecov/codecov-action@v4 | ||
with: | ||
# not required for public repos, but intermittently fails otherwise | ||
token: ${{ secrets.CODECOV_TOKEN }} | ||
|
@@ -97,50 +107,7 @@ jobs: | |
run: | | ||
docker compose --file ${GITHUB_WORKSPACE}/.docker/docker-compose.ci-test.yml logs | ||
docker compose --file ${GITHUB_WORKSPACE}/.docker/docker-compose.ci-test.yml down | ||
test-edge: | ||
name: Test Gotenberg :edge | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: read | ||
needs: | ||
- lint | ||
steps: | ||
- | ||
uses: actions/checkout@v4 | ||
- | ||
name: Start containers | ||
run: | | ||
docker compose --file ${GITHUB_WORKSPACE}/.docker/docker-compose.ci-test-edge.yml pull --quiet | ||
docker compose --file ${GITHUB_WORKSPACE}/.docker/docker-compose.ci-test-edge.yml up --detach | ||
echo "Wait for container to be started" | ||
sleep 5 | ||
docker inspect gotenberg-client-test-edge-server | ||
- | ||
name: Install poppler-utils | ||
run: | | ||
sudo apt-get update | ||
sudo apt-get install --yes --no-install-recommends poppler-utils | ||
- | ||
name: Set up Python 3.11 | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: "3.11" | ||
cache: 'pip' | ||
- | ||
name: Install Hatch | ||
run: | | ||
python3 -m pip install --upgrade pip | ||
pip install --upgrade hatch | ||
- | ||
name: Run tests | ||
continue-on-error: true | ||
run: hatch run cov | ||
- | ||
name: Stop containers | ||
if: always() | ||
run: | | ||
docker compose --file ${GITHUB_WORKSPACE}/.docker/docker-compose.ci-test-edge.yml logs | ||
docker compose --file ${GITHUB_WORKSPACE}/.docker/docker-compose.ci-test-edge.yml down | ||
build: | ||
name: Build | ||
runs-on: ubuntu-latest | ||
|
@@ -160,7 +127,9 @@ jobs: | |
- | ||
name: Install Hatch | ||
run: | | ||
pip3 --quiet install --upgrade hatch | ||
pip3 --quiet install --upgrade hatch uv | ||
hatch --version | ||
uv --version | ||
- | ||
name: Build | ||
run: | | ||
|
@@ -235,7 +204,7 @@ jobs: | |
- | ||
name: Get latest release info | ||
id: query-release-info | ||
uses: release-flow/keep-a-changelog-action@v2 | ||
uses: release-flow/keep-a-changelog-action@v3 | ||
with: | ||
command: query | ||
version: ${{ github.ref_name }} | ||
|
@@ -269,4 +238,4 @@ jobs: | |
path: dist | ||
- | ||
name: Publish build to PyPI | ||
uses: pypa/[email protected].11 | ||
uses: pypa/[email protected].14 |
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
{ | ||
"files.exclude": { | ||
"**/__pycache__": true, | ||
"**/.mypy_cache": true, | ||
"**/.ruff_cache": true, | ||
"**/.pytest_cache": true, | ||
"**/.cache": true, | ||
"**/.coverage*": true | ||
} | ||
} |
This file contains 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
This file contains 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
This file was deleted.
Oops, something went wrong.
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
../CHANGELOG.md |
Oops, something went wrong.