redis / redis/redis-om-python

Add warning when pending migrations exist

Open
#775 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
Python
Stars
1.3k
Forks
128
PR merge metrics
No merged PRs in 30d

Description

Summary

Add a warning message when there are pending migrations that haven't been applied.

Current Behavior

om migrate status shows pending count but there's no proactive warning when using other commands or at startup.

Proposed Behavior

  1. CLI Warning: When running om migrate status, show a colored warning if migrations are pending:

    ⚠️  Warning: 3 pending migrations not applied. Run 'om migrate run' to apply.
    
  2. Optional startup warning (stretch goal): Add a function that applications can call to check migration status and log a warning if behind.

Implementation Notes

  • Update status command output to highlight pending migrations
  • Consider adding --check flag that exits non-zero if behind (useful for CI)

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the om migrate status command and inspect how it reports the pending migration count. The core work is done when pending migrations produce a colored warning with the count and suggested command; the optional startup check and --check flag are additional scope to clarify before implementation.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
cli, database
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.