[OPIK-7159][OPIK-7029] [BE][FE][SDK] revert: back out premature merge of #7428#7509
Closed
awkoy wants to merge 2 commits into
Closed
[OPIK-7159][OPIK-7029] [BE][FE][SDK] revert: back out premature merge of #7428#7509awkoy wants to merge 2 commits into
awkoy wants to merge 2 commits into
Conversation
Contributor
⏱️ pre-commit per-hook timing
⏭️ 19 skipped (no matching files changed)
|
A revert of a migration-bearing PR deletes the .sql file; without a diff filter the checker treated the deletion as a new migration and flagged it as conflicting with its own still-present prefix on main. Only ADDED files are new migrations. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Comment on lines
27
to
+29
| get_new_migrations() { | ||
| local dir=$1 | ||
| git diff --name-only origin/main...HEAD -- "$dir" | grep '\.sql$' || true | ||
| git diff --name-only --diff-filter=A origin/main...HEAD -- "$dir" | grep '\.sql$' || true |
Contributor
There was a problem hiding this comment.
get_new_migrations() uses --diff-filter=A, so renamed/copied .sql migrations never reach NEW_MIGRATIONS and the prefix-conflict check is bypassed — should we include R/C statuses or explicitly fail renames as unsupported?
Want Baz to fix this for you? Activate Fixer
Other fix methods
Prompt for AI Agents
In scripts/check_backend_migration_conflicts.sh around lines 27-29, inside
get_new_migrations(), the git diff uses --diff-filter=A and only returns added files,
ignoring renamed/copied migrations reported as R/C by git, so the prefix/conflict loop
at lines 75-86 can be bypassed entirely. Refactor get_new_migrations to either: (a)
include renamed/copied .sql destination paths in NEW_MIGRATIONS by adding R and C to the
diff-filter (e.g., --diff-filter=ACR), ensuring the existing prefix-conflict logic runs
for these cases, or (b) explicitly detect R/C statuses and fail the job with a clear
message that migration renames/copies are not allowed. Use a diff mode that preserves
rename/copy information (e.g., --name-status or an appropriate --diff-filter) and ensure
.sql files are still filtered correctly in both cases.
Contributor
Author
|
Closing in favor of fixing forward. The feature stays on main; @thiagohora's post-merge review feedback is addressed in a focused follow-up PR #7512 (scope the update lock to metadata writes so status writes are Redis-independent; make the reaper lookback margin configurable). No revert needed. |
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.
Details
Reverts #7428 (squash commit
02df18a), which was merged before full sign-off (a single approval;@thiagohora's review was still comments-only).This is a pure revert of the application changes plus one CI fix required to make the revert itself pass:
scripts/check_backend_migration_conflicts.sh: add--diff-filter=Aso the migration-prefix checker only treats added.sqlfiles as new migrations. Without it, reverting any migration-bearing PR fails the check, because the deleted migration is reported as changed and then flagged as conflicting with its own still-present prefix onmain.The feature branch
awkoy/opik-7159-stuck-init-reaperis preserved intact so the work can be re-landed via a fresh PR once review is complete.Change checklist
02df18a)Issues
Resolves the premature merge of OPIK-7159 / OPIK-7029.
Testing
scripts/check_backend_migration_conflicts.shlocally on this branch → "no conflicts detected".git revertof the squash commit; CI re-runs the full suite that was green on [OPIK-7159][OPIK-7029] feat: recover stuck optimization runs + surface run errors #7428.Documentation
No documentation changes; this is a revert.