Skip to content

Conversation

@jasonz-dfinity
Copy link
Contributor

@jasonz-dfinity jasonz-dfinity commented Jan 8, 2026

The Governance API types are no longer pb, so it shouldn't be called pb_api. This PR is simply s/pb_api/api/.

@jasonz-dfinity jasonz-dfinity requested a review from a team as a code owner January 8, 2026 00:19
Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

This pull request changes code owned by the Governance team. Therefore, make sure that
you have considered the following (for Governance-owned code):

  1. Update unreleased_changelog.md (if there are behavior changes, even if they are
    non-breaking).

  2. Are there BREAKING changes?

  3. Is a data migration needed?

  4. Security review?

How to Satisfy This Automatic Review

  1. Go to the bottom of the pull request page.

  2. Look for where it says this bot is requesting changes.

  3. Click the three dots to the right.

  4. Select "Dismiss review".

  5. In the text entry box, respond to each of the numbered items in the previous
    section, declare one of the following:

  • Done.

  • $REASON_WHY_NO_NEED. E.g. for unreleased_changelog.md, "No
    canister behavior changes.", or for item 2, "Existing APIs
    behave as before.".

Brief Guide to "Externally Visible" Changes

"Externally visible behavior change" is very often due to some NEW canister API.

Changes to EXISTING APIs are more likely to be "breaking".

If these changes are breaking, make sure that clients know how to migrate, how to
maintain their continuity of operations.

If your changes are behind a feature flag, then, do NOT add entrie(s) to
unreleased_changelog.md in this PR! But rather, add entrie(s) later, in the PR
that enables these changes in production.

Reference(s)

For a more comprehensive checklist, see here.

GOVERNANCE_CHECKLIST_REMINDER_DEDUP

@jasonz-dfinity jasonz-dfinity force-pushed the jason/NNS1-4282-4 branch 2 times, most recently from f661a67 to 6e13c06 Compare January 9, 2026 17:16
Base automatically changed from jason/NNS1-4282-4 to master January 9, 2026 18:50
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This pull request performs a straightforward refactoring to rename the pb_api alias to api throughout the codebase. The change is motivated by the fact that the Governance API types are no longer protocol buffer (pb) types, making the old name misleading. This is a pure rename operation with no functional changes.

Key Changes

  • Renamed the import alias from use ic_nns_governance_api as pb_api to use ic_nns_governance_api as api
  • Updated all references to pb_api:: to use api:: instead
  • Updated function names containing pb_api to use api (e.g., convert_guest_launch_measurements_from_pb_to_pb_apiconvert_guest_launch_measurements_from_pb_to_api)

Reviewed changes

Copilot reviewed 3 out of 4 changed files in this pull request and generated no comments.

File Description
rs/nns/governance/src/pb/proposal_conversions.rs Updated import alias and all type references from pb_api to api throughout conversion functions
rs/nns/governance/src/pb/conversions/tests.rs Updated test code to use api instead of pb_api
rs/nns/governance/src/pb/conversions/mod.rs Extensive updates to conversion implementations and function names to use api instead of pb_api
rs/nns/governance/src/governance/tests/neurons_fund.rs Updated test code to use api instead of pb_api

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants