Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dev/test ci #1

Open
wants to merge 77 commits into
base: devel
Choose a base branch
from
Open
Changes from 1 commit
Commits
Show all changes
77 commits
Select commit Hold shift + click to select a range
e15da6d
recitale: move log-level optional parameter as argument of subcommands
QSchulz Dec 18, 2021
1db92ac
recitale: video: fix BaseVideo.ratio crashing by casting str to int
QSchulz Dec 23, 2021
8398e3f
recitale: video: fix call of ratio for BaseVideo
QSchulz Dec 23, 2021
38cb01f
recitale: video: factor out ffprobe execution and parsing
QSchulz Dec 23, 2021
aade25e
recitale: video: switch ffprobe parsing from csv to json
QSchulz Dec 23, 2021
0bc7c26
recitale: video: get and expose duration of video
QSchulz Dec 23, 2021
115d31b
recitale: display progress bar when reencoding video
QSchulz Dec 23, 2021
0f1a949
recitale: audio: get and expose duration for audio
QSchulz Dec 23, 2021
4f1c784
recitale: audio: display progressbar when reencoding audio
QSchulz Dec 23, 2021
cf0805c
.coveragerc: display untested lines
QSchulz Dec 31, 2021
c50a6b7
test: make "same" checks for factories check for same object
QSchulz Jan 1, 2022
3c3bef2
test: cover 100% of recitale/audio.py
QSchulz Jan 1, 2022
94d64c8
test: image: improve code coverage by testing BaseImage
QSchulz Jan 1, 2022
c864e40
test: video: improve code coverage by testing BaseVideo
QSchulz Jan 1, 2022
b3b2bed
recitale: utils: migrate from subprocess'ed openssl encryption to pyc…
QSchulz Jan 4, 2022
b731e9f
docs: configuration: explicit that only the HTML is encrypted not media
QSchulz Jan 4, 2022
3bb0f1c
.github: workflows: release: use github.ref_name to get the branch/ta…
QSchulz Jan 6, 2022
0e71ec3
add Dockerfile
QSchulz Jan 6, 2022
e278efe
.github: workflows: release: build, test and push container image to …
QSchulz Jan 6, 2022
357c292
recitale: migrate from path.py to pathlib
QSchulz Dec 18, 2021
a0e694a
v2.0.0a2 release
QSchulz Jan 15, 2022
460ed48
fix URL for github container image
QSchulz Jan 15, 2022
ebcfa00
recitale: cast dpi to make it serializable
QSchulz Feb 6, 2022
b846930
v2.0.0a3 release
QSchulz Feb 19, 2022
3123448
set minimum version of Jinja2
QSchulz May 7, 2022
5f7fb06
recitale: remove with_ Jinja2 extension
QSchulz May 7, 2022
341f972
v2.0.0a4 release
QSchulz May 7, 2022
af61dac
tox.ini: fix flake configuration error
QSchulz Feb 6, 2023
dd3c16a
recitale: exposure: fix video not aligned on thumbnail
QSchulz Feb 2, 2023
d71e41c
recitale: exposure: fix video format in bordered-pictures section
QSchulz Feb 2, 2023
8c26d3f
recitale: exposure: adapt vertical video in pictures-group section
QSchulz Feb 2, 2023
79e7bda
move thumbnail/reencode addition in own function
QSchulz Feb 6, 2023
fa2b41f
handle filenames with spaces
QSchulz Feb 6, 2023
4784083
v2.0.0a5 release
QSchulz Feb 10, 2023
d57e313
fix shlex.quote call on a PosixPath object
fr33tux May 6, 2023
6a0e78c
recitale: autogen: pass a string to glob.glob
QSchulz Mar 2, 2023
acebd7d
recitale: autogen: replace glob.glob by pathlib.Path.glob
QSchulz Mar 2, 2023
7159393
recitale: autogen: close fd after writing
QSchulz Mar 2, 2023
38dc92e
test: add tests for autogen
QSchulz Jul 9, 2023
b98fd29
recitale: share variable with Pool funcs via dict
QSchulz Aug 29, 2023
10b55dc
cache: remove reference to json module
QSchulz Aug 29, 2023
348ab08
recitale: move local function to module namespace
QSchulz Aug 29, 2023
65201a8
use local variable for global cache
QSchulz Aug 29, 2023
bf71f70
recitale: remove unnecessary "test" in DEFAULTS
QSchulz Aug 29, 2023
4c9c6ac
recitale: limit scope of DEFAULTS variable
QSchulz Aug 29, 2023
b7ea1fd
recitale: move parser out of module namespace
QSchulz Aug 29, 2023
0cb4366
autogen: autofill cover gallery setting if missing
QSchulz Aug 26, 2023
5e525a5
autogen: autofill date gallery setting if missing
QSchulz Aug 26, 2023
30960e9
docs: configuration: add doc for show_date root setting
QSchulz Feb 13, 2023
e9b5b25
docs: configuration: document ffmpeg_audio settings
QSchulz Feb 13, 2023
b8da70e
docs: configuration: fix ffmpeg typo
QSchulz Feb 13, 2023
5c4f595
recitale: fix locale date filter when locale unset
QSchulz Aug 31, 2023
7dd93a4
add .vscode to gitignore
sebsto Sep 5, 2023
173b85e
missing closing curly bracket in recitale/themes/light/templates/inde…
sebsto Sep 5, 2023
97ab940
themes: fix author page website link
QSchulz Sep 5, 2023
08797a4
update HTTP links to HTTPS
QSchulz Sep 5, 2023
12a1a79
docs: index: remove such.life
QSchulz Sep 5, 2023
ff54b38
themes: share: remove Google+ links
QSchulz Sep 5, 2023
2fcb6c8
themes: material: index: fix incorrect background URL
QSchulz Sep 5, 2023
0bb497e
dependencies: force ruamel.yaml older than 0.18.0
QSchulz Dec 30, 2023
23d2d39
themes: material: style-page.css: make caption 100% of bordered-picture
QSchulz Dec 30, 2023
d21ecd9
tox: avoid bringing in pre-release versions
QSchulz Dec 30, 2023
3e965fa
tests: image: fix incorrect assertion test
QSchulz Dec 30, 2023
5101fcb
v2.0.0a6 release
QSchulz Dec 30, 2023
ca136fc
themes: exposure: style-page.css: make caption 100% of bordered-picture
QSchulz Dec 30, 2023
7a1e1bc
themes: exposure: fix video URL covers for subgalleries
QSchulz Dec 30, 2023
5c27c48
autogen: include seconds in date format
QSchulz Dec 31, 2023
3429d71
test: autogen: use non-zero number for seconds in exif field
QSchulz Jan 2, 2024
1a5b830
DO NOT MERGE: only to check CI still works without changes
QSchulz Nov 19, 2024
8a641e8
DO NOT MERGE: try with newer actions?
QSchulz Nov 19, 2024
f78eaa3
DO NOT MERGE: try python 3.13?
QSchulz Nov 19, 2024
8d5dcdb
DO NOT MERGE: maybe ubuntu's the culprit??
QSchulz Nov 19, 2024
251c38e
DO NOT MERGE: add debugging
QSchulz Nov 19, 2024
76c82e8
DO NOT MERGE: log array
QSchulz Nov 19, 2024
3020ed0
DO NOT MERGE: print get_exif
QSchulz Nov 19, 2024
9072109
fixup! DO NOT MERGE: print get_exif
QSchulz Nov 19, 2024
3874f65
DO NOT MERGE: increase log level of pyest
QSchulz Nov 19, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
cache: remove reference to json module
The comment states that this is required for Python 3.3 and earlier.
Python 3.3 has been EoL since October 2017 so I think we're fine now.

This also was an issue for non-Unix systems because Cache needs to be
picklable for any non-fork spawning method and Python modules aren't
picklable.

Signed-off-by: Quentin Schulz <foss+recitale@0leil.net>
QSchulz committed Aug 31, 2023
commit 10b55dc365160fac198c125d4dbdbd9ad8940a65
11 changes: 3 additions & 8 deletions recitale/cache.py
Original file line number Diff line number Diff line change
@@ -16,12 +16,7 @@
class Cache:
cache_file_path = os.path.join(os.getcwd(), ".recitale_cache")

def __init__(self, json):
# fix: I need to keep a reference to json because for whatever reason
# modules are set to None during python shutdown thus totally breaking
# the __del__ call to save the cache
# This wonderfully stupid behavior has been fixed in 3.4 (which nobody uses)
self.json = json
def __init__(self):
if os.path.exists(os.path.join(os.getcwd(), ".recitale_cache")):
cache = json.load(open(self.cache_file_path, "r"))
else:
@@ -77,7 +72,7 @@ def cache_picture(self, source, target, options):
}

def cache_dump(self):
self.json.dump(dict(self.cache), open(self.cache_file_path, "w"))
json.dump(dict(self.cache), open(self.cache_file_path, "w"))


CACHE = Cache(json=json)
CACHE = Cache()
6 changes: 3 additions & 3 deletions test/test_cache.py
Original file line number Diff line number Diff line change
@@ -10,7 +10,7 @@

@pytest.fixture
def cache():
return Cache(json=json)
return Cache()


class TestCache:
@@ -21,7 +21,7 @@ def test_new_cache(self, cache):
def test_load_cache(self, mock_ospath):
cache_json = {"version": CACHE_VERSION, "some": "value"}
with patch("builtins.open", mock_open(read_data=json.dumps(cache_json))):
cache = Cache(json=json)
cache = Cache()

assert dict(cache.cache) == cache_json

@@ -31,7 +31,7 @@ def test_load_cache(self, mock_ospath):
)
def test_load_old_cache(self, mock_ospath, cache_dict):
with patch("builtins.open", mock_open(read_data=json.dumps(cache_dict))):
cache = Cache(json=json)
cache = Cache()

assert dict(cache.cache) == {"version": CACHE_VERSION}