Skip to content

Add multi-channel approver support to Google Chat App setup - #2348

Merged
sk-keeper merged 1 commit into
releasefrom
gchat-add-multi-channel-approver-support
Sep 4, 2026
Merged

Add multi-channel approver support to Google Chat App setup#2348
sk-keeper merged 1 commit into
releasefrom
gchat-add-multi-channel-approver-support

Conversation

@sshrushanth-ks

Copy link
Copy Markdown
Contributor

Summary

Multi-channel approver support was added to Google Chat setup, providing feature parity with Slack.

Changes

  • approvals_setup.py: Extended ApprovalsChannelProfile with channel_field_name and team_channel_key fields. Parameterized approvals_config_to_record_fields() to use profile's field names.
  • approvals_sync.py: Parameterized parse_approvals_from_record(), merge_approvals_custom_fields(), sync_approvals_config(), and run_approvals_sync_down() to accept and use profile's field names.
  • gchat_app_setup.py: Created GCHAT_APPROVALS_PROFILE with channel_field_name='chat_approvals_space_id' and team_channel_key='space_id'. Implemented get_approvals_profile(). Updated build_record_custom_fields() to pass profile. Replaced unsafe assert with explicit CommandError. Added CommandError import.
  • integration_setup_base.py: Updated _patch_record_approvals() and run_approvals_sync_down() to pass profile parameter.
  • models.py: Made approvals field REQUIRED (no default). Added @property chat_approvals_space_id delegating to approvals.single_channel_id. Removed duplicate constants from GChatConstants.
  • slack_app_setup.py: Updated to pass SLACK_APPROVALS_PROFILE to sync functions for consistency.
  • test_gchat_app_setup.py: Updated test_multi_channel_approval_config_serialization() to pass profile and verify GChat field names (chat_approvals_space_id, space_id).

* Add multi-channel approver support to Google Chat App setup

* removed duplicate chat_approvals_space_id, and updates based on review comments

* Fix review feedback on Google Chat multi-channel approvers
-Remove duplicate FIELD_APPROVALS_SPACE_ID from record fields
-Fix type annotation: any → object in _validate_service_account_dict()
-Replace unsafe assert with proper CommandError error handling
-Add test_multi_channel_approval_config_serialization() for multi-team coverage

* Use GChat-specific naming for approvals configuration fields
-Change default channel field to chat_approvals_space_id (from approvals_channel_id)
-Use space_id instead of channel_id in approvals_teams JSON for teams
-Create _gchat_approvals_record_fields() for GChat-specific serialization
-Update tests to verify new field naming conventions

* Addressed review comments:Parameterize ApprovalsChannelProfile to unify Slack/GChat schema and fix --sync-down data corruption
@sshrushanth-ks
sshrushanth-ks marked this pull request as ready for review September 4, 2026 09:27
@sshrushanth-ks sshrushanth-ks self-assigned this Sep 4, 2026
@sk-keeper
sk-keeper merged commit 99525d8 into release Sep 4, 2026
4 checks passed
@sk-keeper
sk-keeper deleted the gchat-add-multi-channel-approver-support branch September 4, 2026 15:59
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.

2 participants