From 079e500f0edc77fb5fb88522163be4c9a4ea98db Mon Sep 17 00:00:00 2001 From: jimmy-sketch Date: Sat, 8 Nov 2025 16:13:51 +0800 Subject: [PATCH 1/2] =?UTF-8?q?chore(ci):=20=E6=9B=B4=E6=96=B0=20GitHub=20?= =?UTF-8?q?Actions=20=E5=B7=A5=E4=BD=9C=E6=B5=81=E4=B8=AD=E7=9A=84?= =?UTF-8?q?=E5=91=BD=E4=BB=A4=E6=89=A7=E8=A1=8C=E6=96=B9=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/pre-commit.yml | 2 +- .github/workflows/ruff.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/pre-commit.yml b/.github/workflows/pre-commit.yml index 46b08a62..0828dfc3 100644 --- a/.github/workflows/pre-commit.yml +++ b/.github/workflows/pre-commit.yml @@ -26,4 +26,4 @@ jobs: run: uv pip install pre-commit - name: Run pre-commit on all files - run: pre-commit run --all-files + run: uv run pre-commit run --all-files diff --git a/.github/workflows/ruff.yml b/.github/workflows/ruff.yml index ca35a84a..d1ba7c52 100644 --- a/.github/workflows/ruff.yml +++ b/.github/workflows/ruff.yml @@ -25,4 +25,4 @@ jobs: run: uv pip install ruff - name: Run Ruff - run: ruff check --output-format=github . + run: uv run ruff check --output-format=github . From c63f7de1175d2707ef87204c5fe35740bef304ce Mon Sep 17 00:00:00 2001 From: jimmy-sketch Date: Sat, 8 Nov 2025 16:18:50 +0800 Subject: [PATCH 2/2] =?UTF-8?q?chore(workflows):=20=E6=A0=BC=E5=BC=8F?= =?UTF-8?q?=E5=8C=96=20GitHub=20=E5=B7=A5=E4=BD=9C=E6=B5=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/codeQL.yml | 42 +++++++++---------- .github/workflows/pre-commit.yml | 40 +++++++++--------- .github/workflows/ruff.yml | 38 ++++++++--------- app/page_building/another_window.py | 1 + .../custom_draw_settings.py | 1 + 5 files changed, 62 insertions(+), 60 deletions(-) diff --git a/.github/workflows/codeQL.yml b/.github/workflows/codeQL.yml index a3c477da..3ca36e67 100644 --- a/.github/workflows/codeQL.yml +++ b/.github/workflows/codeQL.yml @@ -1,30 +1,30 @@ name: CodeQL on: - push: - branches: [master] - pull_request: + push: + branches: [master] + pull_request: jobs: - analyze: - name: CodeQL Analysis - runs-on: ubuntu-latest - permissions: - actions: read - contents: read - security-events: write + analyze: + name: CodeQL Analysis + runs-on: ubuntu-latest + permissions: + actions: read + contents: read + security-events: write - steps: - - name: Checkout repository - uses: actions/checkout@v4 + steps: + - name: Checkout repository + uses: actions/checkout@v4 - - name: Initialize CodeQL - uses: github/codeql-action/init@v3 - with: - languages: python + - name: Initialize CodeQL + uses: github/codeql-action/init@v3 + with: + languages: python - - name: Autobuild (optional for Python) - uses: github/codeql-action/autobuild@v3 + - name: Autobuild (optional for Python) + uses: github/codeql-action/autobuild@v3 - - name: Perform CodeQL Analysis - uses: github/codeql-action/analyze@v3 + - name: Perform CodeQL Analysis + uses: github/codeql-action/analyze@v3 diff --git a/.github/workflows/pre-commit.yml b/.github/workflows/pre-commit.yml index 0828dfc3..24dec0c3 100644 --- a/.github/workflows/pre-commit.yml +++ b/.github/workflows/pre-commit.yml @@ -1,29 +1,29 @@ name: Pre-commit on: - push: - branches: [master] - pull_request: - workflow_dispatch: + push: + branches: [master] + pull_request: + workflow_dispatch: jobs: - pre-commit: - runs-on: ubuntu-22.04 - steps: - - uses: actions/checkout@v4 + pre-commit: + runs-on: ubuntu-22.04 + steps: + - uses: actions/checkout@v4 - - name: Setup uv - uses: astral-sh/setup-uv@v4 - with: - enable-cache: true + - name: Setup uv + uses: astral-sh/setup-uv@v4 + with: + enable-cache: true - - name: Install Python 3.8.10 - run: uv python install 3.8.10 + - name: Install Python 3.8.10 + run: uv python install 3.8.10 - - name: set uv venv - run: uv venv - - name: Install pre-commit with uv - run: uv pip install pre-commit + - name: set uv venv + run: uv venv + - name: Install pre-commit with uv + run: uv pip install pre-commit - - name: Run pre-commit on all files - run: uv run pre-commit run --all-files + - name: Run pre-commit on all files + run: uv run pre-commit run --all-files diff --git a/.github/workflows/ruff.yml b/.github/workflows/ruff.yml index d1ba7c52..756f5f39 100644 --- a/.github/workflows/ruff.yml +++ b/.github/workflows/ruff.yml @@ -1,28 +1,28 @@ name: Ruff on: - push: - branches: [master] - pull_request: + push: + branches: [master] + pull_request: jobs: - ruff: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 + ruff: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 - - name: Setup uv - uses: astral-sh/setup-uv@v3 - with: - enable-cache: true + - name: Setup uv + uses: astral-sh/setup-uv@v3 + with: + enable-cache: true - - name: Setup Python - run: uv python install 3.8.10 + - name: Setup Python + run: uv python install 3.8.10 - - name: Set up venv - run: uv venv - - name: Install Ruff via uv - run: uv pip install ruff + - name: Set up venv + run: uv venv + - name: Install Ruff via uv + run: uv pip install ruff - - name: Run Ruff - run: uv run ruff check --output-format=github . + - name: Run Ruff + run: uv run ruff check --output-format=github . diff --git a/app/page_building/another_window.py b/app/page_building/another_window.py index 42f9c0f2..c6a800de 100644 --- a/app/page_building/another_window.py +++ b/app/page_building/another_window.py @@ -41,6 +41,7 @@ class contributor_window_template(PageTemplate): """贡献者窗口类 使用PageTemplate创建贡献者页面""" + def __init__(self, parent=None): super().__init__(content_widget_class=contributor_page, parent=parent) diff --git a/app/view/settings/extraction_settings/custom_draw_settings.py b/app/view/settings/extraction_settings/custom_draw_settings.py index 9585b4d4..cdd34d13 100644 --- a/app/view/settings/extraction_settings/custom_draw_settings.py +++ b/app/view/settings/extraction_settings/custom_draw_settings.py @@ -14,6 +14,7 @@ from app.tools.settings_access import * from app.Language.obtain_language import * + # ================================================== # 自定义抽设置 # ==================================================