Skip to content

Commit f55dff2

Browse files
committed
chore: Python 3.15 및 전체 의존성 버전 업그레이드
1 parent e9a664c commit f55dff2

19 files changed

Lines changed: 1432 additions & 1126 deletions

File tree

‎.github/actions/notify-slack-deploy/action.yaml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ runs:
2020
using: composite
2121
steps:
2222
- name: Notify Slack
23-
uses: slackapi/slack-github-action@v3
23+
uses: slackapi/slack-github-action@v4
2424
with:
2525
method: chat.postMessage
2626
token: ${{ inputs.slack-token }}

‎.github/workflows/lint.yaml‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,17 +16,17 @@ jobs:
1616
runs-on: ubuntu-latest
1717
steps:
1818
- name: Checkout source codes
19-
uses: actions/checkout@v4
19+
uses: actions/checkout@v7
2020

21-
- uses: actions/setup-python@v4
21+
- uses: actions/setup-python@v7
2222
with:
23-
python-version: '3.12'
23+
python-version: '3.15'
2424

2525
- name: Install dependencies
2626
run: pip install 'pre-commit'
2727

2828
- name: cache pre-commit repo
29-
uses: actions/cache@v4
29+
uses: actions/cache@v6
3030
with:
3131
path: ~/.cache/pre-commit
3232
key: ${{ runner.os }}-pre-commit-${{ hashFiles('.pre-commit-config.yaml') }}

‎.github/workflows/release-server.yaml‎

Lines changed: 17 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -29,24 +29,31 @@ jobs:
2929

3030
steps:
3131
- name: Checkout source codes
32-
uses: actions/checkout@v4
32+
uses: actions/checkout@v7
3333
with:
3434
fetch-depth: 0
3535

3636
- name: Install uv
37-
uses: astral-sh/setup-uv@v5
37+
uses: astral-sh/setup-uv@v10.4.1
3838
with:
3939
enable-cache: true
4040
ignore-nothing-to-cache: true
41+
# v6~v10 에서 바뀐 기본값을 기존 동작으로 고정.
42+
prune-cache: true
43+
cache-dependency-glob: |
44+
**/uv.lock
45+
**/requirements*.txt
46+
add-problem-matchers: false
47+
download-from-astral-mirror: false
4148

4249
- name: Install dependencies
4350
run: uv sync --only-group=deployment
4451

4552
- name: Set up Docker Buildx
46-
uses: docker/setup-buildx-action@v3
53+
uses: docker/setup-buildx-action@v4
4754

4855
- name: Login to Docker Hub
49-
uses: docker/login-action@v3
56+
uses: docker/login-action@v4
5057
with:
5158
username: ${{ secrets.DOCKERHUB_USERNAME }}
5259
password: ${{ secrets.DOCKERHUB_TOKEN }}
@@ -59,7 +66,12 @@ jobs:
5966
echo "repository_name=$(echo ${{ github.repository }} | sed -e 's/${{ github.repository_owner }}\///')" >> "$GITHUB_OUTPUT"
6067
6168
- name: Build and Push Docker image to Docker Hub
62-
uses: docker/build-push-action@v5
69+
uses: docker/build-push-action@v7
70+
# v6 부터 기본으로 켜진 빌드 요약·기록 아티팩트·체크 주석을 기존처럼 끔.
71+
env:
72+
DOCKER_BUILD_SUMMARY: false
73+
DOCKER_BUILD_RECORD_UPLOAD: false
74+
DOCKER_BUILD_CHECKS_ANNOTATIONS: false
6375
with:
6476
push: true
6577
tags: |

‎.github/workflows/test.yaml‎

Lines changed: 18 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -44,12 +44,19 @@ jobs:
4444
ENV_PATH: ../envfile/.env.local
4545

4646
steps:
47-
- uses: actions/checkout@v4
47+
- uses: actions/checkout@v7
4848

49-
- uses: astral-sh/setup-uv@v5
49+
- uses: astral-sh/setup-uv@v10.4.1
5050
with:
5151
enable-cache: true
5252
ignore-nothing-to-cache: true
53+
# v6~v10 에서 바뀐 기본값을 기존 동작으로 고정.
54+
prune-cache: true
55+
cache-dependency-glob: |
56+
**/uv.lock
57+
**/requirements*.txt
58+
add-problem-matchers: false
59+
download-from-astral-mirror: false
5360

5461
- name: Install dependencies
5562
run: uv sync
@@ -88,12 +95,19 @@ jobs:
8895
--health-retries 10
8996
9097
steps:
91-
- uses: actions/checkout@v4
98+
- uses: actions/checkout@v7
9299

93-
- uses: astral-sh/setup-uv@v5
100+
- uses: astral-sh/setup-uv@v10.4.1
94101
with:
95102
enable-cache: true
96103
ignore-nothing-to-cache: true
104+
# v6~v10 에서 바뀐 기본값을 기존 동작으로 고정.
105+
prune-cache: true
106+
cache-dependency-glob: |
107+
**/uv.lock
108+
**/requirements*.txt
109+
add-problem-matchers: false
110+
download-from-astral-mirror: false
97111

98112
- name: Install dependencies
99113
run: uv sync

‎.pre-commit-config.yaml‎

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
# See https://pre-commit.com for more information
22
# See https://pre-commit.com/hooks.html for more hooks
33
default_language_version:
4-
python: python3.12
4+
python: python3.15
55
default_stages: [pre-commit, pre-push]
66
repos:
77
- repo: https://github.com/pre-commit/pre-commit-hooks
8-
rev: v5.0.0
8+
rev: v6.0.0
99
hooks:
1010
- id: check-toml
1111
- id: check-xml
@@ -24,7 +24,7 @@ repos:
2424
- javascript
2525
- markdown
2626
- repo: https://github.com/PyCQA/flake8
27-
rev: 7.2.0
27+
rev: 7.5.0
2828
hooks:
2929
- id: flake8
3030
additional_dependencies:
@@ -34,21 +34,23 @@ repos:
3434
- --max-line-length=120
3535
- --max-complexity=18
3636
- repo: https://github.com/psf/black
37-
rev: 25.1.0
37+
rev: 26.10.1
3838
hooks:
3939
- id: black
40-
language_version: python3.12
40+
language_version: python3.15
4141
args:
4242
- --line-length=120
4343
- repo: https://github.com/PyCQA/bandit
44-
rev: "1.8.3"
44+
rev: "1.9.4"
4545
hooks:
4646
- id: bandit
47+
# bandit 1.9 의 B105 가 테스트 픽스처 토큰 문자열을 대량 오탐 — 테스트는 검사 제외.
48+
exclude: (^|/)(test|tests)/|(^|/)conftest\.py$|_test\.py$
4749
args:
4850
- -c
4951
- bandit.yaml
5052
- repo: https://github.com/PyCQA/isort
51-
rev: "6.0.1"
53+
rev: "9.0.2"
5254
hooks:
5355
- id: isort
5456
# TODO: https://github.com/dosisod/refurb/issues/372 문제 해소 후 uncomment 필요
@@ -69,13 +71,13 @@ repos:
6971
# - drf-standardized-errors
7072
# - djangorestframework-stubs[compatible-mypy]
7173
- repo: https://github.com/astral-sh/uv-pre-commit
72-
rev: 0.6.12
74+
rev: 0.13.12
7375
hooks:
7476
- id: uv-lock
7577
- repo: https://github.com/astral-sh/ruff-pre-commit
76-
rev: v0.11.4
78+
rev: v0.17.6
7779
hooks:
78-
- id: ruff
80+
- id: ruff-check
7981
args:
8082
- --fix
8183
- id: ruff-format

‎app/admin_api/test/shop/orders_api_test.py‎

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -480,6 +480,7 @@ def test_admin_export_returns_xlsx_filtering_refunded_per_include_flag(
480480

481481
df_dict = pandas.read_excel(
482482
BytesIO(b"".join(response.streaming_content)),
483+
engine="openpyxl",
483484
sheet_name=None,
484485
# index_col=0 → write 시 추가된 pandas index 컬럼 제거. na_filter=False → 빈 셀을 NaN 대신 "" 로
485486
# 읽어 None vs NaN 비교 문제 회피. dtype 강제 → leading-zero 가진 string 이 int 로 추론되는 것 방지.
@@ -528,7 +529,9 @@ def test_admin_export_returns_xlsx_filtering_refunded_per_include_flag(
528529

529530
def _export_order_ids(response) -> set[str]:
530531
"""export XLSX 응답의 '주문' 시트에서 주문 번호 집합을 추출."""
531-
df = pandas.read_excel(BytesIO(b"".join(response.streaming_content)), sheet_name="주문", index_col=0, dtype=str)
532+
df = pandas.read_excel(
533+
BytesIO(b"".join(response.streaming_content)), engine="openpyxl", sheet_name="주문", index_col=0, dtype=str
534+
)
532535
return set(df["주문 번호"].tolist()) if not df.empty else set()
533536

534537

‎app/admin_api/test/shop/soft_delete_filtering_test.py‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,7 @@ def test_admin_export_excludes_soft_deleted_opr_from_product_sheet(api_client, o
4949
assert response.status_code == HTTP_200_OK
5050
df_dict = pandas.read_excel(
5151
BytesIO(b"".join(response.streaming_content)),
52+
engine="openpyxl",
5253
sheet_name="주문상품",
5354
index_col=0,
5455
na_filter=False,
@@ -106,6 +107,7 @@ def test_admin_export_excludes_order_with_only_soft_deleted_matching_opr(
106107
assert response.status_code == HTTP_200_OK
107108
df_dict = pandas.read_excel(
108109
BytesIO(b"".join(response.streaming_content)),
110+
engine="openpyxl",
109111
sheet_name=None,
110112
index_col=0,
111113
na_filter=False,

‎app/admin_api/views/shop/orders.py‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -219,7 +219,7 @@ def import_csv(self, request: request.Request) -> response.Response:
219219
if not (csv_file := request.FILES.get("csv_file")):
220220
raise exceptions.ValidationError({"csv_file": "이 값이 필요합니다."})
221221

222-
csv_df = read_uploaded_csv(csv_file.read()).fillna("")
222+
csv_df = read_uploaded_csv(csv_file.read()).astype(object).fillna("")
223223
csv_serializers = [
224224
imports.OrderProductImportSerializer(data=datum) for datum in csv_df.to_dict(orient="index").values()
225225
]

‎app/core/fields.py‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,8 +60,10 @@ def _check_max_length_warning(self) -> list[str]:
6060
return []
6161

6262
def get_prep_value(self, value: typing.Any) -> uuid.UUID | None:
63-
if value in (None, "") or isinstance(value, uuid.UUID):
63+
if value in (None, ""):
6464
return None
65+
if isinstance(value, uuid.UUID):
66+
return value
6567
if isinstance(value, str):
6668
return uuid.UUID(value)
6769
if isinstance(value, bytes):

‎app/core/gunicorn_conf.py‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@
77
timeout = int(os.environ.get("GUNICORN_TIMEOUT", "30"))
88
max_requests = int(os.environ.get("GUNICORN_MAX_REQUESTS", "1000"))
99
max_requests_jitter = int(os.environ.get("GUNICORN_MAX_REQUESTS_JITTER", "100"))
10+
# gunicorn 27 부터 기본으로 $HOME 에 control 소켓을 만드는데, nobody 는 홈이 없어 에러 로그만 남는다.
11+
control_socket_disable = True
1012

1113

1214
def post_fork(server, worker):

0 commit comments

Comments
 (0)