Skip to content

Commit 4ee13a3

Browse files
Get uv to use arm64 python out of the box (#333)
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
1 parent a4eaf27 commit 4ee13a3

7 files changed

Lines changed: 88 additions & 56 deletions

File tree

.github/workflows/autofix.yml

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,13 +10,15 @@ permissions:
1010
jobs:
1111
autofix:
1212
runs-on: ubuntu-latest
13+
env:
14+
RUFF_OUTPUT_FORMAT: github
1315
steps:
1416
- uses: actions/checkout@v4
15-
16-
- uses: astral-sh/ruff-action@v3
17+
- uses: astral-sh/setup-uv@v7
1718
with:
18-
version-file: "pyproject.toml"
19-
args: "check --fix"
19+
activate-environment: true
20+
- run: uv sync --locked --only-group=ruff
21+
- run: ruff check --fix
2022
- run: ruff format
2123
# Format even if the the previous step failed
2224
if: ${{ !cancelled() }}

.github/workflows/lint-and-build.yml

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -52,9 +52,8 @@ jobs:
5252
steps:
5353
- uses: actions/checkout@v4
5454
- name: Set up uv for Python ${{ matrix.python-version }}
55-
uses: astral-sh/setup-uv@v6
55+
uses: astral-sh/setup-uv@v7
5656
with:
57-
enable-cache: true
5857
python-version: ${{ matrix.python-version }}
5958
activate-environment: true
6059
- run: scripts/install.ps1
@@ -70,7 +69,7 @@ jobs:
7069
runs-on: ubuntu-latest
7170
steps:
7271
- uses: actions/checkout@v4
73-
- uses: astral-sh/setup-uv@v6
72+
- uses: astral-sh/setup-uv@v7
7473
- run: uvx uv-secure[faster-async]
7574

7675
Build:
@@ -83,18 +82,21 @@ jobs:
8382
python-version: ["3.13", "3.14"]
8483
steps:
8584
- uses: actions/checkout@v4
86-
# region pyinstaller/pyinstaller#9012 + astral-sh/uv#12906
87-
- name: Set up Python for PyInstaller tk and ARM64 issue
88-
if: matrix.os != 'windows-latest'
85+
# https://github.com/astral-sh/uv/issues/12906#issuecomment-3587439179
86+
- name: Set UV_PYTHON for ARM runners
87+
if: ${{ endsWith(matrix.os, 'arm') }}
88+
run: echo "UV_PYTHON=arm64" >> "$GITHUB_ENV"
89+
# region https://github.com/pyinstaller/pyinstaller/issues/9204
90+
- name: Set up Python for PyInstaller tk issue on Linux
91+
if: ${{ startsWith(matrix.os, 'ubuntu') }}
8992
uses: actions/setup-python@v5
9093
with:
9194
allow-prereleases: true
9295
python-version: ${{ matrix.python-version }}
9396
- name: Set up uv for Python ${{ matrix.python-version }}
94-
uses: astral-sh/setup-uv@v6
97+
uses: astral-sh/setup-uv@v7
9598
with:
96-
enable-cache: true
97-
python-version: ${{ matrix.os == 'windows-latest' && matrix.python-version || null }}
99+
python-version: ${{ !startsWith(matrix.os, 'ubuntu') && matrix.python-version || null }}
98100
# endregion
99101
- run: scripts/install.ps1
100102
shell: pwsh

.vscode/settings.json

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -36,11 +36,6 @@
3636
80,
3737
100,
3838
],
39-
"[git-commit]": {
40-
"editor.rulers": [
41-
72,
42-
],
43-
},
4439
"editor.detectIndentation": false,
4540
"editor.tabSize": 2,
4641
"editor.insertSpaces": true,
@@ -51,6 +46,7 @@
5146
"files.trimTrailingWhitespace": true,
5247
"editor.bracketPairColorization.enabled": true,
5348
"editor.formatOnSave": true,
49+
"editor.formatOnSaveMode": "file",
5450
"editor.codeActionsOnSave": {
5551
"source.fixAll": "explicit",
5652
// "source.*Imports": https://github.com/microsoft/TypeScript/pull/50931#issuecomment-1416288712
@@ -61,6 +57,15 @@
6157
"source.removeUnusedImports": "never",
6258
},
6359

60+
/*
61+
* Git
62+
*/
63+
"[git-commit]": {
64+
"editor.rulers": [
65+
72,
66+
],
67+
},
68+
6469
// NOTE: due to a bug in VSCode, we have to specify editor.defaultFormatter individually to ensure
6570
// it overrides user settings. Please upvote: https://github.com/microsoft/vscode/issues/168411
6671

pyproject.toml

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ name = "AutoSplit"
33
version = "2.3.2"
44
requires-python = ">=3.13"
55
dependencies = [
6-
# Dependencies:
76
"Levenshtein >=0.25",
87
"PyAutoGUI >=0.9.52",
98
"PyWinCtl >=0.0.42", # py.typed
@@ -19,7 +18,7 @@ dependencies = [
1918

2019
#
2120
# Build and compile resources
22-
"pyinstaller >=6.14.0", # Mitigate issues with pkg_resources deprecation warning
21+
"pyinstaller >=6.15.0", # Python 3.14 support
2322

2423
#
2524
# https://packaging.python.org/en/latest/specifications/dependency-specifiers/#environment-markers
@@ -44,17 +43,20 @@ dependencies = [
4443
"python-xlib >=0.33; sys_platform == 'linux'",
4544
]
4645
[dependency-groups]
46+
ruff = [
47+
"beslogic-ruff-config",
48+
"ruff", # Version should come from beslogic-ruff-config and the lock file
49+
]
4750
dev = [
4851
#
4952
# Visual Designer
5053
"qt6-applications >=6.5.0",
5154
#
5255
# Linters & Formatters
53-
"beslogic-ruff-config",
5456
"dprint-py>=0.50.0.0",
5557
"mypy[faster-cache] >=1.18",
5658
"pyright[nodejs] >=1.1.400", # reportPrivateImportUsage behaviour change
57-
"ruff", # Version should come from beslogic-ruff-config
59+
{ include-group = "ruff" },
5860
#
5961
# Types
6062
"types-PyAutoGUI",

ruff.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ extend = ".venv/Beslogic-Ruff-Config/ruff.toml"
33

44
[lint]
55
explicit-preview-rules = false # This project uses bleeding-edge behaviours
6-
ignore=[
6+
ignore = [
77
"D205", # Not all docstrings have a short description + description
88
# We have some Pascal case module names
99
"N999", # pep8-naming: Invalid module name

src/AutoSplit.py

100644100755
File mode changed.

0 commit comments

Comments
 (0)