Skip to content

chore: add support for object enums for drizzle#881

Merged
CatchMe2 merged 2 commits intomainfrom
add-support-for-object-enum-in-drizzle
Feb 23, 2026
Merged

chore: add support for object enums for drizzle#881
CatchMe2 merged 2 commits intomainfrom
add-support-for-object-enum-in-drizzle

Conversation

@CatchMe2
Copy link
Copy Markdown
Contributor

@CatchMe2 CatchMe2 commented Feb 23, 2026

Changes

This PR adds missing support for object enums in drizzle utils.

Checklist

  • Apply one of following labels; major, minor, patch or skip-release
  • I've updated the documentation, or no changes were necessary
  • I've updated the tests, or no changes were necessary

AI Assistance Tracking

We're running a metric to understand where AI assists our engineering work. Please select exactly one of the options below:

Mark "Yes" if AI helped in any part of this work, for example: generating code, refactoring, debugging support,
explaining something, reviewing an idea, or suggesting an approach.

  • Yes, AI assisted with this PR
  • No, AI did not assist with this PR

Summary by CodeRabbit

  • New Features

    • Enhanced database utilities with extended support for additional enum column types, improving flexibility and type resolution capabilities.
  • Tests

    • Added comprehensive test coverage for new enum column type scenarios, including validation of data operations and filtering conditions.

@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Feb 23, 2026

Note

.coderabbit.yaml has unrecognized properties

CodeRabbit is using all valid settings from your configuration. Unrecognized properties (listed below) have been ignored and may indicate typos or deprecated fields that can be removed.

⚠️ Parsing warnings (1)
Validation error: Unrecognized key(s) in object: 'tools'
⚙️ Configuration instructions
  • Please see the configuration documentation for more information.
  • You can also validate your configuration using the online YAML validator.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info

Configuration used: Repository: lokalise/coderabbit/.coderabbit.yaml

Review profile: CHILL

Plan: Pro

Disabled knowledge base sources:

  • Jira integration is disabled

You can enable these sources in your CodeRabbit configuration.

📥 Commits

Reviewing files that changed from the base of the PR and between f260426 and 5f71d0d.

📒 Files selected for processing (2)
  • packages/app/drizzle-utils/src/drizzleFullBulkUpdate.test.ts
  • packages/app/drizzle-utils/src/drizzleFullBulkUpdate.ts

Walkthrough

These changes extend bulk update functionality to support a new enum column type (PgEnumObjectColumn) alongside existing enum support, with comprehensive test updates replacing old enum types and tables with new standardized versions.

Changes

Cohort / File(s) Summary
Enum Type Support Extension
packages/app/drizzle-utils/src/drizzleFullBulkUpdate.ts
Added PgEnumObjectColumn import and extended type resolution logic to handle both PgEnumColumn and PgEnumObjectColumn equivalently when computing column type strings.
Test Suite Updates
packages/app/drizzle-utils/src/drizzleFullBulkUpdate.test.ts
Replaced enum types (statusEnumstandardStatusEnum and new objectStatusEnum) and corresponding test tables (test_standard_enum and test_object_enum). Updated all data manipulation, queries, and assertions to reference new tables and enums. Added new test scenario for object enum columns with validation of where conditions using ObjectStatusEnum.ACTIVE.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~12 minutes

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed The title 'chore: add support for object enums for drizzle' clearly describes the main change: adding object enum support to drizzle utilities.
Description check ✅ Passed The description includes all required sections from the template: Changes section explaining the purpose, completed Checklist with appropriate label applied, and AI Assistance Tracking properly marked.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
  • 📝 Generate docstrings (stacked PR)
  • 📝 Generate docstrings (commit on current branch)
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch add-support-for-object-enum-in-drizzle

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown
Collaborator

@CarlosGamero CarlosGamero left a comment

Choose a reason for hiding this comment

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

🚀

@CatchMe2 CatchMe2 merged commit caaa5a1 into main Feb 23, 2026
7 checks passed
@CatchMe2 CatchMe2 deleted the add-support-for-object-enum-in-drizzle branch February 23, 2026 10:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants