Skip to main content

Upgrading

UPGRADE.md in the repository is the canonical upgrade guide. The 0.3.x → 0.4.0 steps (new migrations, removed config keys, removed source drivers, and the now-immutable published rows) and everything after them live there in full.

The note below covers the earlier, backward-compatible bump.

0.2.x → 0.3.0

Backward-compatible: existing code, config, and ledger rows keep working. Run the migrations and you are done.

php artisan migrate

What the migrations do

  • Add the notice-model columns to legal_documents (notice_mode, change_class, regime, notice_period_days, offers_termination, keeps_unmodified_offered, objection_deadline, objection_closed_at). Existing versions are backfilled: one that required re-consent becomes ActiveReconsent, one that did not becomes SilentEditorial — the behavior they already had.
  • Create the append-only legal_notices delivery-proof table.
  • Drop the legal_consents.document_id foreign key (PostgreSQL and MySQL only). Its ON DELETE SET NULL fought the append-only guarantee: deleting a superseded legal_documents row aborted on PostgreSQL and silently rewrote a ledger row on MySQL. The column and the document() relation stay; the relation resolves to null once the document is gone. Present since 0.1.0 — this is a fix, and nothing you must act on.

Then, optionally

  • --material still works; it is now an alias of --active. New publishes can classify more precisely with --info, --deemed, or --editorial. See The four notice modes.
  • legal-consent:close-objection-windows is auto-scheduled (disable via schedule.close_objection_windows). It only does anything once you publish a --deemed change.
  • requires_explicit_optin was removed from the published config's documents entries. It was never read — the value is derived from legal_basis. Delete it from your published config if you like; leaving it is harmless.
  • New: schedule.prune (default false). Nothing changes for you on upgrade — but if you assumed retention_after_end was already deleting anything, it was not, and this is the switch that makes it true. See Retention.

Release history

The full changelog is CHANGELOG.md in the repository.