From 76019c7fd7cb3fdc7b20125d1c65e41dff768bdc Mon Sep 17 00:00:00 2001 From: Shu Shen Date: Wed, 1 Nov 2023 20:32:05 -0400 Subject: [PATCH 1/4] fix: force int type for random.randint() Automatic conversion of non-integer types is no longer supported in Python 3.12. See https://docs.python.org/3/library/random.html. --- pyqldb/util/retry.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyqldb/util/retry.py b/pyqldb/util/retry.py index 9ce35b1..4c6f0fa 100644 --- a/pyqldb/util/retry.py +++ b/pyqldb/util/retry.py @@ -37,6 +37,6 @@ def calculate_backoff(retry_config, retry_attempt, error, transaction_id): def _get_delay_with_equal_jitter(retry_attempt, retry_config): capped_retries = min(retry_attempt, MAX_POW) delay_seed = min(retry_config.base * (1 << capped_retries), MAX_BACKOFF) - delay = delay_seed / 2 + random.randint(0, delay_seed / 2) + delay = delay_seed / 2 + random.randint(0, int(delay_seed / 2)) return delay From f8c969a7729c1956075bda145451c5dc6669a9bd Mon Sep 17 00:00:00 2001 From: Shu Shen Date: Wed, 1 Nov 2023 21:28:07 -0400 Subject: [PATCH 2/4] chore: bump github action aws-actions/configure-aws-credentials@v4 --- .github/workflows/pythonapp.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/pythonapp.yml b/.github/workflows/pythonapp.yml index 7d418d1..56a1e16 100644 --- a/.github/workflows/pythonapp.yml +++ b/.github/workflows/pythonapp.yml @@ -29,7 +29,7 @@ jobs: with: python-version: ${{ matrix.python-version }} - name: Configure AWS Credentials - uses: aws-actions/configure-aws-credentials@v1 + uses: aws-actions/configure-aws-credentials@v4 with: aws-region: us-east-2 role-to-assume: arn:aws:iam::264319671630:role/GitHubActionsOidc From 8c253f00703f89cf244875be4a7b0104d4a77501 Mon Sep 17 00:00:00 2001 From: Shu Shen Date: Thu, 2 Nov 2023 14:26:01 -0400 Subject: [PATCH 3/4] chore: bump Github actions for CodeQL --- .github/workflows/codeql-analysis.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/codeql-analysis.yml b/.github/workflows/codeql-analysis.yml index 8a744f0..be658dd 100644 --- a/.github/workflows/codeql-analysis.yml +++ b/.github/workflows/codeql-analysis.yml @@ -43,7 +43,7 @@ jobs: # Initializes the CodeQL tools for scanning. - name: Initialize CodeQL - uses: github/codeql-action/init@v1 + uses: github/codeql-action/init@v2 with: languages: ${{ matrix.language }} # If you wish to specify custom queries, you can do so here or in a config file. @@ -54,7 +54,7 @@ jobs: # Autobuild attempts to build any compiled languages (C/C++, C#, or Java). # If this step fails, then you should remove it and run the build manually (see below) - name: Autobuild - uses: github/codeql-action/autobuild@v1 + uses: github/codeql-action/autobuild@v2 # â„šī¸ Command-line programs to run using the OS shell. # 📚 https://git.io/JvXDl @@ -68,4 +68,4 @@ jobs: # make release - name: Perform CodeQL Analysis - uses: github/codeql-action/analyze@v1 + uses: github/codeql-action/analyze@v2 From c896ab2e4a0f7e1e8e31b32a886073c92e7e2585 Mon Sep 17 00:00:00 2001 From: Shu Shen Date: Wed, 1 Nov 2023 19:38:08 -0400 Subject: [PATCH 4/4] chore: remove EoL Python 3.7 from test matrix --- .github/workflows/pythonapp.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/pythonapp.yml b/.github/workflows/pythonapp.yml index 56a1e16..914de85 100644 --- a/.github/workflows/pythonapp.yml +++ b/.github/workflows/pythonapp.yml @@ -17,11 +17,11 @@ jobs: build: runs-on: ${{ matrix.os }} - strategy: + strategy: max-parallel: 6 - matrix : + matrix : os: [ubuntu-latest, windows-latest, macos-latest] - python-version: ['3.7', '3.8', '3.9', '3.10'] + python-version: ['3.8', '3.9', '3.10'] steps: - uses: actions/checkout@v3 - name: Set up Python ${{ matrix.python-version }}