Logger; use Automattic\WooCommerce\GoogleListingsAndAds\Menu\AttributeMapping; use Automattic\WooCommerce\GoogleListingsAndAds\Menu\Dashboard; use Automattic\WooCommerce\GoogleListingsAndAds\Menu\GetStarted; use Automattic\WooCommerce\GoogleListingsAndAds\Menu\ProductFeed; use Automattic\WooCommerce\GoogleListingsAndAds\Menu\Reports; use Automattic\WooCommerce\GoogleListingsAndAds\Menu\Settings; use Automattic\WooCommerce\GoogleListingsAndAds\Menu\SetupAds; use Automattic\WooCommerce\GoogleListingsAndAds\Menu\SetupMerchantCenter; use Automattic\WooCommerce\GoogleListingsAndAds\MerchantCenter\AccountService as MerchantAccountService; use Automattic\WooCommerce\GoogleListingsAndAds\MerchantCenter\ContactInformation; use Automattic\WooCommerce\GoogleListingsAndAds\MerchantCenter\MerchantCenterAwareInterface; use Automattic\WooCommerce\GoogleListingsAndAds\MerchantCenter\MerchantCenterService; use Automattic\WooCommerce\GoogleListingsAndAds\MerchantCenter\MerchantStatuses; use Automattic\WooCommerce\GoogleListingsAndAds\MerchantCenter\PhoneVerification; use Automattic\WooCommerce\GoogleListingsAndAds\MultichannelMarketing\GLAChannel; use Automattic\WooCommerce\GoogleListingsAndAds\MultichannelMarketing\MarketingChannelRegistrar; use Automattic\WooCommerce\GoogleListingsAndAds\MerchantCenter\PolicyComplianceCheck; use Automattic\WooCommerce\GoogleListingsAndAds\Notes\CompleteSetup as CompleteSetupNote; use Automattic\WooCommerce\GoogleListingsAndAds\MerchantCenter\TargetAudience; use Automattic\WooCommerce\GoogleListingsAndAds\Notes\ContactInformation as ContactInformationNote; use Automattic\WooCommerce\GoogleListingsAndAds\Notes\NoteInitializer; use Automattic\WooCommerce\GoogleListingsAndAds\Notes\ReconnectWordPress as ReconnectWordPressNote; use Automattic\WooCommerce\GoogleListingsAndAds\Notes\ReviewAfterClicks as ReviewAfterClicksNote; use Automattic\WooCommerce\GoogleListingsAndAds\Notes\ReviewAfterConversions as ReviewAfterConversionsNote; use Automattic\WooCommerce\GoogleListingsAndAds\Notes\SetupCampaign as SetupCampaignNote; use Automattic\WooCommerce\GoogleListingsAndAds\Notes\SetupCampaignTwoWeeks as SetupCampaign2Note; use Automattic\WooCommerce\GoogleListingsAndAds\Notes\SetupCouponSharing as SetupCouponSharingNote; use Automattic\WooCommerce\GoogleListingsAndAds\Options\AdsAccountState; use Automattic\WooCommerce\GoogleListingsAndAds\Options\AdsSetupCompleted; use Automattic\WooCommerce\GoogleListingsAndAds\Options\MerchantAccountState; use Automattic\WooCommerce\GoogleListingsAndAds\Options\MerchantSetupCompleted; use Automattic\WooCommerce\GoogleListingsAndAds\Options\Options; use Automattic\WooCommerce\GoogleListingsAndAds\Options\OptionsAwareInterface; use Automattic\WooCommerce\GoogleListingsAndAds\Options\OptionsInterface; use Automattic\WooCommerce\GoogleListingsAndAds\Options\Transients; use Automattic\WooCommerce\GoogleListingsAndAds\Options\TransientsInterface; use Automattic\WooCommerce\GoogleListingsAndAds\Product\AttributeMapping\AttributeMappingHelper; use Automattic\WooCommerce\GoogleListingsAndAds\Product\Attributes\AttributeManager; use Automattic\WooCommerce\GoogleListingsAndAds\Product\BatchProductHelper; use Automattic\WooCommerce\GoogleListingsAndAds\Product\ProductFactory; use Automattic\WooCommerce\GoogleListingsAndAds\Product\ProductFilter; use Automattic\WooCommerce\GoogleListingsAndAds\Product\ProductHelper; use Automattic\WooCommerce\GoogleListingsAndAds\Product\ProductMetaHandler; use Automattic\WooCommerce\GoogleListingsAndAds\Product\ProductRepository; use Automattic\WooCommerce\GoogleListingsAndAds\Product\ProductSyncer; use Automattic\WooCommerce\GoogleListingsAndAds\Proxies\GoogleGtagJs; use Automattic\WooCommerce\GoogleListingsAndAds\Proxies\Tracks as TracksProxy; use Automattic\WooCommerce\GoogleListingsAndAds\Proxies\WC; use Automattic\WooCommerce\GoogleListingsAndAds\Proxies\WP; use Automattic\WooCommerce\GoogleListingsAndAds\Shipping\LocationRatesProcessor; use Automattic\WooCommerce\GoogleListingsAndAds\Shipping\ShippingSuggestionService; use Automattic\WooCommerce\GoogleListingsAndAds\Shipping\ZoneMethodsParser; use Automattic\WooCommerce\GoogleListingsAndAds\Shipping\ShippingZone; use Automattic\WooCommerce\GoogleListingsAndAds\Shipping\ZoneLocationsParser; use Automattic\WooCommerce\GoogleListingsAndAds\TaskList\CompleteSetupTask; use Automattic\WooCommerce\GoogleListingsAndAds\Tracking\Events\ActivatedEvents; use Automattic\WooCommerce\GoogleListingsAndAds\Tracking\Events\GenericEvents; use Automattic\WooCommerce\GoogleListingsAndAds\Tracking\Events\SiteClaimEvents; use Automattic\WooCommerce\GoogleListingsAndAds\Tracking\Events\SiteVerificationEvents; use Automattic\WooCommerce\GoogleListingsAndAds\Tracking\EventTracking; use Automattic\WooCommerce\GoogleListingsAndAds\Tracking\TrackerSnapshot; use Automattic\WooCommerce\GoogleListingsAndAds\Tracking\Tracks; use Automattic\WooCommerce\GoogleListingsAndAds\Tracking\TracksAwareInterface; use Automattic\WooCommerce\GoogleListingsAndAds\Tracking\TracksInterface; use Automattic\WooCommerce\GoogleListingsAndAds\Utility\AddressUtility; use Automattic\WooCommerce\GoogleListingsAndAds\Utility\DateTimeUtility; use Automattic\WooCommerce\GoogleListingsAndAds\Utility\ImageUtility; use Automattic\WooCommerce\GoogleListingsAndAds\Utility\ISOUtility; use Automattic\WooCommerce\GoogleListingsAndAds\Vendor\League\ISO3166\ISO3166DataProvider; use Automattic\WooCommerce\GoogleListingsAndAds\Vendor\Psr\Container\ContainerInterface; use Automattic\WooCommerce\GoogleListingsAndAds\View\PHPViewFactory; use Symfony\Component\Validator\Validator\ValidatorInterface; use wpdb; /** * Class CoreServiceProvider * * @package Automattic\WooCommerce\GoogleListingsAndAds\Internal\DependencyManagement */ class CoreServiceProvider extends AbstractServiceProvider { /** * @var array */ protected $provides = [ Installer::class => true, Redirect::class => true, Admin::class => true, AddressUtility::class => true, Reports::class => true, AssetsHandlerInterface::class => true, BulkEditInitializer::class => true, ContactInformationNote::class => true, CompleteSetupTask::class => true, CompleteSetupNote::class => true, CouponBulkEdit::class => true, CouponHelper::class => true, CouponMetaHandler::class => true, CouponSyncer::class => true, Dashboard::class => true, DateTimeUtility::class => true, EventTracking::class => true, GetStarted::class => true, GlobalSiteTag::class => true, ISOUtility::class => true, SiteVerificationEvents::class => true, OptionsInterface::class => true, TransientsInterface::class => true, ProductFeed::class => true, ReconnectWordPressNote::class => true, ReviewAfterClicksNote::class => true, RESTControllers::class => true, Service::class => true, Settings::class => true, SetupAds::class => true, SetupMerchantCenter::class => true, SetupCampaignNote::class => true, SetupCampaign2Note::class => true, SetupCouponSharingNote::class => true, TableManager::class => true, TrackerSnapshot::class => true, Tracks::class => true, TracksInterface::class => true, ProductSyncer::class => true, ProductHelper::class => true, ProductMetaHandler::class => true, SiteVerificationMeta::class => true, BatchProductHelper::class => true, ProductFilter::class => true, ProductRepository::class => true, MetaBoxInterface::class => true, MetaBoxInitializer::class => true, ViewFactory::class => true, DebugLogger::class => true, MerchantStatuses::class => true, PhoneVerification::class => true, PolicyComplianceCheck::class => true, ContactInformation::class => true, MerchantCenterService::class => true, TargetAudience::class => true, MerchantAccountState::class => true, AdsAccountState::class => true, DBInstaller::class => true, AttributeManager::class => true, ProductFactory::class => true, AttributesTab::class => true, VariationsAttributes::class => true, DeprecatedFilters::class => true, ZoneLocationsParser::class => true, ZoneMethodsParser::class => true, LocationRatesProcessor::class => true, ShippingZone::class => true, AdsAccountService::class => true, MerchantAccountService::class => true, AttributeMapping::class => true, MarketingChannelRegistrar::class => true, ]; /** * Use the register method to register items with the container via the * protected $this->leagueContainer property or the `getLeagueContainer` method * from the ContainerAwareTrait. * * @return void */ public function register(): void { $this->conditionally_share_with_tags( DebugLogger::class ); // Share our interfaces, possibly with concrete objects. $this->share_concrete( AssetsHandlerInterface::class, AssetsHandler::class ); $this->share_concrete( TransientsInterface::class, Transients::class ); $this->share_concrete( TracksInterface::class, $this->share_with_tags( Tracks::class, TracksProxy::class ) ); // Set up Options, and inflect classes that need options. $this->share_concrete( OptionsInterface::class, Options::class ); $this->getLeagueContainer() ->inflector( OptionsAwareInterface::class ) ->invokeMethod( 'set_options_object', [ OptionsInterface::class ] ); // Share helper classes, and inflect classes that need it. $this->share_with_tags( GoogleHelper::class, WC::class ); $this->getLeagueContainer() ->inflector( GoogleHelperAwareInterface::class ) ->invokeMethod( 'set_google_helper_object', [ GoogleHelper::class ] ); // Set up the TargetAudience service. $this->share_with_tags( TargetAudience::class, WC::class, OptionsInterface::class, GoogleHelper::class ); // Set up MerchantCenter service, and inflect classes that need it. $this->share_with_tags( MerchantCenterService::class ); $this->getLeagueContainer() ->inflector( MerchantCenterAwareInterface::class ) ->invokeMethod( 'set_merchant_center_object', [ MerchantCenterService::class ] ); // Set up Ads service, and inflect classes that need it. $this->share_with_tags( AdsAccountState::class ); $this->share_with_tags( AdsService::class, AdsAccountState::class ); $this->getLeagueContainer() ->inflector( AdsAwareInterface::class ) ->invokeMethod( 'set_ads_object', [ AdsService::class ] ); $this->share_with_tags( AssetSuggestionsService::class, WP::class, WC::class, ImageUtility::class, wpdb::class, AdsAssetGroupAsset::class ); // Set up the installer. $installer_definition = $this->share_with_tags( Installer::class, InstallableInterface::class, FirstInstallInterface::class, WP::class ); $installer_definition->setConcrete( function ( ...$arguments ) { return new Installer( ...$arguments ); } ); // Share utility classes $this->share_with_tags( AddressUtility::class ); $this->share_with_tags( DateTimeUtility::class ); $this->share_with_tags( ImageUtility::class, WP::class ); $this->share_with_tags( ISOUtility::class, ISO3166DataProvider::class ); // Share our regular service classes. $this->conditionally_share_with_tags( Admin::class, AssetsHandlerInterface::class, PHPViewFactory::class, MerchantCenterService::class, AdsService::class ); $this->conditionally_share_with_tags( Redirect::class, WP::class ); $this->conditionally_share_with_tags( GetStarted::class ); $this->conditionally_share_with_tags( SetupMerchantCenter::class ); $this->conditionally_share_with_tags( SetupAds::class ); $this->conditionally_share_with_tags( Dashboard::class ); $this->conditionally_share_with_tags( Reports::class ); $this->conditionally_share_with_tags( ProductFeed::class ); $this->conditionally_share_with_tags( AttributeMapping::class ); $this->conditionally_share_with_tags( Settings::class ); $this->share_with_tags( TrackerSnapshot::class ); $this->conditionally_share_with_tags( EventTracking::class, ContainerInterface::class ); $this->conditionally_share_with_tags( RESTControllers::class, ContainerInterface::class ); $this->conditionally_share_with_tags( ConnectionTest::class, ContainerInterface::class ); $this->share_with_tags( CompleteSetupTask::class ); $this->conditionally_share_with_tags( GlobalSiteTag::class, AssetsHandlerInterface::class, GoogleGtagJs::class, ProductHelper::class, WC::class, WP::class ); $this->share_with_tags( SiteVerificationMeta::class ); $this->conditionally_share_with_tags( MerchantSetupCompleted::class ); $this->conditionally_share_with_tags( AdsSetupCompleted::class ); $this->conditionally_share_with_tags( AdsAccountService::class, ContainerInterface::class ); $this->conditionally_share_with_tags( MerchantAccountService::class, ContainerInterface::class ); // Inbox Notes $this->share_with_tags( ContactInformationNote::class ); $this->share_with_tags( CompleteSetupNote::class ); $this->share_with_tags( ReconnectWordPressNote::class, GoogleConnection::class ); $this->share_with_tags( ReviewAfterClicksNote::class, MerchantMetrics::class, WP::class ); $this->share_with_tags( ReviewAfterConversionsNote::class, MerchantMetrics::class, WP::class ); $this->share_with_tags( SetupCampaignNote::class, MerchantCenterService::class ); $this->share_with_tags( SetupCampaign2Note::class, MerchantCenterService::class ); $this->share_with_tags( SetupCouponSharingNote::class, MerchantStatuses::class ); $this->share_with_tags( NoteInitializer::class, ActionScheduler::class ); // Product attributes $this->conditionally_share_with_tags( AttributeManager::class ); $this->conditionally_share_with_tags( AttributesTab::class, Admin::class, AttributeManager::class, MerchantCenterService::class ); $this->conditionally_share_with_tags( VariationsAttributes::class, Admin::class, AttributeManager::class, MerchantCenterService::class ); // Product Block Editor $this->share_with_tags( ChannelVisibilityBlock::class, ProductHelper::class, MerchantCenterService::class ); $this->conditionally_share_with_tags( ProductBlocksService::class, AssetsHandlerInterface::class, ChannelVisibilityBlock::class, AttributeManager::class, MerchantCenterService::class ); $this->share_with_tags( MerchantAccountState::class ); $this->share_with_tags( MerchantStatuses::class ); $this->share_with_tags( PhoneVerification::class, Merchant::class, WP::class, ISOUtility::class ); $this->share_with_tags( PolicyComplianceCheck::class, WC::class, GoogleHelper::class, TargetAudience::class ); $this->share_with_tags( ContactInformation::class, Merchant::class, GoogleSettings::class ); $this->share_with_tags( ProductMetaHandler::class ); $this->share( ProductHelper::class, ProductMetaHandler::class, WC::class, TargetAudience::class ); $this->share_with_tags( ProductFilter::class, ProductHelper::class ); $this->share_with_tags( ProductRepository::class, ProductMetaHandler::class, ProductFilter::class ); $this->share_with_tags( ProductFactory::class, AttributeManager::class, WC::class ); $this->share_with_tags( BatchProductHelper::class, ProductMetaHandler::class, ProductHelper::class, ValidatorInterface::class, ProductFactory::class, TargetAudience::class, AttributeMappingRulesQuery::class ); $this->share_with_tags( ProductSyncer::class, GoogleProductService::class, BatchProductHelper::class, ProductHelper::class, MerchantCenterService::class, WC::class, ProductRepository::class ); // Coupon management classes $this->share_with_tags( CouponMetaHandler::class ); $this->share_with_tags( CouponHelper::class, CouponMetaHandler::class, WC::class, MerchantCenterService::class ); $this->share_with_tags( CouponSyncer::class, GooglePromotionService::class, CouponHelper::class, ValidatorInterface::class, MerchantCenterService::class, TargetAudience::class, WC::class ); // Set up inflector for tracks classes. $this->getLeagueContainer() ->inflector( TracksAwareInterface::class ) ->invokeMethod( 'set_tracks', [ TracksInterface::class ] ); // Share admin meta boxes $this->conditionally_share_with_tags( ChannelVisibilityMetaBox::class, Admin::class, ProductMetaHandler::class, ProductHelper::class, MerchantCenterService::class ); $this->conditionally_share_with_tags( CouponChannelVisibilityMetaBox::class, Admin::class, CouponMetaHandler::class, CouponHelper::class, MerchantCenterService::class, TargetAudience::class ); $this->conditionally_share_with_tags( MetaBoxInitializer::class, Admin::class, MetaBoxInterface::class ); // Share bulk edit views $this->share_with_tags( CouponBulkEdit::class, CouponMetaHandler::class, MerchantCenterService::class, TargetAudience::class ); $this->share_with_tags( BulkEditInitializer::class ); $this->share_with_tags( PHPViewFactory::class ); // Share other classes. $this->share_with_tags( ActivatedEvents::class, $_SERVER ); $this->share_with_tags( GenericEvents::class ); $this->share_with_tags( SiteClaimEvents::class ); $this->share_with_tags( SiteVerificationEvents::class ); $this->conditionally_share_with_tags( InstallTimestamp::class ); $this->conditionally_share_with_tags( ClearProductStatsCache::class, MerchantStatuses::class ); $this->share_with_tags( TableManager::class, 'db_table' ); $this->share_with_tags( DBInstaller::class, TableManager::class, Migrator::class ); $this->share_with_tags( DeprecatedFilters::class ); $this->share_with_tags( LocationRatesProcessor::class ); $this->share_with_tags( ZoneLocationsParser::class, GoogleHelper::class ); $this->share_with_tags( ZoneMethodsParser::class, WC::class ); $this->share_with_tags( ShippingZone::class, WC::class, ZoneLocationsParser::class, ZoneMethodsParser::class, LocationRatesProcessor::class ); $this->share_with_tags( ShippingSuggestionService::class, ShippingZone::class, WC::class ); $this->share_with_tags( RequestReviewStatuses::class ); // Share Attribute Mapping related classes $this->share_with_tags( AttributeMappingHelper::class ); if ( defined( 'WC_MCM_EXISTS' ) ) { $this->share_with_tags( GLAChannel::class, MerchantCenterService::class, AdsCampaign::class, Ads::class, MerchantStatuses::class, ProductSyncStats::class ); $this->share_with_tags( MarketingChannelRegistrar::class, GLAChannel::class, WC::class ); } } }
Fatal error: Uncaught Automattic\WooCommerce\GoogleListingsAndAds\Vendor\League\Container\Exception\ContainerException: A service provider must be a fully qualified class name or instance of (\League\Container\ServiceProvider\ServiceProviderInterface) in /htdocs/wp-content/plugins/google-listings-and-ads/vendor/league/container/src/ServiceProvider/ServiceProviderAggregate.php:52 Stack trace: #0 /htdocs/wp-content/plugins/google-listings-and-ads/vendor/league/container/src/Container.php(146): Automattic\WooCommerce\GoogleListingsAndAds\Vendor\League\Container\ServiceProvider\ServiceProviderAggregate->add('Automattic\\WooC...') #1 /htdocs/wp-content/plugins/google-listings-and-ads/src/Container.php(75): Automattic\WooCommerce\GoogleListingsAndAds\Vendor\League\Container\Container->addServiceProvider('Automattic\\WooC...') #2 /htdocs/wp-content/plugins/google-listings-and-ads/google-listings-and-ads.php(93): Automattic\WooCommerce\GoogleListingsAndAds\Container->__construct() #3 /htdocs/wp-content/plugins/google-listings-and-ads/src/PluginFactory.php(25): woogle_get_container() #4 /htdocs/wp-content/plugins/google-listings-and-ads/google-listings-and-ads.php(72): Automattic\WooCommerce\GoogleListingsAndAds\PluginFactory::instance() #5 /htdocs/wp-includes/class-wp-hook.php(324): {closure}('') #6 /htdocs/wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters('', Array) #7 /htdocs/wp-includes/plugin.php(517): WP_Hook->do_action(Array) #8 /htdocs/wp-content/plugins/woocommerce/includes/class-woocommerce.php(218): do_action('woocommerce_loa...') #9 /htdocs/wp-includes/class-wp-hook.php(324): WooCommerce->on_plugins_loaded('') #10 /htdocs/wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters(NULL, Array) #11 /htdocs/wp-includes/plugin.php(517): WP_Hook->do_action(Array) #12 /htdocs/wp-settings.php(559): do_action('plugins_loaded') #13 /htdocs/wp-config.php(85): require_once('/htdocs/wp-sett...') #14 /htdocs/wp-load.php(50): require_once('/htdocs/wp-conf...') #15 /htdocs/wp-blog-header.php(13): require_once('/htdocs/wp-load...') #16 /htdocs/index.php(17): require('/htdocs/wp-blog...') #17 {main} thrown in /htdocs/wp-content/plugins/google-listings-and-ads/vendor/league/container/src/ServiceProvider/ServiceProviderAggregate.php on line 52