Skip to content

Fix Qwen3 crash

Fix Qwen3 crash #467

Workflow file for this run

# Copyright 2023–2025 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
name: CodeQuality
on:
pull_request:
concurrency:
# Dedup pull requests (canceling previous runs of the same workflow for same PR), and scheduled runs but nothing else
group: >
${{
github.event_name == 'pull_request' && format('{0}-pr-{1}', github.workflow, github.event.pull_request.number) ||
github.event_name == 'schedule' && format('{0}-schedule', github.workflow) ||
github.run_id
}}
cancel-in-progress: true
jobs:
qa:
name: "Static code-quality checkers"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v5
- name: Install uv and set the Python version
uses: astral-sh/setup-uv@v7
with:
python-version: '3.12'
enable-cache: true
- name: Set venv
run: uv venv --python 3.12 "$GITHUB_WORKSPACE"/venv
- name: Install `pre-commit`
run: . "$GITHUB_WORKSPACE"/venv/bin/activate && uv pip install pre-commit
- name: Cache pre-commit environments
uses: actions/cache@v4
with:
path: ~/.cache/pre-commit
key: pre-commit-${{ hashFiles('.pre-commit-config.yaml') }}
- name: Run pre-commit checks on just the files that have changed
run: |
git fetch origin "$GITHUB_BASE_REF":"$GITHUB_BASE_REF"
git branch "$GITHUB_HEAD_REF"
. "$GITHUB_WORKSPACE"/venv/bin/activate
pre-commit run --from-ref "$GITHUB_BASE_REF" --to-ref "$GITHUB_HEAD_REF"