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

After upgrading to v0.0.5, the content directory watcher stops adding new archives to the ComicLib database #10

Open
Arkyver opened this issue Jan 27, 2024 · 1 comment

Comments

@Arkyver
Copy link

Arkyver commented Jan 27, 2024

I've observed that since the release of v0.0.5, the changes in the content path no longer trigger a scan, which prevents new archives from being added to the database. This issue seems to stem from the fact that directory updates are now being excluded from the watchfiles in scan.py, as seen in this line of code:

for changes in watchfiles.watch(settings.content, watch_filter=lambda change, path: change in (watchfiles.Change.added, watchfiles.Change.modified) and Path(path).is_file()):

Because the scanners such as 22-ehviewer.py require the parent directory path of the image files, the scan will skip them when is invoked with a path to image files. Is this modification intended to address other issues?

@URenko
Copy link
Contributor

URenko commented Jan 27, 2024

As described in the release note, directory will not trigger a scan during watch since v0.0.5.

This is because, unlike single files, it is difficult to determine when the contents of this directory have been completely created.
Therefore we cannot accurately count some metadata, such as page count.
I'll try to re-enable it once a good solution is available.

Before that, you can try some manual ways to trigger a scan: https://comiclib.github.io/comiclib/en/scan%26watch/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants