@gentbajko/slopify 4.5.6 → 4.5.8

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.
@@ -53,6 +53,11 @@ function reviews(req) {
53
53
  // The binary's image tool (`ImagegenArgs`: prompt, referenced_image_paths,
54
54
  // num_last_images_to_include) takes each referenced image as an absolute path it reads
55
55
  // itself, so the copy sits in the job's own folder - the sandbox's writable, readable root.
56
+ // Codex's per-minute limit ("429 Too Many Requests"), not the plan's usage limit
57
+ // (`codexPlanLimit`): quota is left, so the step waits and draws again (`retry-policy.ts`).
58
+ function throttled(message) {
59
+ return /\b429\b|too many requests|rate.?limit/i.test(message);
60
+ }
56
61
  export function codexReferencePath(directory, image) {
57
62
  return join(directory, image.mime === "image/jpeg" ? "reference.jpg" : "reference.png");
58
63
  }
@@ -297,6 +302,11 @@ export function codexImage(deps) {
297
302
  const planLimit = codexPlanLimit(message, new Date());
298
303
  if (planLimit !== undefined)
299
304
  throw codexLimitError(message, planLimit);
305
+ if (throttled(message))
306
+ throw providerError({
307
+ kind: "rate_limit",
308
+ message: cliReported(binary, redact(message), imageNext),
309
+ });
300
310
  throw providerError({
301
311
  kind: /refus|content.policy|safety/i.test(message) ? "refusal" : "other",
302
312
  message: /refus|content.policy|safety/i.test(message)
@@ -313,6 +323,11 @@ export function codexImage(deps) {
313
323
  const planLimit = codexPlanLimit(message, new Date());
314
324
  if (planLimit !== undefined)
315
325
  throw codexLimitError(message, planLimit);
326
+ if (throttled(message))
327
+ throw providerError({
328
+ kind: "rate_limit",
329
+ message: cliReported(binary, redact(message), imageNext),
330
+ });
316
331
  throw providerError({
317
332
  kind: /image.generation|image tool|feature.*unavailable/i.test(message)
318
333
  ? "unsupported"
@@ -0,0 +1,11 @@
1
+ # Slopify 4.5.7
2
+
3
+ Released 1 December 2026.
4
+
5
+ A picture Codex turns away for drawing too fast now waits and is drawn again, instead of failing.
6
+
7
+ ## Codex's "Too Many Requests" waits instead of failing
8
+
9
+ - **A picture Codex refuses with "429 Too Many Requests" now waits and tries again.** Codex answers this when pictures are asked for faster than its per-minute limit allows, even with plenty of your plan left. Slopify took it for an ordinary failure, so each picture used up its few attempts within seconds and the step failed, often a short's pictures while two videos were drawing at once. It now waits about 2, 4, 8 and 16 minutes, as for any rate limit, and the step only fails if Codex is still refusing after half an hour.
10
+ - Codex's plan usage limit ("You've hit your usage limit") is unchanged: it still says when the plan resets.
11
+ - Technical: `adapters/image/codex.ts` throws `kind: "rate_limit"` for a `turn.failed` or `error` event whose message matches `429`, `too many requests` or `rate limit` (after the plan-limit check), so `autoRetryDelay` (`kernel/runner/retry-policy.ts`) puts the step back to wait.
@@ -0,0 +1,10 @@
1
+ # Slopify 4.5.8
2
+
3
+ Released 1 December 2026.
4
+
5
+ A schedule's video no longer reads Failed after a restart because a step was running at that moment.
6
+
7
+ ## A step a restart interrupted goes on by itself
8
+
9
+ - **A schedule's video no longer reads Failed after a restart.** A step that was running when Slopify stopped is marked failed, "interrupted", and Slopify 4.5.6 only continued runs a restart had stopped, not these. A video made ahead, or one its day already took, then read Failed until someone pressed Try again. Now, a minute after Slopify starts, such a video goes on like any other a restart stopped, with the same limits: a project you paused stays paused, a checkpoint of yours still waits for you, and a step that failed for a reason of its own still waits for Try again.
10
+ - Technical: `continueStopped` (`schedules/continue-stopped.ts`) also takes a project whose failed stages all have `failure_reason='interrupted'` (`markInterruptedStages`, `main.ts`), including one `projectIsActive` reads as failed, and continues it with `continueHeldRun`.
@@ -1,4 +1,16 @@
1
1
  [
2
+ {
3
+ "id": "4.5.8",
4
+ "title": "Slopify 4.5.8",
5
+ "version": "4.5.8",
6
+ "date": "2026-12-01"
7
+ },
8
+ {
9
+ "id": "4.5.7",
10
+ "title": "Slopify 4.5.7",
11
+ "version": "4.5.7",
12
+ "date": "2026-12-01"
13
+ },
2
14
  {
3
15
  "id": "4.5.6",
4
16
  "title": "Slopify 4.5.6",
@@ -14,7 +14,21 @@ function scheduledProjects(db) {
14
14
  WHERE r.projects_settled_at IS NULL AND r.status!='running'`)
15
15
  .all()
16
16
  .map((row) => z.string().parse(row.id));
17
- return [...new Set(ids)].filter((id) => projectIsActive(db, id));
17
+ return [...new Set(ids)].filter(
18
+ // A run failed only by the restart reads Failed, so is no active project; it counts here.
19
+ (id) => projectIsActive(db, id) ||
20
+ (interruptedOnly(db, id) &&
21
+ db.prepare("SELECT 1 FROM project_trash WHERE project_id=?").get(id) === undefined));
22
+ }
23
+ // A step running when Slopify stopped reads failed, "interrupted" (`markInterruptedStages` in
24
+ // `main.ts`), with its work held like any other a restart stopped. A run failed only that way
25
+ // goes on too; one with a failure of its own waits for Try again.
26
+ function interruptedOnly(db, projectId) {
27
+ const reasons = db
28
+ .prepare("SELECT failure_reason AS reason FROM stages WHERE project_id=? AND state='failed'")
29
+ .all(projectId)
30
+ .map((row) => row.reason);
31
+ return reasons.length > 0 && reasons.every((reason) => reason === "interrupted");
18
32
  }
19
33
  // A restart stops every run that was going (`recoverWork`), and a schedule's videos then read
20
34
  // Stopped until someone presses Continue the run: a made-ahead video until its day, and one its
@@ -28,7 +42,8 @@ export async function continueStopped(deps) {
28
42
  return [];
29
43
  const continued = [];
30
44
  for (const projectId of scheduledProjects(deps.db)) {
31
- if (!projectHolds(deps.db, { projectId }).stopped.has(projectId))
45
+ if (!projectHolds(deps.db, { projectId }).stopped.has(projectId) &&
46
+ !interruptedOnly(deps.db, projectId))
32
47
  continue;
33
48
  try {
34
49
  const outcome = await continueRun(projectId);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gentbajko/slopify",
3
- "version": "4.5.6",
3
+ "version": "4.5.8",
4
4
  "description": "Turn a prompt into a finished video, locally, with your own provider keys",
5
5
  "license": "Apache-2.0",
6
6
  "author": "Gent Bajko",