Skip to content
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

Removing old API versions to prevent random autoload errors #6

Merged
merged 1 commit into from
Sep 18, 2017

Conversation

zak10
Copy link

@zak10 zak10 commented Sep 18, 2017

Summary

This PR will remove all versions of the Adwords API prior to the current version. When composer creates an optimized autoloader, it can pick any of the versions of this library since we are currently loading them all. Unfortunately for us, v2016* is alphabetically prior to v2017*, meaning the autoloader is going to use the oldest versions of the API first.

This is all evident in the /path/to/application/vendor/composer/autoload_static.php file. Each namespaced class is currently pointing to the v201607 like so:

'AdGroupCriterionServiceGet' => DIR . '/..' . '/sidecar/googleads-php-lib/src/Google/Api/Ads/AdWords/v201607/AdGroupCriterionService.php',

Why did we just start noticing these errors?

On 6/5/2017 we made a release of this library that reverted a change previously that removed all of the older versions of the API. When those versions were added back in, the errors started happening again.

Google doesn't totally remove an API version for some time, so v201607 will only throw intermittent errors, which is what we're seeing now.

@chriscannon
Copy link

Ugh good lord! At least we won't make this same mistake with the Bing upgrade.

@zak10 zak10 merged commit 5f2efbf into master Sep 18, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants