-
Notifications
You must be signed in to change notification settings - Fork 22
Google Pull work integration branch. #2981
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
budzanowski
wants to merge
47
commits into
develop
Choose a base branch
from
test/combined-branches
base: develop
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This was referenced Jun 23, 2025
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## develop #2981 +/- ##
===========================================
Coverage 66.1% 66.2%
- Complexity 4820 4837 +17
===========================================
Files 491 826 +335
Lines 20506 25814 +5308
Branches 0 1269 +1269
===========================================
+ Hits 13563 17080 +3517
- Misses 6943 8581 +1638
- Partials 0 153 +153
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
e90ffa7
to
683dc35
Compare
Update SyncerHooks tests to mock the is_enabled_for_datatype method that was added to prevent sync jobs when PUSH is disabled. The tests now properly expect sync operations to be scheduled or not based on the merchant center status. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <[email protected]>
update tests
to preserve theJSON type when empty
Address #2821 (comment)
Co-authored-by: Mik <[email protected]>
…y default Authorization is now granted by default, making the WPCOM API authorization check redundant. Changes: - Remove `is_wpcom_api_authorized()` method from Options and OptionsInterface - Update NotificationsService to remove authorization checks from `is_ready()` method - Remove authorization status from error logging and debug output - Remove authorization field from analytics tracking data - Update unit tests to remove authorization-related test scenarios The remaining validation in NotificationsService ensures robust functionality through: - Feature enablement check - Merchant Center readiness validation - WordPress.com API health verification - Data type-specific sync settings 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <[email protected]>
…aces 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <[email protected]>
Remove outdated @param and fix return type annotation. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <[email protected]>
- Fix partner token health check in is_wpcom_api_status_healthy() - Inject is_partner_token_healthy: true when WPCOM returns false - Preserves existing logic for future compatibility - Auto-set WPCOM_REST_API_STATUS to 'approved' in get_connected_status() - Set status to 'approved' by default when not set - Preserves code structure for future UI functionality These changes fix issues after switching from OAuth to client credentials in INTEGRA-48, ensuring the system works properly with the new auth method. Addresses: INTEGRA-51 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <[email protected]>
- Mock is_wpcom_api_status_healthy to return true in test_get_connected_status_incomplete - Update expected wpcom_rest_api_status to 'approved' instead of null - Reflects new behavior where authorization is always approved with client credentials 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <[email protected]>
Removes user-facing controls for enabling/disabling the new product sync feature since it's now enabled by default with client credentials. ## Changes Made ### Removed UI Components: - "Disable product data fetch" button from Merchant Center account card - EnableNewProductSyncNotice banner from settings page - API_DATA_FETCH_FEATURE option from disconnect modal ### Preserved Functionality: - EnableNewProductSyncButton for "Grant access" during auth errors - Backend API endpoints for sync control - Both push and pull sync mechanisms - API-based configuration control ## Impact - Clean UI without confusing opt-in/opt-out controls - Sync functionality remains fully operational - Feature enabled by default with client credentials - API control still available for developers Addresses: INTEGRA-47 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <[email protected]>
Auto-fix JavaScript formatting issue identified by eslint/prettier. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <[email protected]>
bbff78a
to
e5982a4
Compare
- Add blog_id property to NotificationsService class - Include blog_id in all notification message bodies sent to WPCOM - Update NotificationsServiceTest to expect blog_id in request body - Enables WPCOM notification proxy to work with client credentials flow This change ensures all notification messages include the WordPress.com blog_id in their payload, which is required for the WPCOM proxy system to properly route notifications in the new client credentials authentication flow. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <[email protected]>
…-id-to-notifications Add blog_id to all notification messages (INTEGRA-49)
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
This PR combines eight related enhancements to improve the Google for WooCommerce integration:
Changes from PR #2821 - Add the G4W settings to WC REST API
/settings/google-for-woocommerce
endpoint to WC REST API/settings/general
to dedicated groupgla_google_connected
,gla_jetpack_connected
,gla_language
,gla_merchant_center
,gla_shipping_rates
,gla_shipping_times
,gla_target_audience
gla_syncable
parameter for securityChanges from PR #2810 - Block Shipping, Products and Coupons when Sync Push is disabled
Changes from PR #2982 - Remove WPCOM API authorization check as authorization is granted by default
is_wpcom_api_authorized()
method from Options and OptionsInterface classesRelated to PR #2976 - Reintroduce account:connect functionality for Google account linking (merged to develop)
update_sdi_merchant_account()
method to Middleware class for Google's SDI account:connect endpointChanges from PR #2985 - Fix WPCOM API partner token validation for client credentials (merged)
is_partner_token_healthy: true
when WPCOM returns false due to outdated OAuth-based validationWPCOM_REST_API_STATUS
to 'approved' by default since authorization is automatic with client credentialsChanges from PR #2987 - Remove opt-in/opt-out UI controls for product data sync (merged)
✅ Changes from PR #2977 - Add manual account linking endpoint (COMPLETED)
GET /wp-json/wc/gla/connect
endpoint for Google-triggered account linkingupdate_sdi_merchant_account()
when invoked by Google✅ Changes from PR #2989 - Add blog_id to notification messages (COMPLETED)
blog_id
property to NotificationsService classblog_id
in all notification message bodies sent to WPCOM endpointsblog_id
in request verificationTest Plan
For WC REST API Settings:
gla_syncable=1
parameter returns all expected settingsFor Sync Push Controls:
For WPCOM API Authorization Cleanup:
composer test
composer lint
For Account Linking Integration:
For WPCOM API Partner Token Health Fix:
For UI Controls Removal:
✅ For Manual Account Linking Endpoint:
✅ For Notification Messages with blog_id:
Related PRs
INTEGRA-30 Project Status
Completed Tasks:
Remaining Tasks:
All PRs are part of the broader INTEGRA-30 effort to improve Google for WooCommerce API integration, sync controls, account linking functionality, client credentials compatibility, and simplified user experience.
🤖 Generated with Claude Code