Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: BlueBrain/dir-content-diff
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 1.7.0
Choose a base ref
...
head repository: BlueBrain/dir-content-diff
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: main
Choose a head ref

Commits on Feb 8, 2024

  1. Chore: Apply Copier template (#55)

    [skip-changelog]
    adrien-berchet authored Feb 8, 2024
    Copy the full SHA
    76d8569 View commit details

Commits on Apr 8, 2024

  1. Feat: Add new comparators for Feather, Parquet and Stata files (#56)

    * Feat: Add new comparators for Feather, Parquet and Stata files
    
    * Fix: Fix coverage
    adrien-berchet authored Apr 8, 2024
    Copy the full SHA
    cf58e52 View commit details
  2. Copy the full SHA
    47b5735 View commit details

Commits on Apr 26, 2024

  1. Copy the full SHA
    55fe9eb View commit details

Commits on May 1, 2024

  1. Copy the full SHA
    d7f7d9f View commit details

Commits on Aug 29, 2024

  1. Copy the full SHA
    40a64ff View commit details
  2. Release: 1.9.0 (#61)

    adrien-berchet authored Aug 29, 2024
    Copy the full SHA
    e0d0f4d View commit details
  3. Copy the full SHA
    7db2807 View commit details
  4. Release: 1.9.1 (#63)

    adrien-berchet authored Aug 29, 2024
    Copy the full SHA
    d1a407f View commit details

Commits on Sep 9, 2024

  1. Copy the full SHA
    0b3b40e View commit details
  2. Copy the full SHA
    732ee4e View commit details

Commits on Nov 6, 2024

  1. Copy the full SHA
    154eb4f View commit details
  2. Copy the full SHA
    0508561 View commit details

Commits on Nov 12, 2024

  1. Chore: Add license headers, use pyproject.toml file and migrate docs …

    …to MyST parser (#68)
    
    * Chore: Add license headers and use pyproject.toml file
    
    * Docs: Migrate from m2r2 to MyST parser
    
    * Build: Fix dependencies
    adrien-berchet authored Nov 12, 2024
    Copy the full SHA
    afb0261 View commit details

Commits on Nov 13, 2024

  1. Copy the full SHA
    0a2bf7f View commit details

Commits on Nov 17, 2024

  1. Feat: Add CLI (#70)

    adrien-berchet authored Nov 17, 2024
    Copy the full SHA
    c630f60 View commit details

Commits on Nov 18, 2024

  1. CI(dependabot): bump codecov/codecov-action from 4 to 5 (#72)

    Bumps [codecov/codecov-action](https://github.com/codecov/codecov-action) from 4 to 5.
    - [Release notes](https://github.com/codecov/codecov-action/releases)
    - [Changelog](https://github.com/codecov/codecov-action/blob/main/CHANGELOG.md)
    - [Commits](codecov/codecov-action@v4...v5)
    
    ---
    updated-dependencies:
    - dependency-name: codecov/codecov-action
      dependency-type: direct:production
      update-type: version-update:semver-major
    ...
    
    Signed-off-by: dependabot[bot] <support@github.com>
    Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
    dependabot[bot] authored Nov 18, 2024
    Copy the full SHA
    a9741d8 View commit details
  2. Copy the full SHA
    3cb0e93 View commit details
  3. Release: 1.12.0 (#71)

    adrien-berchet authored Nov 18, 2024
    Copy the full SHA
    86d0d9d View commit details

Commits on Jul 3, 2025

  1. Fix: Properly update the verbosity in PDF comparator (#75)

    * Test: Fix expected results for diff-pdf-visually>=1.8.1
    
    * Fix: Properly update the verbosity in PDF comparator
    
    * CI: Drop APT cache
    
    * Chore: Update licence headers
    adrien-berchet authored Jul 3, 2025
    Copy the full SHA
    7e172e4 View commit details
  2. Copy the full SHA
    041c3b7 View commit details
  3. Copy the full SHA
    26199cb View commit details
Showing with 2,506 additions and 252 deletions.
  1. +1 −1 .codespellrc
  2. +2 −2 .copier-answers.yml
  3. +6 −0 .copyright.tmpl
  4. +11 −0 .coveragerc_min_versions
  5. +0 −7 .flake8
  6. +4 −2 .github/workflows/commitlint.yml
  7. +2 −2 .github/workflows/publish-sdist.yml
  8. +20 −10 .github/workflows/run-tox.yml
  9. +21 −11 .pre-commit-config.yaml
  10. +1 −0 .pylintrc
  11. +2 −2 .readthedocs.yml
  12. +77 −0 CHANGELOG.md
  13. +1 −1 CONTRIBUTING.md
  14. +2 −0 MANIFEST.in
  15. +71 −29 dir_content_diff/__init__.py
  16. +143 −20 dir_content_diff/base_comparators.py
  17. +188 −0 dir_content_diff/cli/__init__.py
  18. +10 −0 dir_content_diff/comparators/__init__.py
  19. +9 −0 dir_content_diff/comparators/dependencies.json
  20. +53 −0 dir_content_diff/comparators/morphio.py
  21. +54 −4 dir_content_diff/{ → comparators}/pandas.py
  22. +156 −0 dir_content_diff/comparators/voxcell.py
  23. +10 −0 dir_content_diff/pytest_plugin.py
  24. +87 −1 dir_content_diff/util.py
  25. +3 −1 docs/source/api_ref.rst
  26. +2 −1 docs/source/changelog.rst
  27. +27 −7 docs/source/conf.py
  28. +2 −1 docs/source/contributing.rst
  29. +2 −1 docs/source/index.rst
  30. +61 −2 pyproject.toml
  31. +28 −54 setup.py
  32. +9 −0 tests/__init__.py
  33. +10 −0 tests/comparators/__init__.py
  34. +92 −0 tests/comparators/test_morphio.py
  35. +272 −40 tests/{ → comparators}/test_pandas.py
  36. +367 −0 tests/comparators/test_voxcell.py
  37. +18 −2 tests/conftest.py
  38. +10 −0 tests/generate_test_files.py
  39. +234 −33 tests/test_base.py
  40. +276 −0 tests/test_cli.py
  41. +45 −0 tests/test_missing_deps.py
  42. +12 −2 tests/test_pytest_plugin.py
  43. +49 −0 tests/test_util.py
  44. +12 −2 tests/test_version.py
  45. +44 −14 tox.ini
2 changes: 1 addition & 1 deletion .codespellrc
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
[codespell]
skip = .git/*
skip = .git/*,*.pdf
4 changes: 2 additions & 2 deletions .copier-answers.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Changes here will be overwritten by Copier

_commit: 0.1.53
_commit: 0.1.67
_src_path: git@bbpgitlab.epfl.ch:neuromath/python-template.git
author_email: ''
author_name: Blue Brain Project, EPFL
@@ -21,7 +21,7 @@ setup_codeql: false
ssh_url: git@github.com:BlueBrain/dir-content-diff.git
team_name: ''
tracker_url: https://github.com/BlueBrain/dir-content-diff/issues
use_pyproject_toml: false
use_pyproject_toml: true
version: 1.1.0

# End of Copier answers
6 changes: 6 additions & 0 deletions .copyright.tmpl
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
Copyright (c) 2023-${edit_year} Blue Brain Project, EPFL.

This file is part of dir-content-diff.
See https://github.com/BlueBrain/dir-content-diff for further info.

SPDX-License-Identifier: Apache-2.0
11 changes: 11 additions & 0 deletions .coveragerc_min_versions
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
[paths]
source_paths =
dir_content_diff
*/site-packages/dir_content_diff
*/dir_content_diff/dir_content_diff
*/dir-content-diff/dir_content_diff

[report]
exclude_also =
return pd\.read_feather\(path, \*\*kwargs\)
data\.to_feather\(path, \*\*kwargs\)
7 changes: 0 additions & 7 deletions .flake8

This file was deleted.

6 changes: 4 additions & 2 deletions .github/workflows/commitlint.yml
Original file line number Diff line number Diff line change
@@ -8,12 +8,14 @@ jobs:
check-pr-title:
name: Check PR title
runs-on: ubuntu-latest
env:
PR_TITLE: ${{ github.event.pull_request.title }}
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: '16'
node-version: '20'
- run: npm install -g --force commitlint @commitlint/cli commitlint-plugin-cleanfeet
- run: npm install conventional-changelog-conventionalcommits
- run: touch .git/COMMIT_EDITMSG
- run: echo "${{ github.event.pull_request.title }}" | commitlint
- run: echo "$PR_TITLE" | commitlint
4 changes: 2 additions & 2 deletions .github/workflows/publish-sdist.yml
Original file line number Diff line number Diff line change
@@ -11,10 +11,10 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python 3.8
- name: Set up Python 3.10
uses: actions/setup-python@v5
with:
python-version: 3.8
python-version: "3.10"
- name: Build a wheel and a source tarball
run: |
pip install setuptools>=42 build setuptools_scm[toml]>=3.4
30 changes: 20 additions & 10 deletions .github/workflows/run-tox.yml
Original file line number Diff line number Diff line change
@@ -6,19 +6,21 @@ on:
branches:
- main
workflow_dispatch:
schedule:
- cron: "0 2 15 1,7 *"

jobs:
build:

runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.8", "3.9", "3.10", "3.11"]
python-version: ["3.9", "3.10", "3.11", "3.12"]
min_versions: ["min_versions", "latest_versions"]
exclude:
- min_versions: "min_versions"
include:
- python-version: "3.8"
- python-version: "3.9"
min_versions: "min_versions"

steps:
@@ -30,12 +32,9 @@ jobs:
- name: Get current month
id: date
run: echo "date=$(date +'%Y-%m')" >> $GITHUB_OUTPUT
- name: Cache APT Packages
uses: awalsh128/cache-apt-pkgs-action@latest
with:
packages: poppler-utils imagemagick
version: 1.0
execute_install_scripts: true
- name: Install APT Packages
run: |
sudo apt-get install -y poppler-utils imagemagick
- name: Cache tox and precommit environments
uses: actions/cache@v4
with:
@@ -59,17 +58,28 @@ jobs:
pip install tox
tox run -e min_versions
- name: JUnit Report Action
uses: mikepenz/action-junit-report@v4
uses: mikepenz/action-junit-report@v5
if: always() # always run even if the previous step fails
with:
report_paths: 'reports/pytest-*.xml'
- name: Upload to codecov
uses: codecov/codecov-action@v4
uses: codecov/codecov-action@v5
with:
fail_ci_if_error: false
directory: ./reports
flags: pytest
name: "dir-content-diff-py${{ matrix.python-version }}-${{ matrix.min_versions }}"
token: ${{ secrets.CODECOV_TOKEN }}
- name: Upload to codecov results
uses: codecov/test-results-action@v1
with:
fail_ci_if_error: false
flags: pytest
directory: ./reports
name: "dir-content-diff-py${{ matrix.python-version }}-${{ matrix.min_versions }}-test-results"
token: ${{ secrets.CODECOV_TOKEN }}
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
- name: Upload test artifacts
uses: actions/upload-artifact@v4
if: always()
32 changes: 21 additions & 11 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
default_language_version:
python: python3.8
repos:
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.7.0
hooks:
- id: ruff
args: ["--fix", "--exit-non-zero-on-fix"]
- id: ruff-format
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.4.0
rev: v5.0.0
hooks:
- id: check-added-large-files
- id: check-case-conflict
@@ -13,22 +17,18 @@ repos:
- id: end-of-file-fixer
- id: trailing-whitespace
- repo: https://github.com/alessandrojcm/commitlint-pre-commit-hook
rev: v9.5.0
rev: v9.18.0
hooks:
- id: commitlint
stages:
- commit-msg
additional_dependencies: ['conventional-changelog-conventionalcommits']
- repo: https://github.com/pycqa/isort
rev: 5.12.0
rev: 5.13.2
hooks:
- id: isort
- repo: https://github.com/psf/black
rev: 23.9.1
hooks:
- id: black
- repo: https://github.com/codespell-project/codespell
rev: v2.2.5
rev: v2.3.0
hooks:
- id: codespell
args: ["-x", ".codespellignorelines"]
@@ -38,6 +38,16 @@ repos:
- id: pydocstyle
additional_dependencies: ["tomli"]
- repo: https://github.com/PyCQA/flake8
rev: 6.1.0
rev: 7.1.1
hooks:
- id: flake8
additional_dependencies: ['flake8-pyproject']
- repo: https://github.com/arkinmodi/add-license-header
rev: v2.2.0
hooks:
- id: add-license-header
args:
- --unmanaged
- --license-file
- .copyright.tmpl
files: \.py$
1 change: 1 addition & 0 deletions .pylintrc
Original file line number Diff line number Diff line change
@@ -3,6 +3,7 @@ disable=
arguments-differ,
invalid-name,
too-many-lines,
too-many-positional-arguments

[FORMAT]
# Regexp for a line that is allowed to be longer than the limit.
4 changes: 2 additions & 2 deletions .readthedocs.yml
Original file line number Diff line number Diff line change
@@ -6,9 +6,9 @@
version: 2

build:
os: ubuntu-20.04
os: ubuntu-22.04
tools:
python: "3.9"
python: "3.11"

sphinx:
configuration: docs/source/conf.py
77 changes: 77 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,82 @@
# Changelog

## [1.12.1](https://github.com/BlueBrain/dir-content-diff/compare/1.12.0..1.12.1)

> 3 July 2025
### Fixes

- Properly update the verbosity in PDF comparator (Adrien Berchet - [#75](https://github.com/BlueBrain/dir-content-diff/pull/75))

### CI Improvements

- Schedule CI every 6 months (Adrien Berchet - [#76](https://github.com/BlueBrain/dir-content-diff/pull/76))

## [1.12.0](https://github.com/BlueBrain/dir-content-diff/compare/1.11.0..1.12.0)

> 18 November 2024
### New Features

- Add CLI (Adrien Berchet - [#70](https://github.com/BlueBrain/dir-content-diff/pull/70))
- Intercept 'tempfile' argument of the PdfComparator to improve it (Adrien Berchet - [#69](https://github.com/BlueBrain/dir-content-diff/pull/69))

### Chores And Housekeeping

- Add license headers, use pyproject.toml file and migrate docs to MyST parser (Adrien Berchet - [#68](https://github.com/BlueBrain/dir-content-diff/pull/68))

### CI Improvements

- Push test results to Codecov (Adrien Berchet - [#73](https://github.com/BlueBrain/dir-content-diff/pull/73))

## [1.11.0](https://github.com/BlueBrain/dir-content-diff/compare/1.10.0..1.11.0)

> 6 November 2024
### Build

- Drop support for Python 3.8 (dependabot[bot] - [#66](https://github.com/BlueBrain/dir-content-diff/pull/66))

## [1.10.0](https://github.com/BlueBrain/dir-content-diff/compare/1.9.1..1.10.0)

> 10 September 2024
### New Features

- Add parameters for load and save methods of base comparators (Adrien Berchet - [#64](https://github.com/BlueBrain/dir-content-diff/pull/64))

## [1.9.1](https://github.com/BlueBrain/dir-content-diff/compare/1.9.0..1.9.1)

> 29 August 2024
### CI Improvements

- Fix publish job (Adrien Berchet - [#62](https://github.com/BlueBrain/dir-content-diff/pull/62))

## [1.9.0](https://github.com/BlueBrain/dir-content-diff/compare/1.8.1..1.9.0)

> 29 August 2024
### New Features

- Add new specific comparators (Adrien Berchet - [#60](https://github.com/BlueBrain/dir-content-diff/pull/60))

## [1.8.1](https://github.com/BlueBrain/dir-content-diff/compare/1.8.0..1.8.1)

> 1 May 2024
### Build

- Freeze docutils version to be compatible with m2r2 (Adrien Berchet - [#58](https://github.com/BlueBrain/dir-content-diff/pull/58))

## [1.8.0](https://github.com/BlueBrain/dir-content-diff/compare/1.7.0..1.8.0)

> 8 April 2024
### New Features

- Add new comparators for Feather, Parquet and Stata files (Adrien Berchet - [#56](https://github.com/BlueBrain/dir-content-diff/pull/56))

## [1.7.0](https://github.com/BlueBrain/dir-content-diff/compare/1.6.0..1.7.0)

> 5 February 2024
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -59,7 +59,7 @@ When you wish to contribute to the code base, please consider the following guid
or

```shell
tox -e py38 -e lint -e docs -e check-packaging
tox run -e py39,lint,docs,check-packaging
```

* Commit your changes using a descriptive commit message.
2 changes: 2 additions & 0 deletions MANIFEST.in
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
global-exclude *.py[co] .DS_Store

include dir_content_diff/comparators/dependencies.json
Loading