Skip to content

feat: mark whether a project was auto approved or not - #8343

Merged
mergify[bot] merged 4 commits into
mainfrom
boris/dev-1522-add-field-for-whether-a-project-was-auto-or
Nov 17, 2026
Merged

mergify[bot] merged 4 commits into
mainfrom
boris/dev-1522-add-field-for-whether-a-project-was-auto-or

Conversation

@aecsocket

Copy link
Copy Markdown
Contributor

No description provided.

@github-actions

Copy link
Copy Markdown
Contributor

Pull request changelog

App

Added

Changed

Deprecated

Removed

Fixed

Security

Website

Added

Changed

Deprecated

Removed

Fixed

Security

Hosting

Added

Changed

Deprecated

Removed

Fixed

Security

@aecsocket
aecsocket marked this pull request as ready for review November 16, 2026 13:24
@mergify

mergify Bot commented Nov 16, 2026 •

Copy link
Copy Markdown

Queue requested — the merge queue status continues in this comment ↓.

@greptile-apps

greptile-apps Bot commented Nov 16, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerView in GreptileConfidence Score: 4/5

[Medium impact] The change affects how project approval history is stored in the backend.

The spacing requirement must be satisfied before merging; no behavioral defect was found.

Summary

Adds a stored reason for a project's first approval.

  • Project records now say whether a moderator or automatic review approved them.

Reviews (1) · Last reviewed commit: "prepare" · Reviewed by Greptile

Comment on lines +97 to +102
SET status = $1,
approved_because = CASE
WHEN approved IS NULL THEN 'auto'
ELSE approved_because
END,
approved = COALESCE(approved, NOW())

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Added SQL uses tabs

The added SQL lines in try_auto_approve use tabs, but the backend guide requires spaces. This repository requirement must be satisfied before merging. Replace the tabs with spaces and refresh the matching SQLx cache, since changing query whitespace changes its hash.

Context Used: apps/labrinth/AGENTS.md (source)

Prompt To Fix With AI
This is a comment left during a code review.
Path: apps/labrinth/src/routes/v3/projects/mutation.rs
Line: 97-102

Comment:
**Added SQL uses tabs**

The added SQL lines in `try_auto_approve` use tabs, but the backend guide requires spaces. This repository requirement must be satisfied before merging. Replace the tabs with spaces and refresh the matching SQLx cache, since changing query whitespace changes its hash.

**Context Used:** apps/labrinth/AGENTS.md ([source](https://github.com/modrinth/code/blob/main/apps/labrinth/AGENTS.md))

---

For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.

Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we use a mix of tabs and spaces in SQL migrations so it's not worth fixing atp

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fair point—the SQL block follows the surrounding query style, and its mixed indentation alone isn’t worth a review comment. I shouldn’t have framed this as a required fix. Should I remember not to flag mixed indentation in embedded SQL when it matches the local query style?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

add this to memory

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added the rule: “Do not flag mixed tabs and spaces in embedded SQL when the indentation matches the surrounding query style.” View rule

@aecsocket

Copy link
Copy Markdown
Contributor Author

@Mergifyio queue

@mergify

mergify Bot commented Nov 17, 2026 •

Copy link
Copy Markdown

✅ Merged into main as 0d193c5 at 14:16 UTC

Less than a minute in the queue, with no time running CI.

So far

  • ✅ Entered the queue Tue 17 Nov, 14:16 · rule default · triggered by @aecsocket with the @mergifyio queue command
  • ⚡ Direct Merge · Draft PR skipped, base moved only in app
  • ✅ Merged 14:16 · 0d193c5
2 merge conditions met
  • github-review-approved · required by GitHub branch protection
  • any of · required by GitHub branch protection:
    • check-success = Lint and Test
    • check-neutral = Lint and Test
    • check-skipped = Lint and Test

Times in UTC · dashboard · how the merge queue works

@mergify mergify Bot added the queued label Nov 17, 2026
@mergify
mergify Bot merged commit 0d193c5 into main Nov 17, 2026
11 checks passed
@mergify
mergify Bot deleted the boris/dev-1522-add-field-for-whether-a-project-was-auto-or branch November 17, 2026 14:16
@mergify mergify Bot removed the queued label Nov 17, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants