From 1a5b830b7560975ec2c968d3f86e0a028acdcb49 Mon Sep 17 00:00:00 2001 From: Quentin Schulz Date: Tue, 19 Nov 2024 21:25:21 +0100 Subject: [PATCH 1/9] DO NOT MERGE: only to check CI still works without changes Signed-off-by: Quentin Schulz --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index 7579d40f..802cea34 100644 --- a/README.md +++ b/README.md @@ -2,6 +2,8 @@

+PLEP + ![GitHub](https://img.shields.io/github/license/recitale/recitale?color=brightgreen) ![PyPI - Python Version](https://img.shields.io/pypi/pyversions/recitale) ![PyPI - Status](https://img.shields.io/pypi/status/recitale) From 8a641e891ec09870c2d789ffa69a7c9dc8f6c2b3 Mon Sep 17 00:00:00 2001 From: Quentin Schulz Date: Tue, 19 Nov 2024 21:42:28 +0100 Subject: [PATCH 2/9] DO NOT MERGE: try with newer actions? Signed-off-by: Quentin Schulz --- .github/workflows/devel.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/devel.yml b/.github/workflows/devel.yml index 2225e188..b0e83062 100644 --- a/.github/workflows/devel.yml +++ b/.github/workflows/devel.yml @@ -4,8 +4,8 @@ jobs: tox: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 - - uses: actions/setup-python@v2 + - uses: actions/checkout@v4 + - uses: actions/setup-python@v5 with: python-version: '3.x' - name: Install dependencies @@ -25,8 +25,8 @@ jobs: build-example: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 - - uses: actions/setup-python@v2 + - uses: actions/checkout@v4 + - uses: actions/setup-python@v5 with: python-version: '3.x' - name: Install dependencies From f78eaa313e5892300192be0058cdd72f9e59e789 Mon Sep 17 00:00:00 2001 From: Quentin Schulz Date: Tue, 19 Nov 2024 21:44:10 +0100 Subject: [PATCH 3/9] DO NOT MERGE: try python 3.13? Signed-off-by: Quentin Schulz --- .github/workflows/devel.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/devel.yml b/.github/workflows/devel.yml index b0e83062..29a11b2f 100644 --- a/.github/workflows/devel.yml +++ b/.github/workflows/devel.yml @@ -7,7 +7,7 @@ jobs: - uses: actions/checkout@v4 - uses: actions/setup-python@v5 with: - python-version: '3.x' + python-version: '3.13' - name: Install dependencies run: | set -xe @@ -28,7 +28,7 @@ jobs: - uses: actions/checkout@v4 - uses: actions/setup-python@v5 with: - python-version: '3.x' + python-version: '3.13' - name: Install dependencies run: | set -xe From 8d5dcdb4f03e6b8ad5abca9a09fdb08fe5ce72f0 Mon Sep 17 00:00:00 2001 From: Quentin Schulz Date: Tue, 19 Nov 2024 21:53:48 +0100 Subject: [PATCH 4/9] DO NOT MERGE: maybe ubuntu's the culprit?? Signed-off-by: Quentin Schulz --- .github/workflows/devel.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/devel.yml b/.github/workflows/devel.yml index 29a11b2f..02a9be8f 100644 --- a/.github/workflows/devel.yml +++ b/.github/workflows/devel.yml @@ -2,7 +2,7 @@ on: [push, pull_request] jobs: tox: - runs-on: ubuntu-latest + runs-on: ubuntu-22.04 steps: - uses: actions/checkout@v4 - uses: actions/setup-python@v5 @@ -23,7 +23,7 @@ jobs: verbose: true build-example: - runs-on: ubuntu-latest + runs-on: ubuntu-22.04 steps: - uses: actions/checkout@v4 - uses: actions/setup-python@v5 From 251c38ecd98aeb79a8d25a43510368cdf65c0289 Mon Sep 17 00:00:00 2001 From: Quentin Schulz Date: Tue, 19 Nov 2024 22:07:56 +0100 Subject: [PATCH 5/9] DO NOT MERGE: add debugging Signed-off-by: Quentin Schulz --- recitale/autogen.py | 5 ++++- tox.ini | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/recitale/autogen.py b/recitale/autogen.py index a5ee288e..bceab8f1 100644 --- a/recitale/autogen.py +++ b/recitale/autogen.py @@ -42,9 +42,12 @@ def get_exif(filename): # DateTimeOriginal, DateTimeDigitized, DateTime(DateTimeModified) ctime = exif.get(0x9003, exif.get(0x9004, exif.get(0x0132))) if ctime is not None: + logger.error('%s: ctime %s' % (filename, ctime)) return ctime - return strftime(TIME_FORMAT, gmtime(os.path.getmtime(filename))) + s = strftime(TIME_FORMAT, gmtime(os.path.getmtime(filename))) + logger.error('%s: mtime: %s' % (filename, s)) + return s def build_template(folder, force): diff --git a/tox.ini b/tox.ini index b7d784d1..0768e10d 100644 --- a/tox.ini +++ b/tox.ini @@ -48,4 +48,4 @@ commands = bandit -s B404,B603,B701 -r recitale [testenv:pytest] extras = tests -commands = pytest --cov={envsitepackagesdir}/recitale/ --cov-report=xml +commands = pytest --cov={envsitepackagesdir}/recitale/ --cov-report=xml -vv From 76c82e8210cc88f25bcfe78946acc5fd268311da Mon Sep 17 00:00:00 2001 From: Quentin Schulz Date: Tue, 19 Nov 2024 22:27:55 +0100 Subject: [PATCH 6/9] DO NOT MERGE: log array Signed-off-by: Quentin Schulz --- recitale/autogen.py | 1 + 1 file changed, 1 insertion(+) diff --git a/recitale/autogen.py b/recitale/autogen.py index bceab8f1..7daa9681 100644 --- a/recitale/autogen.py +++ b/recitale/autogen.py @@ -72,6 +72,7 @@ def build_template(folder, force): template = Template(DATA, trim_blocks=True) files = sorted(files_grabbed, key=get_exif) + logger.error(files) cover = gallery_settings.get("cover", files[0].name) date = gallery_settings.get("date") From 3020ed00dd8c38d581bed54ec04105b90f9063f7 Mon Sep 17 00:00:00 2001 From: Quentin Schulz Date: Tue, 19 Nov 2024 22:29:11 +0100 Subject: [PATCH 7/9] DO NOT MERGE: print get_exif Signed-off-by: Quentin Schulz --- recitale/autogen.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/recitale/autogen.py b/recitale/autogen.py index 7daa9681..abaa36bb 100644 --- a/recitale/autogen.py +++ b/recitale/autogen.py @@ -71,8 +71,9 @@ def build_template(folder, force): files_grabbed.extend(Path(folder).glob(files)) template = Template(DATA, trim_blocks=True) - files = sorted(files_grabbed, key=get_exif) - logger.error(files) + for file in files_grabbed: + logger.error('%s exif: %s' % (file, get_exif(file)) + files = files_grabbed cover = gallery_settings.get("cover", files[0].name) date = gallery_settings.get("date") From 907210980c0f3bf1312abb44ec2fee89c7014bc4 Mon Sep 17 00:00:00 2001 From: Quentin Schulz Date: Tue, 19 Nov 2024 22:31:27 +0100 Subject: [PATCH 8/9] fixup! DO NOT MERGE: print get_exif --- recitale/autogen.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recitale/autogen.py b/recitale/autogen.py index abaa36bb..568e0a24 100644 --- a/recitale/autogen.py +++ b/recitale/autogen.py @@ -72,7 +72,7 @@ def build_template(folder, force): template = Template(DATA, trim_blocks=True) for file in files_grabbed: - logger.error('%s exif: %s' % (file, get_exif(file)) + logger.error('%s exif: %s' % (file, get_exif(file))) files = files_grabbed cover = gallery_settings.get("cover", files[0].name) From 3874f6567cb99a18f14f74f1d20f4176b75f09ce Mon Sep 17 00:00:00 2001 From: Quentin Schulz Date: Tue, 19 Nov 2024 22:34:10 +0100 Subject: [PATCH 9/9] DO NOT MERGE: increase log level of pyest Signed-off-by: Quentin Schulz --- tox.ini | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tox.ini b/tox.ini index 0768e10d..349408ba 100644 --- a/tox.ini +++ b/tox.ini @@ -49,3 +49,7 @@ commands = bandit -s B404,B603,B701 -r recitale [testenv:pytest] extras = tests commands = pytest --cov={envsitepackagesdir}/recitale/ --cov-report=xml -vv + +[pytest] +log_cli = True +log_level = DEBUG