Skip to content

Conversation

@suztomo
Copy link
Member

@suztomo suztomo commented Oct 20, 2025

The message packages hosts the data types that are common across
the CLI and language container implementations.
ReleaseInitRequest and ReleaseInitResponse are example data types
that belong to the package.

The request and response types are the argument and return type
of the upcoming ReleaseInit function implementation.

It was originally "request" package in google-cloud-go. However,
because it also includes responses from the language container to
the CLI, I'm renaming it to "messages".

…uest

The message packages hosts the data types that are common across
the CLI and language container implementations.
ReleaseInitRequest and ReleaseInitResponse are example data types
that belong to the package.

The request and response types are the argument and return type
of the upcoming ReleaseInit function implementation.

It was originally "request" package in google-cloud-go. However,
because it also includes responses from the language container to
the CLI, I'm renaming it to "messages".
@product-auto-label product-auto-label bot added the size: s Pull request size is small. label Oct 20, 2025
@gemini-code-assist
Copy link
Contributor

Summary of Changes

Hello @suztomo, 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 refactors the core data types used for inter-process communication within the librariangen tool. By renaming the request package to message, the change clarifies that this package will house common data structures for both incoming requests and outgoing responses. It also lays the groundwork for future functionality by introducing specific request and response types for release initialization, centralizing these communication contracts.

Highlights

  • Package Renaming: The request package has been renamed to message to better reflect its role in handling both requests and responses between the CLI and language container implementations.
  • New Data Types: Introduced ReleaseInitRequest and ReleaseInitResponse structs within the new message package, which are intended for an upcoming ReleaseInit function.
  • Code Refactoring: Updated generator.go to import and utilize the newly named message package and its types, ensuring consistency with the refactored data structures.
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.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  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.

@suztomo suztomo requested a review from meltsufin October 20, 2025 21:33
@codecov
Copy link

codecov bot commented Oct 20, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 88.37%. Comparing base (2f6c75d) to head (3071d07).
⚠️ Report is 2 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #3958   +/-   ##
=======================================
  Coverage   88.37%   88.37%           
=======================================
  Files           6        6           
  Lines         370      370           
=======================================
  Hits          327      327           
  Misses         30       30           
  Partials       13       13           
Flag Coverage Δ
librariangen 88.37% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request refactors the request package into a new message package and introduces the ReleaseInitRequest and ReleaseInitResponse data types. The changes are well-structured and clear. My feedback includes suggestions to improve the documentation for the newly added types and a recommendation to include unit tests to ensure their correctness, particularly for JSON serialization.

Comment on lines 29 to 37
// Request is the structure of the release-init-request.json file.
type ReleaseInitRequest struct {
Libraries []*Library `json:"libraries"`
}

// Response is the structure of the release-init-response.json file.
type ReleaseInitResponse struct {
Error string `json:"error,omitempty"`
}
Copy link
Contributor

Choose a reason for hiding this comment

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

medium

It's a good practice to add unit tests for new data structures, especially for JSON serialization and deserialization, to verify the json tags and prevent future regressions. Consider adding tests for ReleaseInitRequest and ReleaseInitResponse in message_test.go.

suztomo and others added 2 commits October 20, 2025 17:35
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
@suztomo
Copy link
Member Author

suztomo commented Oct 20, 2025

Many checks didn't run. Closing/reopening this.

@suztomo suztomo closed this Oct 20, 2025
@suztomo suztomo reopened this Oct 20, 2025
@sonarqubecloud
Copy link

@sonarqubecloud
Copy link

Quality Gate Passed Quality Gate passed for 'java_showcase_integration_tests'

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
0.0% Coverage on New Code
0.0% Duplication on New Code

See analysis details on SonarQube Cloud

@suztomo suztomo merged commit f22935d into main Oct 21, 2025
49 checks passed
@suztomo suztomo deleted the release-init-stub branch October 21, 2025 01:58
meltsufin added a commit that referenced this pull request Oct 24, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size: s Pull request size is small.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants