Skip to content

Commit

Permalink
Merge branch 'main' into feature/multipart
Browse files Browse the repository at this point in the history
  • Loading branch information
patrick91 committed Aug 29, 2024
2 parents 4f5f1c4 + cafc388 commit 600c5e2
Show file tree
Hide file tree
Showing 484 changed files with 15,887 additions and 7,999 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/federation-compatibility.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,20 +28,20 @@ jobs:
- uses: actions/setup-python@v4
id: setup-python
with:
python-version: "3.10"
python-version: "3.12"
cache: "poetry"
- run: poetry env use python3.10
- run: poetry env use python3.12
- run: poetry install

- name: export schema
run: poetry run strawberry export-schema schema:schema > schema.graphql
working-directory: federation-compatibility

- uses: apollographql/federation-subgraph-compatibility@v1
- uses: apollographql/federation-subgraph-compatibility@v2
with:
compose: 'federation-compatibility/docker-compose.yml'
schema: 'federation-compatibility/schema.graphql'
port: 4001
token: ${{ secrets.BOT_TOKEN }}
failOnWarning: true
failOnWarning: false
failOnRequired: true
30 changes: 30 additions & 0 deletions .github/workflows/issue-manager.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: Issue Manager

on:
schedule:
- cron: "0 0 * * *"
issue_comment:
types:
- created
issues:
types:
- labeled
pull_request_target:
types:
- labeled
workflow_dispatch:

jobs:
issue-manager:
runs-on: ubuntu-latest
steps:
- uses: tiangolo/issue-manager@0.5.0
with:
token: ${{ secrets.GITHUB_TOKEN }}
config: >
{
"info-needed": {
"delay": "P14D",
"message": "Hi, this issue requires extra info to be actionable. We're closing this issue because it has not been actionable for a while now. Feel free to provide the requested information and we'll happily open it again! 😊"
}
}
2 changes: 1 addition & 1 deletion .github/workflows/ok-to-preview.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ jobs:
event_data = json.load(f)
links = [
"https://beta.strawberry.rocks/docs/pr/{pr_number}/{path}".format(
"https://strawberry.rocks/docs/pr/{pr_number}/{path}".format(
pr_number=event_data["number"],
path=file.replace(".md", "").replace("docs/", "")
)
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/release-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ jobs:
ref: "refs/pull/${{ github.event.number }}/merge"
- name: Extract tweet message and changelog
id: extract
uses: strawberry-graphql/tweet-actions/read-tweet@v5
uses: strawberry-graphql/tweet-actions/read-tweet@v6
with:
changelog: ${{ needs.release-file-check.outputs.changelog }}
version: "(next)"
Expand All @@ -102,7 +102,7 @@ jobs:
if: ${{ needs.read-tweet-md.outputs.tweet != '' }}
steps:
- name: Validate tweet
uses: strawberry-graphql/tweet-actions/validate-tweet@v5
uses: strawberry-graphql/tweet-actions/validate-tweet@v6
with:
tweet: ${{ needs.read-tweet-md.outputs.tweet }}

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ jobs:
- uses: actions/checkout@v1
- name: Extract tweet message and changelog
id: extract
uses: strawberry-graphql/tweet-actions/read-tweet@v5
uses: strawberry-graphql/tweet-actions/read-tweet@v6
with:
changelog: ${{ needs.release-file-check.outputs.changelog }}
version: ${{ needs.release.outputs.version }}
Expand Down
80 changes: 46 additions & 34 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,8 @@ jobs:
outputs:
sessions: ${{ steps.set-matrix.outputs.sessions }}
steps:
- uses: actions/checkout@v3
- uses: wntrblm/nox@main
- run: pipx install poetry
- run: pipx inject nox nox-poetry
- uses: actions/checkout@v4
- run: pip install poetry nox nox-poetry
- id: set-matrix
shell: bash
run: |
Expand All @@ -50,36 +48,44 @@ jobs:
session: ${{ fromJson(needs.generate-jobs-tests.outputs.sessions) }}

steps:
- uses: actions/checkout@v3
- uses: wntrblm/nox@main
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-versions: "3.8, 3.9, 3.10, 3.11, 3.12"
python-version: |
3.8
3.9
3.10
3.11
3.12
- name: Pip and nox cache
id: cache
uses: actions/cache@v3
uses: actions/cache@v4
with:
path: |
~/.cache
~/.nox
.nox
key: ${{ runner.os }}-nox-${{ matrix.session.session }}-${{
hashFiles('**/poetry.lock') }}-${{ hashFiles('**/noxfile.py') }}
restore-keys: |
${{ runner.os }}-nox-${{ matrix.session.session }}-
${{ runner.os }}-nox-
key:
${{ runner.os }}-nox-${{ matrix.session.session }}-${{
hashFiles('**/poetry.lock') }}-${{ hashFiles('**/noxfile.py') }}-4

- run: pipx install coverage
- run: pipx install poetry
- run: pipx inject nox nox-poetry
- run: pip install poetry nox nox-poetry
- run: nox -r -t tests -s "${{ matrix.session.session }}"

- name: coverage xml
run: coverage xml -i
- uses: actions/upload-artifact@v4
if: ${{ always() }}
with:
name: coverage-${{ matrix.session.session }}
path: coverage.xml

- uses: codecov/codecov-action@v3
if: ${{ always() }}
upload-coverage:
name: 🆙 Upload Coverage
needs: [unit-tests]
runs-on: ubuntu-latest

steps:
- uses: actions/download-artifact@v4
- uses: codecov/codecov-action@v4
with:
token: ${{ secrets.CODECOV_TOKEN }}
fail_ci_if_error: true
Expand All @@ -92,9 +98,9 @@ jobs:
fail-fast: false

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- run: pipx install poetry
- uses: actions/setup-python@v4
- uses: actions/setup-python@v5
id: setup-python
with:
python-version: "3.12"
Expand All @@ -106,7 +112,7 @@ jobs:
if: steps.setup-python.outputs.cache-hit != 'true'

- name: Run benchmarks
uses: CodSpeedHQ/action@v1
uses: CodSpeedHQ/action@v2
with:
token: ${{ secrets.CODSPEED_TOKEN }}
run: poetry run pytest tests/benchmarks --codspeed
Expand All @@ -118,38 +124,44 @@ jobs:
fail-fast: false

steps:
- uses: actions/checkout@v3
- uses: wntrblm/nox@main
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-versions: "3.8, 3.9, 3.10, 3.11, 3.12"
python-version: |
3.8
3.9
3.10
3.11
3.12
- name: Pip and nox cache
id: cache
uses: actions/cache@v3
uses: actions/cache@v4
with:
path: |
~/.cache
~/.nox
.nox
key: ${{ runner.os }}-nox-lint-${{ matrix.session.session }}-${{
key:
${{ runner.os }}-nox-lint-${{ matrix.session.session }}-${{
hashFiles('**/poetry.lock') }}-${{ hashFiles('**/noxfile.py') }}
restore-keys: |
${{ runner.os }}-lint-nox-${{ matrix.session.session }}-
${{ runner.os }}-lint-nox-
- run: pipx install poetry
- run: pipx inject nox nox-poetry
- run: pip install poetry
- run: pip install nox nox-poetry
- run: nox -r -t lint

unit-tests-on-windows:
name: 🪟 Tests on Windows
runs-on: windows-latest

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- run: pipx install poetry
- run: pipx install coverage
- uses: actions/setup-python@v4
- uses: actions/setup-python@v5
id: setup-python
with:
python-version: "3.11"
Expand All @@ -170,7 +182,7 @@ jobs:
run: coverage xml -i
if: ${{ always() }}

- uses: codecov/codecov-action@v3
- uses: codecov/codecov-action@v4
if: ${{ always() }}
with:
token: ${{ secrets.CODECOV_TOKEN }}
Expand Down
3 changes: 0 additions & 3 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
.DS_Store


# Created by https://www.gitignore.io/api/macos,linux,python,windows
# Edit at https://www.gitignore.io/?templates=macos,linux,python,windows

Expand Down
5 changes: 3 additions & 2 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
repos:
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.2.1
rev: v0.4.10
hooks:
- id: ruff-format
exclude: ^tests/\w+/snapshots/
Expand All @@ -20,7 +20,7 @@ repos:
files: '^docs/.*\.mdx?$'

- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.5.0
rev: v4.6.0
hooks:
- id: trailing-whitespace
- id: check-merge-conflict
Expand All @@ -35,3 +35,4 @@ repos:
hooks:
- id: blacken-docs
args: [--skip-errors]
files: '\.(rst|md|markdown|py|mdx)$'
Loading

0 comments on commit 600c5e2

Please sign in to comment.