Skip to content

Commit 273e642

Browse files
committed
naming update
1 parent e5cbb35 commit 273e642

14 files changed

+199
-167
lines changed

.github/workflows/_check_code.yaml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
name: Code checks
2+
3+
on:
4+
# Runs when manually triggered from the GitHub UI.
5+
workflow_dispatch:
6+
7+
# Runs when invoked by another workflow.
8+
workflow_call:
9+
10+
jobs:
11+
actions_lint_check:
12+
name: Actions lint check
13+
runs-on: ubuntu-latest
14+
steps:
15+
- name: Checkout repository
16+
uses: actions/checkout@v6
17+
- name: Run actionlint
18+
uses: rhysd/actionlint@v1.7.9
19+
20+
lint_check:
21+
name: Lint check
22+
uses: apify/workflows/.github/workflows/python_lint_check.yaml@main
23+
with:
24+
python-versions: '["3.10", "3.11", "3.12", "3.13", "3.14"]'
25+
26+
type_check:
27+
name: Type check
28+
uses: apify/workflows/.github/workflows/python_type_check.yaml@main
29+
with:
30+
python-versions: '["3.10", "3.11", "3.12", "3.13", "3.14"]'

.github/workflows/_check_docs.yaml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
name: Doc checks
2+
3+
on:
4+
# Runs when manually triggered from the GitHub UI.
5+
workflow_dispatch:
6+
7+
# Runs when invoked by another workflow.
8+
workflow_call:
9+
10+
jobs:
11+
doc_checks:
12+
name: Doc checks
13+
uses: apify/workflows/.github/workflows/python_docs_check.yaml@main
14+
secrets: inherit

.github/workflows/_async_docstrings_check.yaml renamed to .github/workflows/_check_docstrings.yaml

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,18 @@
1-
name: Async docstrings check
1+
name: Docstrings checks
22

33
on:
4+
# Runs when manually triggered from the GitHub UI.
5+
workflow_dispatch:
6+
7+
# Runs when invoked by another workflow.
48
workflow_call:
59

610
env:
711
PYTHON_VERSION: 3.14
812

913
jobs:
10-
async_docstring_check:
11-
name: Async docstrings check
14+
docstrings_checks:
15+
name: Docstrings checks
1216
runs-on: ubuntu-latest
1317

1418
steps:
@@ -28,5 +32,5 @@ jobs:
2832
- name: Install dependencies
2933
run: make install-dev
3034

31-
- name: Run async docstrings check
35+
- name: Async docstrings check
3236
run: make check-async-docstrings

.github/workflows/build_and_deploy_docs.yaml renamed to .github/workflows/_release_docs.yaml

Lines changed: 12 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,23 @@
1-
name: Build and deploy docs
1+
name: Doc release
22

33
on:
4-
push:
5-
branches:
6-
- master
4+
# Runs when manually triggered from the GitHub UI.
75
workflow_dispatch:
86

7+
# Runs when invoked by another workflow.
8+
workflow_call:
9+
inputs:
10+
ref:
11+
required: true
12+
type: string
13+
914
env:
1015
NODE_VERSION: 22
1116
PYTHON_VERSION: 3.14
1217

1318
jobs:
14-
doc_checks:
15-
name: Doc checks
16-
uses: ./.github/workflows/doc_checks.yaml
17-
18-
build_and_deploy_docs:
19-
needs: [doc_checks]
19+
release_docs:
20+
name: Doc release
2021
environment:
2122
name: github-pages
2223
permissions:
@@ -30,29 +31,12 @@ jobs:
3031
uses: actions/checkout@v6
3132
with:
3233
token: ${{ secrets.APIFY_SERVICE_ACCOUNT_GITHUB_TOKEN }}
34+
ref: ${{ github.event_name == 'workflow_call' && inputs.ref || github.ref }}
3335

3436
- name: Set up Node
3537
uses: actions/setup-node@v6
3638
with:
3739
node-version: ${{ env.NODE_VERSION }}
38-
cache: npm
39-
cache-dependency-path: website/package-lock.json
40-
41-
- name: Install Node dependencies
42-
run: |
43-
npm install
44-
npm update @apify/docs-theme
45-
working-directory: ./website
46-
47-
# We do this as early as possible to prevent conflicts if someone else would push something in the meantime
48-
- name: Commit the updated package.json and lockfile
49-
run: |
50-
git config user.name 'GitHub Actions'
51-
git config user.email 'github-actions[bot]@users.noreply.github.com'
52-
git add website/package.json
53-
git add website/package-lock.json
54-
git diff-index --quiet HEAD || git commit -m 'chore: Automatic docs theme update [skip ci]' || true
55-
git push
5640

5741
- name: Set up Python
5842
uses: actions/setup-python@v6
Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
1-
name: Create a pre-release
1+
name: Pre-release
22

33
on:
4-
# Trigger a beta version release (pre-release) on push to the master branch.
5-
push:
6-
branches:
7-
- master
8-
tags-ignore:
9-
- "**" # Ignore all tags to prevent duplicate builds when tags are pushed.
10-
11-
# Or it can be triggered manually.
4+
# Runs when manually triggered from the GitHub UI.
125
workflow_dispatch:
136

7+
# Runs when invoked by another workflow.
8+
workflow_call:
9+
outputs:
10+
changelog_commitish:
11+
description: The commit SHA after updating the changelog
12+
value: ${{ jobs.update_changelog.outputs.changelog_commitish }}
13+
1414
concurrency:
1515
group: release
1616
cancel-in-progress: false
@@ -32,13 +32,9 @@ jobs:
3232
release_type: prerelease
3333
existing_changelog_path: CHANGELOG.md
3434

35-
run_code_checks:
36-
name: Run code checks
37-
uses: ./.github/workflows/code_checks.yaml
38-
3935
update_changelog:
4036
name: Update changelog
41-
needs: [release_metadata, run_code_checks]
37+
needs: [release_metadata]
4238
uses: apify/workflows/.github/workflows/python_bump_and_update_changelog.yaml@main
4339
with:
4440
version_number: ${{ needs.release_metadata.outputs.version_number }}
@@ -47,8 +43,9 @@ jobs:
4743
APIFY_SERVICE_ACCOUNT_GITHUB_TOKEN: ${{ secrets.APIFY_SERVICE_ACCOUNT_GITHUB_TOKEN }}
4844

4945
publish_to_pypi:
46+
if: "!startsWith(github.event.head_commit.message, 'ci') && !startsWith(github.event.head_commit.message, 'docs')"
5047
name: Publish to PyPI
51-
needs: [release_metadata, run_code_checks, update_changelog]
48+
needs: [release_metadata, update_changelog]
5249
runs-on: ubuntu-latest
5350
permissions:
5451
contents: write
@@ -67,3 +64,6 @@ jobs:
6764
# Publishes the package to PyPI using PyPA official GitHub action with OIDC authentication.
6865
- name: Publish package to PyPI
6966
uses: pypa/gh-action-pypi-publish@release/v1
67+
68+
# TODO: add job for publish package to Conda
69+
# https://github.com/apify/crawlee-python/issues/104

.github/workflows/_tests.yaml

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
name: Tests
2+
3+
on:
4+
# Runs when manually triggered from the GitHub UI.
5+
workflow_dispatch:
6+
7+
# Runs when invoked by another workflow.
8+
workflow_call:
9+
10+
jobs:
11+
unit_tests:
12+
name: Unit tests
13+
uses: apify/workflows/.github/workflows/python_unit_tests.yaml@main
14+
secrets: inherit
15+
with:
16+
python-versions: '["3.10", "3.11", "3.12", "3.13", "3.14"]'
17+
operating-systems: '["ubuntu-latest", "windows-latest"]'
18+
python-version-for-codecov: "3.14"
19+
operating-system-for-codecov: ubuntu-latest
20+
21+
integration_tests:
22+
name: Integration tests
23+
uses: apify/workflows/.github/workflows/python_integration_tests.yaml@main
24+
secrets: inherit
25+
with:
26+
python-versions: '["3.10", "3.14"]'
27+
operating-systems: '["ubuntu-latest"]'
28+
python-version-for-codecov: "3.14"
29+
operating-system-for-codecov: ubuntu-latest

.github/workflows/check_pr_title.yaml

Lines changed: 0 additions & 14 deletions
This file was deleted.

.github/workflows/code_checks.yaml

Lines changed: 0 additions & 62 deletions
This file was deleted.

.github/workflows/doc_checks.yaml

Lines changed: 0 additions & 20 deletions
This file was deleted.

.github/workflows/release.yaml renamed to .github/workflows/manual_release_stable.yaml

Lines changed: 12 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
name: Create a release
1+
name: Stable release
22

33
on:
4-
# Trigger a stable version release via GitHub's UI, with the ability to specify the type of release.
4+
# Runs when manually triggered from the GitHub UI, with options to specify the type of release.
55
workflow_dispatch:
66
inputs:
77
release_type:
@@ -26,8 +26,13 @@ concurrency:
2626
cancel-in-progress: false
2727

2828
jobs:
29+
code_checks:
30+
name: Code checks
31+
uses: ./.github/workflows/_check_code.yaml
32+
2933
release_metadata:
3034
name: Prepare release metadata
35+
needs: [code_checks]
3136
runs-on: ubuntu-latest
3237
outputs:
3338
version_number: ${{ steps.release_metadata.outputs.version_number }}
@@ -43,25 +48,9 @@ jobs:
4348
custom_version: ${{ inputs.custom_version }}
4449
existing_changelog_path: CHANGELOG.md
4550

46-
lint_check:
47-
name: Lint check
48-
uses: apify/workflows/.github/workflows/python_lint_check.yaml@main
49-
with:
50-
python-versions: '["3.10", "3.11", "3.12", "3.13", "3.14"]'
51-
52-
type_check:
53-
name: Type check
54-
uses: apify/workflows/.github/workflows/python_type_check.yaml@main
55-
with:
56-
python-versions: '["3.10", "3.11", "3.12", "3.13", "3.14"]'
57-
58-
async_docstrings:
59-
name: Async dostrings check
60-
uses: ./.github/workflows/_async_docstrings_check.yaml
61-
6251
update_changelog:
6352
name: Update changelog
64-
needs: [release_metadata, lint_check, type_check]
53+
needs: [release_metadata]
6554
uses: apify/workflows/.github/workflows/python_bump_and_update_changelog.yaml@main
6655
with:
6756
version_number: ${{ needs.release_metadata.outputs.version_number }}
@@ -70,7 +59,7 @@ jobs:
7059
APIFY_SERVICE_ACCOUNT_GITHUB_TOKEN: ${{ secrets.APIFY_SERVICE_ACCOUNT_GITHUB_TOKEN }}
7160

7261
create_github_release:
73-
name: Create github release
62+
name: Create GitHub release
7463
needs: [release_metadata, update_changelog]
7564
runs-on: ubuntu-latest
7665
env:
@@ -105,3 +94,6 @@ jobs:
10594
# Publishes the package to PyPI using PyPA official GitHub action with OIDC authentication.
10695
- name: Publish package to PyPI
10796
uses: pypa/gh-action-pypi-publish@release/v1
97+
98+
# TODO: add job for publish package to Conda
99+
# https://github.com/apify/crawlee-python/issues/104

0 commit comments

Comments
 (0)