@gentbajko/slopify 3.13.1 → 3.13.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/edge/http/projects.js +6 -3
- package/dist/extension/slopify-studio-chrome.zip +0 -0
- package/dist/extension/slopify-studio-firefox.zip +0 -0
- package/dist/patch-notes/3.13.2.md +5 -0
- package/dist/patch-notes/index.json +6 -0
- package/dist/slices/uploads/repo.js +11 -0
- package/package.json +1 -1
|
@@ -17,7 +17,7 @@ import { limitWaitsByProject, listingWait } from "../../slices/run-cost/panel.js
|
|
|
17
17
|
import { outputsOf } from "../../slices/storage/repo.js";
|
|
18
18
|
import { longVideoStats } from "../../slices/studio/stats.js";
|
|
19
19
|
import { trashProject } from "../../slices/trash/service.js";
|
|
20
|
-
import { setAsideProjects, uploadedProjects } from "../../slices/uploads/repo.js";
|
|
20
|
+
import { setAsideProjects, uploadedAndSettled, uploadedProjects, } from "../../slices/uploads/repo.js";
|
|
21
21
|
import { onInvalid, problem, titleOf } from "./problem.js";
|
|
22
22
|
import { createProject } from "./project-create.js";
|
|
23
23
|
const idParam = z.object({
|
|
@@ -37,9 +37,11 @@ export function projectRoutes(deps) {
|
|
|
37
37
|
log: deps.log,
|
|
38
38
|
hasInflight: deps.runner.hasInflight,
|
|
39
39
|
};
|
|
40
|
+
// An uploaded project with nothing admitted reads as done (`uploadedAndSettled`).
|
|
41
|
+
const statusOf = (status, settled) => settled && (status === "paused" || status === "pending") ? "done" : status;
|
|
40
42
|
const summarise = (project) => ({
|
|
41
43
|
...project,
|
|
42
|
-
status: derive(stagesOf(deps.db, project.id), project.paused),
|
|
44
|
+
status: statusOf(derive(stagesOf(deps.db, project.id), project.paused), uploadedAndSettled(deps.db).has(project.id)),
|
|
43
45
|
});
|
|
44
46
|
return (new Hono()
|
|
45
47
|
.post("/", zValidator("json", runDraftSchema, onInvalid), async (c) => {
|
|
@@ -65,6 +67,7 @@ export function projectRoutes(deps) {
|
|
|
65
67
|
const channels = projectChannels(deps.db);
|
|
66
68
|
const uploads = uploadedProjects(deps.db);
|
|
67
69
|
const aside = setAsideProjects(deps.db);
|
|
70
|
+
const settled = uploadedAndSettled(deps.db);
|
|
68
71
|
const numbers = longVideoStats(deps.db);
|
|
69
72
|
const waits = limitWaitsByProject(deps.db);
|
|
70
73
|
const projects = listProjectHeads(deps.db).map((project) => {
|
|
@@ -72,7 +75,7 @@ export function projectRoutes(deps) {
|
|
|
72
75
|
const waiting = waits.get(project.id);
|
|
73
76
|
return {
|
|
74
77
|
...project,
|
|
75
|
-
status: derive(stages, project.paused),
|
|
78
|
+
status: statusOf(derive(stages, project.paused), settled.has(project.id)),
|
|
76
79
|
progress: progressOf(stages),
|
|
77
80
|
channelId: channels.get(project.id) ?? defaultChannelId,
|
|
78
81
|
uploadedAt: uploads.get(project.id) ?? null,
|
|
Binary file
|
|
Binary file
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
# Slopify 3.13.2
|
|
2
|
+
|
|
3
|
+
Released 8 October 2026.
|
|
4
|
+
|
|
5
|
+
- **Uploaded videos no longer show as Paused.** A project you uploaded that was paused, or had a leftover step from an edit after the upload, showed as Paused or Waiting in the project list and on its page. An uploaded project with nothing queued to run now shows as Done. A remake you start on an uploaded video still shows as running until it finishes.
|
|
@@ -18,6 +18,17 @@ export function uploadedProjects(db) {
|
|
|
18
18
|
.all()
|
|
19
19
|
.map((row) => [String(row.project_id), String(row.uploaded_at)]));
|
|
20
20
|
}
|
|
21
|
+
// Uploaded projects with nothing admitted still to run: their leftover steps (a placeholder
|
|
22
|
+
// from an edit after the upload, a pause from a bulk Pause) are not work the person is
|
|
23
|
+
// waiting for, so the listing calls them done rather than "Paused" or "Waiting".
|
|
24
|
+
export function uploadedAndSettled(db) {
|
|
25
|
+
return new Set(db
|
|
26
|
+
.prepare(`SELECT u.project_id FROM project_uploads u WHERE NOT EXISTS(
|
|
27
|
+
SELECT 1 FROM revision_work w WHERE w.project_id=u.project_id
|
|
28
|
+
AND w.state IN ('pending','running') AND w.dispatch_state!='held')`)
|
|
29
|
+
.all()
|
|
30
|
+
.map((row) => String(row.project_id)));
|
|
31
|
+
}
|
|
21
32
|
// "Keep as is": a waiting run the person leaves as it is, until the project's next edit. Set on
|
|
22
33
|
// the current head revision; the listing counts it only while that revision is still the head.
|
|
23
34
|
export function setAside(db, projectId, aside, at) {
|