Skip to content

test: enable repository-returning test - #11913

Merged
gioboa merged 3 commits into
typeorm:v0.3from
gioboa:test/enable-returning-test
Jan 13, 2026
Merged

gioboa merged 3 commits into
typeorm:v0.3from
gioboa:test/enable-returning-test

Conversation

@gioboa

@gioboa gioboa commented Jan 11, 2026 •

Copy link
Copy Markdown
Collaborator

This PR enables repository-returning test by renaming the related file.

@gioboa
gioboa force-pushed the test/enable-returning-test branch from 51c99d4 to 407d703 Compare January 11, 2026 19:31
@naorpeled naorpeled self-assigned this Jan 11, 2026
@gioboa
gioboa force-pushed the test/enable-returning-test branch from 407d703 to debf9c6 Compare January 13, 2026 08:36
@gioboa
gioboa marked this pull request as ready for review January 13, 2026 10:58
@qodo-free-for-open-source-projects

Copy link
Copy Markdown

PR Reviewer Guide 🔍

Here are some key observations to aid the review process:

⏱️ Estimated effort to review: 2 🔵🔵⚪⚪⚪
🧪 PR contains tests
🔒 No security concerns identified
⚡ Recommended focus areas for review

Type Mismatch

The id field is declared as number type but decorated with @PrimaryGeneratedColumn("uuid"). UUIDs are strings, not numbers. This type mismatch will likely cause runtime errors or type checking issues.

@PrimaryGeneratedColumn("uuid")
id: number

@qodo-free-for-open-source-projects

qodo-free-for-open-source-projects Bot commented Jan 13, 2026 •

Copy link
Copy Markdown

PR Code Suggestions ✨

Latest suggestions up to b302a46

CategorySuggestion                                                                                                                                    Impact
General
Verify database UUID support

Ensure the database driver supports UUID generation, as support varies across
databases like PostgreSQL, MySQL, and SQLite. Consider adding database-specific
checks or documentation.

test/functional/repository/returning/entity/User.ts [5-6]

 @PrimaryGeneratedColumn("uuid")
 id: string
 
+// Note: UUID generation requires PostgreSQL or a database with UUID support
+
  • Apply / Chat
Suggestion importance[1-10]: 7

__

Why: The suggestion correctly points out a potential cross-database compatibility issue when switching to UUIDs, which is a valid and important consideration for portability and robustness.

Medium
  • More

Previous suggestions

✅ Suggestions up to commit 1d6d92e
CategorySuggestion                                                                                                                                    Impact
Possible issue
✅ Fix type mismatch for UUID
Suggestion Impact:The suggestion was directly implemented. The commit changed the id property type from number to string on line 5-6, exactly as suggested, fixing the type mismatch with the UUID primary key generator.

code diff:

-    id: number
+    id: string

Change the type of the id property from number to string to align with the
@PrimaryGeneratedColumn("uuid") decorator, which generates string UUIDs.

test/functional/repository/returning/entity/User.ts [5-6]

 @PrimaryGeneratedColumn("uuid")
-id: number
+id: string
Suggestion importance[1-10]: 9

__

Why: The suggestion correctly identifies a critical type mismatch where a UUID (string) is assigned to a number property, which would cause a runtime error.

High
✅ Suggestions up to commit 28f047d
CategorySuggestion                                                                                                                                    Impact
Possible issue
✅ Fix type mismatch for UUID column
Suggestion Impact:The suggestion was directly implemented. The commit changed the id property type from number to string on line 5-6, exactly as suggested, fixing the type mismatch with the UUID primary key generator.

code diff:

-    id: number
+    id: string

Change the type of the id property from number to string to match the
@PrimaryGeneratedColumn("uuid") decorator, which generates a string value.

test/functional/repository/returning/entity/User.ts [5-6]

 @PrimaryGeneratedColumn("uuid")
-id: number
+id: string
Suggestion importance[1-10]: 9

__

Why: The suggestion correctly identifies a critical type mismatch where a UUID string from @PrimaryGeneratedColumn("uuid") is assigned to an id property typed as number, preventing a likely runtime error.

High

@gioboa
gioboa force-pushed the test/enable-returning-test branch from 28f047d to 1d6d92e Compare January 13, 2026 11:00
@qodo-free-for-open-source-projects

Copy link
Copy Markdown

Persistent review updated to latest commit 28f047d

@qodo-free-for-open-source-projects

Copy link
Copy Markdown

Persistent review updated to latest commit 1d6d92e

@coveralls

coveralls commented Jan 13, 2026 •

Copy link
Copy Markdown

Coverage Status

coverage: 80.765% (+0.004%) from 80.761%
when pulling b302a46 on gioboa:test/enable-returning-test
into 11d9767 on typeorm:v0.3.

@G0maa
G0maa self-requested a review January 13, 2026 11:16
@qodo-free-for-open-source-projects

Copy link
Copy Markdown

Code Review by Qodo (Alpha)

🐞 Bugs (0) 📘 Rule Violations (0) 📎 Requirement Gaps (0) 💡 Suggestions (0)

Grey Divider

Great, No Issues Found!

Qodo reviewed your code and found no material issues that require review

Grey Divider

Qodo Logo

@gioboa
gioboa merged commit de2d34a into typeorm:v0.3 Jan 13, 2026
34 checks passed
gioboa added a commit to gioboa/typeorm that referenced this pull request Jan 13, 2026
gioboa added a commit to gioboa/typeorm that referenced this pull request Jan 13, 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.

6 participants