Commit graph

4 commits

Author SHA1 Message Date
fd4823ee7f feat(cleanup): remove the uploads size cap
All checks were successful
CI / unit (pull_request) Successful in 50s
CI / backend-e2e (pull_request) Successful in 2m5s
CI / dashboard-e2e (pull_request) Successful in 2m44s
The uploads size cap trimmed source uploads once UPLOAD_DIR crossed
UPLOADS_MAX_GB (default 15 GB), so a burst of long sources got purged
mid-window ("Uploads at 28.3 GB (cap 15 GB) — trimming"). Drop the cap
entirely: the function, the UPLOADS_MAX_GB env knob, its call in the
cleanup task and the scope test.

Sources are still bounded by the age-based _sweep_expired_uploads sweep
(they age out with JOB_RETENTION_SECONDS), and the OUTPUT_MAX_GB cap is
untouched.
2026-10-11 21:53:01 +01:00
719946b3cd refactor/package-layout (#3)
All checks were successful
CI / backend-tests (push) Successful in 29s
CI / frontend-build (push) Successful in 9m48s
Reviewed-on: #3
Co-authored-by: pedro-bento <mail@pbento.pt>
Co-committed-by: pedro-bento <mail@pbento.pt>
2026-10-04 20:47:12 +01:00
edcfeaf9d5 refactor: remove cloud/ billing mode and flatten to self-hosted-only
- Delete the entire cloud/ package (Stripe billing, auth/OAuth, metering, API keys,
  account erasure, lifecycle/digest emails, R2 archive, autopilot, MCP OAuth,
  proxy ledger, managed keys) and all BILLING_ENABLED branches in app.py
- Keep self-host behavior via no-op shims; /api/config now returns
  {youtubeUrlEnabled, jobRetentionSeconds, localLlm}
- Remove cloud tests (31 files), alembic/, log_view.py, requirements-billing.txt,
  docker-compose.cloud.yml; update CLI to Postiz + /api/config; clean docs/skills
- Flatten dashboard: remove auth/billing/pricing/history chrome, inert config-only AuthContext
- Fix residual test drift; lint + build + compile all green
2026-10-04 17:02:55 +01:00
victorcavero14
ea789999e8 fix(cleanup): never sweep a job that is still queued or running
The hourly sweep deleted job dirs and source uploads by age alone. With the
queue backed up (22-sep-2026) free jobs waited over an hour, so their dir
was removed under the worker: no clips, and the minute reservation stayed
held until the 3 h stuck sweep. 21 free users lost their job that way today,
most of them on their first run.

- _job_is_active(): running here, queued/processing in memory, or a fresh
  resume manifest (the other instance's jobs during a handover). Manifests
  pin a dir for at most ACTIVE_JOB_MAX_SECONDS (24 h).
- The age sweeps and both size caps skip active jobs and their sources.
- run_job_wrapper settles the reservation from the job record it started
  with, so a vanished entry releases the minutes instead of holding them.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-22 20:21:14 +02:00