Merged progress from Dev to Main #4

Merged
N0tAI merged 23 commits from dev into main 2026-03-19 18:44:10 +00:00
N0tAI commented 2026-03-19 18:44:01 +00:00 (Migrated from github.com)
No description provided.
gemini-code-assist[bot] commented 2026-03-19 18:47:26 +00:00 (Migrated from github.com)

Summary of Changes

Hello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request merges the progress from the 'Dev' branch to 'Main', which includes a significant restructuring of the project, implementation of a new data layer with Entity Framework Core and PostgreSQL, updates to the API layer, and the addition of unit tests. These changes collectively aim to improve the project's architecture, maintainability, and testability.

Highlights

  • Project Restructuring: The project was restructured to improve maintainability and scalability, which involved renaming several projects and namespaces.
  • Data Layer Implementation: Implemented a new data layer using Entity Framework Core with PostgreSQL, including models, context, and repositories.
  • API Layer Updates: Updated the API layer to use the new data layer, including renaming namespaces and project files.
  • Added Unit Tests: Added a unit test project with a basic integration test to ensure the API is functioning correctly.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here.


  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution. ↩︎

## Summary of Changes Hello, I'm Gemini Code Assist[^1]! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request merges the progress from the 'Dev' branch to 'Main', which includes a significant restructuring of the project, implementation of a new data layer with Entity Framework Core and PostgreSQL, updates to the API layer, and the addition of unit tests. These changes collectively aim to improve the project's architecture, maintainability, and testability. ### Highlights * **Project Restructuring**: The project was restructured to improve maintainability and scalability, which involved renaming several projects and namespaces. * **Data Layer Implementation**: Implemented a new data layer using Entity Framework Core with PostgreSQL, including models, context, and repositories. * **API Layer Updates**: Updated the API layer to use the new data layer, including renaming namespaces and project files. * **Added Unit Tests**: Added a unit test project with a basic integration test to ensure the API is functioning correctly. <details> <summary><b>Using Gemini Code Assist</b></summary> <br> The full guide for Gemini Code Assist can be found on our [documentation page](https://developers.google.com/gemini-code-assist/docs/review-github-code), here are some quick tips. <b>Invoking Gemini</b> You can request assistance from Gemini at any point by creating a comment using either `/gemini <command>` or `@gemini-code-assist <command>`. Below is a summary of the supported commands on the current page. Feature | Command | Description --- | --- | --- Code Review | `/gemini review` | Performs a code review for the current pull request in its current state. Pull Request Summary | `/gemini summary` | Provides a summary of the current pull request in its current state. Comment | @gemini-code-assist | Responds in comments when explicitly tagged, both in pull request comments and review comments. Help | `/gemini help` | Displays a list of available commands. <b>Customization</b> To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a `.gemini/` folder in the base of the repository. Detailed instructions can be found [here](https://developers.google.com/gemini-code-assist/docs/customize-gemini-behavior-github). <b>Limitations & Feedback</b> Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with :thumbsup: and :thumbsdown: on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up [here](https://google.qualtrics.com/jfe/form/SV_2cyuGuTWsEw84yG). </details> [^1]: Review the [Privacy Notices](https://policies.google.com/privacy), [Generative AI Prohibited Use Policy](https://policies.google.com/terms/generative-ai/use-policy), [Terms of Service](https://policies.google.com/terms), and learn how to configure Gemini Code Assist in GitHub [here](https://developers.google.com/gemini-code-assist/docs/customize-gemini-behavior-github). Gemini can make mistakes, so double check it and [use code with caution](https://support.google.com/legal/answer/13505487).
gemini-code-assist[bot] (Migrated from github.com) reviewed 2026-03-19 18:49:25 +00:00
gemini-code-assist[bot] (Migrated from github.com) left a comment

Code Review

The pull request involves a significant refactoring of the project structure, renaming Thayen.WebPlanner.API to Planner.Api and Thayen.WebPlanner.Data to Planner.Data, and introducing a new Planner.Tests project. The data layer has been completely overhauled to use Entity Framework Core with a custom IdType struct for GUIDs, implementing a generic CRUD repository and Unit of Work pattern, and including new PostgreSQL setup scripts. The API project's Program.cs was streamlined, and comprehensive .gitignore files were added to both Planner.Api and Planner.Data. Review comments highlight a critical bug in CrudRepository.DeleteByIdAsync where _dbSet.FindAsync is incorrectly used with an IEnumerable<IdType>, which needs to be corrected to properly handle multiple IDs or use RemoveRange. Additionally, an integration test in Planner.Tests attempts to call a non-existent /ping endpoint, indicating a test failure or a missing API endpoint.

## Code Review The pull request involves a significant refactoring of the project structure, renaming `Thayen.WebPlanner.API` to `Planner.Api` and `Thayen.WebPlanner.Data` to `Planner.Data`, and introducing a new `Planner.Tests` project. The data layer has been completely overhauled to use Entity Framework Core with a custom `IdType` struct for GUIDs, implementing a generic CRUD repository and Unit of Work pattern, and including new PostgreSQL setup scripts. The API project's `Program.cs` was streamlined, and comprehensive `.gitignore` files were added to both `Planner.Api` and `Planner.Data`. Review comments highlight a critical bug in `CrudRepository.DeleteByIdAsync` where `_dbSet.FindAsync` is incorrectly used with an `IEnumerable<IdType>`, which needs to be corrected to properly handle multiple IDs or use `RemoveRange`. Additionally, an integration test in `Planner.Tests` attempts to call a non-existent `/ping` endpoint, indicating a test failure or a missing API endpoint.
@ -0,0 +45,4 @@
}
public async Task<bool> DeleteByIdAsync(IEnumerable<IdType> ids)
{
gemini-code-assist[bot] (Migrated from github.com) commented 2026-03-19 18:49:26 +00:00

high

The DeleteByIdAsync method uses _dbSet.FindAsync(ids). FindAsync is designed to find an entity by its primary key values, which typically means a single key value or an array of key components for composite keys. Passing an IEnumerable<IdType> directly to FindAsync is incorrect and will likely result in a runtime error or unexpected behavior. If the intention is to delete multiple entities by their IDs, you should iterate through the ids and find/remove each entity, or use a Where clause followed by ExecuteDeleteAsync() for bulk deletion.

    public async Task<bool> DeleteByIdAsync(IEnumerable<IdType> ids)
    {
        var entitiesToDelete = await _dbSet.Where(e => ids.Contains((IdType)e.Id!)).ToListAsync();
        if (entitiesToDelete.Any())
        {
            _dbSet.RemoveRange(entitiesToDelete);
            return true;
        }
        return false;
    }
![high](https://www.gstatic.com/codereviewagent/high-priority.svg) The `DeleteByIdAsync` method uses `_dbSet.FindAsync(ids)`. `FindAsync` is designed to find an entity by its primary key values, which typically means a single key value or an array of key components for composite keys. Passing an `IEnumerable<IdType>` directly to `FindAsync` is incorrect and will likely result in a runtime error or unexpected behavior. If the intention is to delete multiple entities by their IDs, you should iterate through the `ids` and find/remove each entity, or use a `Where` clause followed by `ExecuteDeleteAsync()` for bulk deletion. ```c# public async Task<bool> DeleteByIdAsync(IEnumerable<IdType> ids) { var entitiesToDelete = await _dbSet.Where(e => ids.Contains((IdType)e.Id!)).ToListAsync(); if (entitiesToDelete.Any()) { _dbSet.RemoveRange(entitiesToDelete); return true; } return false; } ```
@ -0,0 +10,4 @@
{
var client = WebApplicationFactory.CreateClient();
var response = await client.GetAsync("/ping");
gemini-code-assist[bot] (Migrated from github.com) commented 2026-03-19 18:49:26 +00:00

high

The integration test attempts to access a /ping endpoint. However, there is no /ping endpoint defined in the Planner.Api project's Program.cs or any visible controller. This test will likely fail. Please ensure that the /ping endpoint is correctly implemented in the API or adjust the test to target an existing endpoint.

![high](https://www.gstatic.com/codereviewagent/high-priority.svg) The integration test attempts to access a `/ping` endpoint. However, there is no `/ping` endpoint defined in the `Planner.Api` project's `Program.cs` or any visible controller. This test will likely fail. Please ensure that the `/ping` endpoint is correctly implemented in the API or adjust the test to target an existing endpoint.
Sign in to join this conversation.
No description provided.