Skip to content

Conversation

rathovarun1032
Copy link

@rathovarun1032 rathovarun1032 commented Sep 10, 2025

Description

This PR adds the implementation of the CLI utility for Remote Config Rollouts. The operations exposed are:

  1. GetRollout
  2. ListRollouts
  3. DeleteRollout

Scenarios Tested

  1. Unit tests have been written.
  2. Manual E2E tests have been performed for the CLI commands.
  3. The CLI wraps raw API errors into FirebaseError and returns it.
  4. Verify with the --json flag for Get, List and Delete rollouts.

GetRollout and DeleteRollout share similar test cases:

Expectation: The user should pass the rolloutId that is required to be fetched / deleted.

Test cases:

Test Case Description Expectation
i Passing a valid rolloutId Return the specified rollout.
ii Not passing a rolloutId Returns an error about resource being invalid.
iii Passing an incorrect / invalid ID Returns an error about resource being invalid.

ListRollouts

Expectation: The user can optionally pass a filter, page_size and page_token.

Test Case Description Expectation
i Passing none of the filter, page_size and page_token. Return all rollouts
ii Passing a valid filter Return the filtered rollout(s)
iii Passing only a valid page size Return page_size number of rollouts
iv Passing only a page token Return 10 rollouts after the page_token or remaining rollouts (minimum of both)
v Passing page_token and page_size Return page_size number of rollouts starting at page_token
vi Pass a combination of page_token, page_size and filter Return the filtered rollout(s)
vii Pass an incorrect page_token Return an error stating token is invalid
viii Pass an incorrect / invalid filter Return an empty object or no rollouts

Sample Commands

  1. GetRollout

    firebase remoteconfig:rollouts:get <rolloutId>

  2. ListRollouts

    firebase remoteconfig:rollouts:list --filter <optional filter> --page_size <optional page size> --page_token <optional page token>

  3. DeleteRollout

    firebase remoteconfig:rollouts:delete <rolloutId>

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.

Summary of Changes

Hello @rathovarun1032, 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 significantly enhances the Firebase CLI's Remote Config capabilities by adding comprehensive support for managing rollouts. It provides users with new command-line tools to retrieve, view, and remove Remote Config rollouts, streamlining the workflow for A/B testing and phased rollouts directly from their development environment.

Highlights

  • New Remote Config Rollout CLI Commands: Introduced three new CLI commands under remoteconfig:rollouts: get, list, and delete. These commands allow users to manage Remote Config rollouts directly from the command line.
  • Core Logic and CLI Integration: Implemented the underlying logic for fetching, listing, and deleting Remote Config rollouts, along with their integration into the existing CLI command structure. This includes new TypeScript files for each command's functionality and tests.
  • Remote Config Interface Definitions: Updated the Remote Config interfaces to include new types for RemoteConfigRollout, RolloutDefinition, ExperimentVariant, and ListRollouts, ensuring proper data structuring for rollout management.
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 in your pull request via creating an issue comment (i.e. comment on the pull request page) using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands.

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 issue 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.

@rathovarun1032 rathovarun1032 changed the base branch from master to rc-abt-rollouts-cli September 10, 2025 07:17
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 introduces CLI commands for managing Remote Config rollouts, including get, list, and delete operations. The implementation adds new command files, corresponding business logic, and interface definitions.

My review has identified a few areas for improvement:

  • Critical Test Issues: The tests for the new rollout functionalities (delete, get, list) are not correctly stubbing the API client. This is a critical issue as it means the tests are not verifying the intended behavior. I've provided suggestions on how to fix this in each test file.
  • IAM Permissions: The permissions used for the new commands might be placeholders. It's important to verify and use the most narrowly scoped permissions required for these operations.
  • Documentation: Some JSDoc comments have been removed from the interfaces file, which reduces code clarity. It would be beneficial to restore them.

Overall, this is a solid addition of new functionality. Addressing the testing issues is crucial before merging.

@Namyalg Namyalg marked this pull request as draft September 11, 2025 06:45
@rathovarun1032 rathovarun1032 marked this pull request as ready for review September 21, 2025 10:42
@rathovarun1032 rathovarun1032 changed the title [WIP]Rc rollouts implementation Remote Config Rollouts CLI implementation Sep 21, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants