👷 build(database): add topic status and tasks automation mode#13994
Merged
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #13994 +/- ##
==========================================
- Coverage 66.78% 66.78% -0.01%
==========================================
Files 2044 2044
Lines 174052 174052
Branches 17146 21223 +4077
==========================================
- Hits 116249 116247 -2
- Misses 57679 57681 +2
Partials 124 124
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
automation_mode columna63f5b8 to
4ce2a9c
Compare
4ce2a9c to
c0db57e
Compare
2225c08 to
02b8b12
Compare
- topics: add \`status\` (active/completed/archived) and \`completed_at\`
- tasks: add \`automation_mode\` ('heartbeat' | 'schedule' | null) to make the heartbeat vs schedule distinction explicit
- tasks: drop default on \`heartbeat_interval\` so null cleanly marks "no heartbeat configured" now that automation_mode is the discriminator
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Aligns with canary (#13979): vi.resetModules + dynamic import re-parses antd + @lobehub/ui on every test, which can blow past the default 5s timeout on cold CI runs. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
3c175ee to
cae218a
Compare
tjx666
approved these changes
Apr 20, 2026
nekomeowww
approved these changes
Apr 20, 2026
4 tasks
mrsimpson
added a commit
to mrsimpson/lobehub
that referenced
this pull request
May 8, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This release ships a database schema migration that makes two pieces of lifecycle state explicit: how a topic finishes, and how a task is automated. Both already existed implicitly, which made some downstream behaviors ambiguous. This change turns them into first-class columns so the UI, scheduler, and reporting layers can rely on them directly.
Migration overview
Previously, a topic's completion was inferred from surrounding context — there was no dedicated status or timestamp marking when a topic moved out of the active pool. Tasks had a similar ambiguity around automation: heartbeat supervision and cron-style scheduling lived in overlapping fields, so a configured-but-paused schedule looked identical to one that was never set.
This migration makes both states explicit.
topics
status(active|completed|archived)completed_attimestampstatusand(user_id, completed_at)so completion views and archival queries stay cheaptasks
automation_mode(heartbeat|schedule|null) — a single discriminator that makes the two automation kinds mutually exclusive by design and removes the "configured but disabled" ambiguityautomation_modeIn practice, the topic list can now distinguish completed and archived records without reinterpreting other fields, and the task scheduler gets a clean switch to route records between heartbeat supervision and cron execution.
Notes for self-hosted users
The migration owner: @arvinxx — responsible for this database schema change, reach out for any migration-related issues.