robwittman / shopify-php-sdk

PHP SDK for development with the Shopify API
MIT License
65 stars 41 forks source link

Ambiguous class resolution #14

Closed brenjt closed 6 years ago

brenjt commented 6 years ago

There are many classes that have conflicting names. I received this output with composer install

Warning: Ambiguous class resolution, "Shopify\Object\Location" was found in both "/www/vendor/robwittman/shopify-php-sdk/lib/Object/Location.php" and "/www/vendor/robwittman/shopify-php-sdk/lib/Object/Policy.php", the first will be used.
Warning: Ambiguous class resolution, "Shopify\Options\Blog\ListOptions" was found in both "/www/vendor/robwittman/shopify-php-sdk/lib/Options/Blog/GetOptions.php" and "/www/vendor/robwittman/shopify-php-sdk/lib/Options/Blog/ListOptions.php", the first will be used.
Warning: Ambiguous class resolution, "Shopify\Options\Article\CountOptions" was found in both "/www/vendor/robwittman/shopify-php-sdk/lib/Options/Article/CountOptions.php" and "/www/vendor/robwittman/shopify-php-sdk/lib/Options/Collect/CountOptions.php", the first will be used.
Warning: Ambiguous class resolution, "Shopify\Options\Article\GetOptions" was found in both "/www/vendor/robwittman/shopify-php-sdk/lib/Options/Article/GetOptions.php" and "/www/vendor/robwittman/shopify-php-sdk/lib/Options/Collect/GetOptions.php", the first will be used.
Warning: Ambiguous class resolution, "Shopify\Options\Article\ListOptions" was found in both "/www/vendor/robwittman/shopify-php-sdk/lib/Options/Article/ListOptions.php" and "/www/vendor/robwittman/shopify-php-sdk/lib/Options/Comment/GetOptions.php", the first will be used.
Warning: Ambiguous class resolution, "Shopify\Options\Article\ListOptions" was found in both "/www/vendor/robwittman/shopify-php-sdk/lib/Options/Article/ListOptions.php" and "/www/vendor/robwittman/shopify-php-sdk/lib/Options/Country/GetOptions.php", the first will be used.
Warning: Ambiguous class resolution, "Shopify\Options\Article\ListOptions" was found in both "/www/vendor/robwittman/shopify-php-sdk/lib/Options/Article/ListOptions.php" and "/www/vendor/robwittman/shopify-php-sdk/lib/Options/Country/ListOptions.php", the first will be used.
Warning: Ambiguous class resolution, "Shopify\Options\Fulfillment\ListOptions" was found in both "/www/vendor/robwittman/shopify-php-sdk/lib/Options/Fulfillment/ListOptions.php" and "/www/vendor/robwittman/shopify-php-sdk/lib/Options/Metafield/ListOptions.php", the first will be used.
Warning: Ambiguous class resolution, "Shopify\Options\Fulfillment\ListOptions" was found in both "/www/vendor/robwittman/shopify-php-sdk/lib/Options/Fulfillment/ListOptions.php" and "/www/vendor/robwittman/shopify-php-sdk/lib/Options/ProductVariant/GetOptions.php", the first will be used.
robwittman commented 6 years ago

Just tried installing for a new project and found the same errors.

I'll open a PR to fix over the weekend

robwittman commented 6 years ago

I had removed the usage of *Options objects to pass arguments to service functions a while ago, but hadn't drafted a new release yet. v2.1.0 has been tagged.