From 59cb8109ba6b22667aa3f8b58bcdd32d6108c74e Mon Sep 17 00:00:00 2001 From: impervius <63152795+impervius@users.noreply.github.com> Date: Fri, 6 Feb 2026 17:17:50 +0200 Subject: [PATCH 1/5] Don't use strict == versions for dependencies, and update tooling in CI --- .github/workflows/mypy.yml | 11 ++++------- .github/workflows/pylint.yml | 11 ++++------- .github/workflows/pypi-publish.yml | 18 +++++++----------- .github/workflows/unittests.yml | 10 ++++------ .pre-commit-config.yaml | 6 +++--- pyproject.toml | 11 ++++------- setup.py | 19 ------------------- 7 files changed, 26 insertions(+), 60 deletions(-) delete mode 100644 setup.py diff --git a/.github/workflows/mypy.yml b/.github/workflows/mypy.yml index ad88de4..7e31aab 100644 --- a/.github/workflows/mypy.yml +++ b/.github/workflows/mypy.yml @@ -11,17 +11,14 @@ jobs: matrix: python-version: ["3.9", "3.10", "3.11", "3.12", "3.13", "3.14"] steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v6 - name: Set up Python ${{ matrix.python-version }} - uses: actions/setup-python@v3 + uses: astral-sh/setup-uv@v7 with: python-version: ${{ matrix.python-version }} - name: Install dependencies run: | - python -m pip install --upgrade pip - pip install python-snappy - pip install zstd - pip install mypy + uv sync - name: Analysing the code with mypy run: | - mypy dfindexeddb + uv run --with mypy mypy dfindexeddb diff --git a/.github/workflows/pylint.yml b/.github/workflows/pylint.yml index 93b7838..8cc6893 100644 --- a/.github/workflows/pylint.yml +++ b/.github/workflows/pylint.yml @@ -11,17 +11,14 @@ jobs: matrix: python-version: ["3.9", "3.10", "3.11", "3.12", "3.13", "3.14"] steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v6 - name: Set up Python ${{ matrix.python-version }} - uses: actions/setup-python@v3 + uses: astral-sh/setup-uv@v7 with: python-version: ${{ matrix.python-version }} - name: Install dependencies run: | - python -m pip install --upgrade pip - pip install python-snappy - pip install zstd - pip install pylint + uv sync - name: Analysing the code with pylint run: | - pylint --rc-file=.pylintrc dfindexeddb tests + uv run --with pylint pylint --rc-file=.pylintrc dfindexeddb tests diff --git a/.github/workflows/pypi-publish.yml b/.github/workflows/pypi-publish.yml index b68bfee..a2aa734 100644 --- a/.github/workflows/pypi-publish.yml +++ b/.github/workflows/pypi-publish.yml @@ -8,19 +8,15 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v6 - name: Set up Python - uses: actions/setup-python@v4 + uses: astral-sh/setup-uv@v7 with: python-version: "3.x" - - name: Install dependencies - run: | - python -m pip install --upgrade pip - pip install build - name: Build package - run: python -m build + run: uv build - name: Store the distribution packages - uses: actions/upload-artifact@v4 + uses: actions/upload-artifact@v6 with: name: python-package-distributions path: dist/ @@ -41,7 +37,7 @@ jobs: steps: - name: Download all the dists - uses: actions/download-artifact@v4.1.7 + uses: actions/download-artifact@v7 with: name: python-package-distributions path: dist/ @@ -60,12 +56,12 @@ jobs: steps: - name: Download all the dists - uses: actions/download-artifact@v4.1.7 + uses: actions/download-artifact@v7 with: name: python-package-distributions path: dist/ - name: Sign the dists with Sigstore - uses: sigstore/gh-action-sigstore-python@v3.0.0 + uses: sigstore/gh-action-sigstore-python@v3.2.0 with: inputs: >- ./dist/*.tar.gz diff --git a/.github/workflows/unittests.yml b/.github/workflows/unittests.yml index b9bbc72..91f6bdf 100644 --- a/.github/workflows/unittests.yml +++ b/.github/workflows/unittests.yml @@ -11,16 +11,14 @@ jobs: matrix: python-version: ["3.9", "3.10", "3.11", "3.12", "3.13", "3.14"] steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v6 - name: Set up Python ${{ matrix.python-version }} - uses: actions/setup-python@v3 + uses: astral-sh/setup-uv@v7 with: python-version: ${{ matrix.python-version }} - name: Install dependencies run: | - python -m pip install --upgrade pip - pip install python-snappy - pip install zstd + uv sync - name: Run unittests run: | - python -m unittest discover -s tests -p '*.py' -t . + uv run python -m unittest discover -s tests -p '*.py' -t . diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index cb05480..6d0269a 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,6 +1,6 @@ repos: - repo: https://github.com/pre-commit/pre-commit-hooks - rev: v5.0.0 + rev: v6.0.0 hooks: - id: trailing-whitespace - id: end-of-file-fixer @@ -14,13 +14,13 @@ repos: exclude: _pb2\.py - repo: https://github.com/pre-commit/mirrors-mypy - rev: v1.14.1 + rev: v1.19.1 hooks: - id: mypy exclude: ^(tests/|test_data/|_pb2\.py) - repo: https://github.com/PyCQA/pylint - rev: v3.3.4 + rev: v4.0.4 hooks: - id: pylint exclude: _pb2\.py diff --git a/pyproject.toml b/pyproject.toml index 7f012c3..a19f7e7 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -9,15 +9,12 @@ requires-python = ">=3.9" description = "dfindexeddb is an experimental Python tool for performing digital forensic analysis of IndexedDB and leveldb files." license = "Apache-2.0" license-files = ["LICENSE"] -authors = [{name = "Syd Pleno", email = "sydp@google.com"}] +authors = [{ name = "Syd Pleno", email = "sydp@google.com" }] maintainers = [ - {name = "dfIndexeddb Developers", email = "dfindexeddb-dev@googlegroups.com"}, + { name = "dfIndexeddb Developers", email = "dfindexeddb-dev@googlegroups.com" }, ] -dependencies = [ - "python-snappy==0.6.1", - "zstd==1.5.5.1", -] -readme = {file = "README.md", content-type = "text/markdown"} +dependencies = ["python-snappy>=0.6.1", "zstd>=1.5.5.1"] +readme = { file = "README.md", content-type = "text/markdown" } classifiers = [ "Development Status :: 3 - Alpha", "Programming Language :: Python", diff --git a/setup.py b/setup.py deleted file mode 100644 index 7bdac75..0000000 --- a/setup.py +++ /dev/null @@ -1,19 +0,0 @@ -""" -Copyright 2024 Google LLC - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - https://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -""" - -from setuptools import setup - -setup() From 41f19f3c43b86c40b0ffc8d7fa45128f03a54bc6 Mon Sep 17 00:00:00 2001 From: impervius <63152795+impervius@users.noreply.github.com> Date: Fri, 6 Feb 2026 17:19:57 +0200 Subject: [PATCH 2/5] Add missing newline in .gitignore --- .gitignore | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitignore b/.gitignore index 4da4542..58a3dfd 100644 --- a/.gitignore +++ b/.gitignore @@ -81,4 +81,4 @@ ENV/ .DS_Store -*.code-workspace \ No newline at end of file +*.code-workspace From c858ff664943d59021de4cb2309fdc18ed47773b Mon Sep 17 00:00:00 2001 From: impervius <63152795+impervius@users.noreply.github.com> Date: Fri, 6 Feb 2026 17:49:37 +0200 Subject: [PATCH 3/5] Fix python-version for uv --- .github/workflows/pypi-publish.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/pypi-publish.yml b/.github/workflows/pypi-publish.yml index a2aa734..12081f2 100644 --- a/.github/workflows/pypi-publish.yml +++ b/.github/workflows/pypi-publish.yml @@ -12,7 +12,7 @@ jobs: - name: Set up Python uses: astral-sh/setup-uv@v7 with: - python-version: "3.x" + python-version: "3" - name: Build package run: uv build - name: Store the distribution packages From 19820eaa99c9fadbcf254018abe1a4543cef9e6d Mon Sep 17 00:00:00 2001 From: impervius <63152795+impervius@users.noreply.github.com> Date: Sat, 7 Feb 2026 08:26:35 +0200 Subject: [PATCH 4/5] Fix merge issue --- .github/workflows/mypy.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/mypy.yml b/.github/workflows/mypy.yml index 38a1e9d..26add89 100644 --- a/.github/workflows/mypy.yml +++ b/.github/workflows/mypy.yml @@ -21,5 +21,4 @@ jobs: uv sync - name: Analysing the code with mypy run: | - uv run --with mypy mypy dfindexeddb uv run --with mypy mypy dfindexeddb tests From 46d3776e966e90b39dfc693c28bdb52ca3aea01e Mon Sep 17 00:00:00 2001 From: impervius <63152795+impervius@users.noreply.github.com> Date: Fri, 20 Feb 2026 18:19:03 +0200 Subject: [PATCH 5/5] Revert CI changes per maintainer's request --- .github/workflows/mypy.yml | 11 +++++++---- .github/workflows/pylint.yml | 11 +++++++---- .github/workflows/pypi-publish.yml | 20 ++++++++++++-------- .github/workflows/unittests.yml | 10 ++++++---- .pre-commit-config.yaml | 6 +++--- 5 files changed, 35 insertions(+), 23 deletions(-) diff --git a/.github/workflows/mypy.yml b/.github/workflows/mypy.yml index 26add89..828a81a 100644 --- a/.github/workflows/mypy.yml +++ b/.github/workflows/mypy.yml @@ -11,14 +11,17 @@ jobs: matrix: python-version: ["3.9", "3.10", "3.11", "3.12", "3.13", "3.14"] steps: - - uses: actions/checkout@v6 + - uses: actions/checkout@v3 - name: Set up Python ${{ matrix.python-version }} - uses: astral-sh/setup-uv@v7 + uses: actions/setup-python@v3 with: python-version: ${{ matrix.python-version }} - name: Install dependencies run: | - uv sync + python -m pip install --upgrade pip + pip install python-snappy + pip install zstd + pip install mypy - name: Analysing the code with mypy run: | - uv run --with mypy mypy dfindexeddb tests + mypy dfindexeddb tests diff --git a/.github/workflows/pylint.yml b/.github/workflows/pylint.yml index 8cc6893..93b7838 100644 --- a/.github/workflows/pylint.yml +++ b/.github/workflows/pylint.yml @@ -11,14 +11,17 @@ jobs: matrix: python-version: ["3.9", "3.10", "3.11", "3.12", "3.13", "3.14"] steps: - - uses: actions/checkout@v6 + - uses: actions/checkout@v3 - name: Set up Python ${{ matrix.python-version }} - uses: astral-sh/setup-uv@v7 + uses: actions/setup-python@v3 with: python-version: ${{ matrix.python-version }} - name: Install dependencies run: | - uv sync + python -m pip install --upgrade pip + pip install python-snappy + pip install zstd + pip install pylint - name: Analysing the code with pylint run: | - uv run --with pylint pylint --rc-file=.pylintrc dfindexeddb tests + pylint --rc-file=.pylintrc dfindexeddb tests diff --git a/.github/workflows/pypi-publish.yml b/.github/workflows/pypi-publish.yml index 12081f2..b68bfee 100644 --- a/.github/workflows/pypi-publish.yml +++ b/.github/workflows/pypi-publish.yml @@ -8,15 +8,19 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v6 + - uses: actions/checkout@v4 - name: Set up Python - uses: astral-sh/setup-uv@v7 + uses: actions/setup-python@v4 with: - python-version: "3" + python-version: "3.x" + - name: Install dependencies + run: | + python -m pip install --upgrade pip + pip install build - name: Build package - run: uv build + run: python -m build - name: Store the distribution packages - uses: actions/upload-artifact@v6 + uses: actions/upload-artifact@v4 with: name: python-package-distributions path: dist/ @@ -37,7 +41,7 @@ jobs: steps: - name: Download all the dists - uses: actions/download-artifact@v7 + uses: actions/download-artifact@v4.1.7 with: name: python-package-distributions path: dist/ @@ -56,12 +60,12 @@ jobs: steps: - name: Download all the dists - uses: actions/download-artifact@v7 + uses: actions/download-artifact@v4.1.7 with: name: python-package-distributions path: dist/ - name: Sign the dists with Sigstore - uses: sigstore/gh-action-sigstore-python@v3.2.0 + uses: sigstore/gh-action-sigstore-python@v3.0.0 with: inputs: >- ./dist/*.tar.gz diff --git a/.github/workflows/unittests.yml b/.github/workflows/unittests.yml index 91f6bdf..b9bbc72 100644 --- a/.github/workflows/unittests.yml +++ b/.github/workflows/unittests.yml @@ -11,14 +11,16 @@ jobs: matrix: python-version: ["3.9", "3.10", "3.11", "3.12", "3.13", "3.14"] steps: - - uses: actions/checkout@v6 + - uses: actions/checkout@v3 - name: Set up Python ${{ matrix.python-version }} - uses: astral-sh/setup-uv@v7 + uses: actions/setup-python@v3 with: python-version: ${{ matrix.python-version }} - name: Install dependencies run: | - uv sync + python -m pip install --upgrade pip + pip install python-snappy + pip install zstd - name: Run unittests run: | - uv run python -m unittest discover -s tests -p '*.py' -t . + python -m unittest discover -s tests -p '*.py' -t . diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 53a0edb..8c69f64 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,6 +1,6 @@ repos: - repo: https://github.com/pre-commit/pre-commit-hooks - rev: v6.0.0 + rev: v5.0.0 hooks: - id: trailing-whitespace - id: end-of-file-fixer @@ -14,13 +14,13 @@ repos: exclude: _pb2\.py - repo: https://github.com/pre-commit/mirrors-mypy - rev: v1.19.1 + rev: v1.14.1 hooks: - id: mypy exclude: ^(test_data/|_pb2\.py) - repo: https://github.com/PyCQA/pylint - rev: v4.0.4 + rev: v3.3.4 hooks: - id: pylint exclude: _pb2\.py