From ec40b44653f6b0bd3b1ebb0f6606bcd5acd5ea58 Mon Sep 17 00:00:00 2001 From: Jie Liu Date: Mon, 7 Jul 2025 16:04:07 +0800 Subject: [PATCH 1/2] chore(githubActions): upgrade ubuntu os version --- .github/workflows/ci-test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci-test.yml b/.github/workflows/ci-test.yml index 5219587..7fd89df 100644 --- a/.github/workflows/ci-test.yml +++ b/.github/workflows/ci-test.yml @@ -7,7 +7,7 @@ jobs: max-parallel: 1 matrix: python_version: ['2.7', '3.4', '3.5', '3.6', '3.7', '3.8', '3.9'] - runs-on: ubuntu-20.04 + runs-on: ubuntu-22.04 steps: - name: Checkout repo uses: actions/checkout@v2 From 4edd698ef107335e14d7c34c15491300683852bc Mon Sep 17 00:00:00 2001 From: Jie Liu Date: Mon, 7 Jul 2025 17:36:18 +0800 Subject: [PATCH 2/2] refactor: fix the flake8 error F824 --- qiniu/http/regions_provider.py | 2 -- 1 file changed, 2 deletions(-) diff --git a/qiniu/http/regions_provider.py b/qiniu/http/regions_provider.py index c451d16..a8bcf88 100644 --- a/qiniu/http/regions_provider.py +++ b/qiniu/http/regions_provider.py @@ -161,7 +161,6 @@ def __init__(self, fd): def __enter__(self): with _file_threading_lockers_lock: - global _file_threading_lockers threading_lock = _file_threading_lockers.get(self._file_path, threading.Lock()) # Could use keyword style `acquire(blocking=False)` when min version of python update to >= 3 if not threading_lock.acquire(False): @@ -170,7 +169,6 @@ def __enter__(self): def __exit__(self, exc_type, exc_val, exc_tb): with _file_threading_lockers_lock: - global _file_threading_lockers threading_lock = _file_threading_lockers.get(self._file_path) if threading_lock and threading_lock.locked(): threading_lock.release()