Skip to content

Server tasks, preview check and MP4 video previews - #47

Merged
Two-Play merged 2 commits into
developfrom
feature/server-tasks
Oct 24, 2026
Merged

Two-Play merged 2 commits into
developfrom
feature/server-tasks

Conversation

@Two-Play

Copy link
Copy Markdown
Owner

Refs #43. Replaces #44: instead of only a hint, the app can now start the work on the server itself.

What

  • Settings → Server tasks (new page, also linked as "Check previews on the server" under the preview settings):
    • Scan library (sheet: what to create for new files), Generate (covers, MP4 and WebP previews, sprites, marker previews/screenshots, phashes; only what's missing), Auto tag, Clean (with confirmation).
    • Running tasks from Stash's jobQueue, polled every 2 s while the page is open, with progress and a stop button.
    • Preview check: fetches one byte of the WebP/MP4 preview URLs of 8 random scenes and 4 markers (Stash answers 404 for missing files). If the WebP previews are missing: an explanation and "Generate animated previews". Runs again when a job finishes.
  • Preview format (Settings → Scene cards): animated image (WebP, default) or video (MP4). Video plays Stash's MP4 preview in its own muted media_kit player (PreviewVideo), one at a time, and the settings show a hint about the extra data, battery and memory. Markers keep the WebP.
  • GraphQL: tasks.graphql (jobQueue, stopJob, metadataScan/Generate/AutoTag/Clean). The demo accepts the mutations and has an empty queue.
  • Backlog: 3.4 ✅, 13.16 updated, new 13.18. CLAUDE.md updated.

Checks

  • dart analyze: no issues
  • flutter test: all 352 pass (new server_tasks_test.dart, demo test for the tasks and the check)
  • Not tried on a device against a real Stash yet, in particular the MP4 preview player's performance.

🤖 Generated with Claude Code

Settings → Server tasks starts Stash's scan, generate, auto tag and clean,
shows the job queue with progress and a stop button, and checks a random
sample of scenes and markers for their WebP and MP4 previews. When the
animated previews are missing it explains why and generates them.

The lists' previews can now play Stash's MP4 preview instead of the WebP
(Preview format), with a hint about the extra data, battery and memory.

Refs #43, replaces #44.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@codacy-production

Copy link
Copy Markdown

Up to standards ✅

🟢 Issues 0 issues

Results:
0 new issues

View in Codacy

🟢 Metrics 107 duplication

Metric Results
Duplication 107

View in Codacy

NEW Get contextual insights on your PRs based on Codacy's metrics, along with PR and Jira context, without leaving GitHub. Enable AI reviewer
TIP This summary will be updated as you push new changes.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@Two-Play
Two-Play merged commit 6c5aaa3 into develop Oct 24, 2026
4 checks passed
@Two-Play
Two-Play deleted the feature/server-tasks branch October 24, 2026 14:23
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

Successfully merging this pull request may close these issues.

1 participant