googleads / google-ads-php

Google Ads API Client Library for PHP
https://developers.google.com/google-ads/api/docs/client-libs/php
Apache License 2.0
295 stars 262 forks source link

Update issues v12 to lastest #953

Closed publish-web closed 1 year ago

publish-web commented 1 year ago

Ubuntu 21.10

Hi,

I have some issues when I try to update google-ads-php.

Here is what I do :

And I have this error :

Using version ^21.0 for googleads/google-ads-php Root package 'googleads/google-ads-php' cannot require itself in its composer.json

Can you help me please ?

Thank you!

fiboknacky commented 1 year ago

You don't need to remove the google-ads-php directory. Instead, what you should is just running composer update from your project directory.

As the error message describes, you're requiring the library inside itself, which is wrong.

publish-web commented 1 year ago

Thanks for your answer!

This is what I've done following your advice :

But it returns :

Nothing to install, update or remove

In the composer.json file, I can see "17.1" and this my current library version :

{
    "require": {
        "grpc/grpc": "^1.38",
        "google/protobuf": "^3.17",
        "googleads/google-ads-php": "^17.1"
    }
}

But I'm trying to update to 21.0, should I edit this file manually?

fiboknacky commented 1 year ago

Nope. Please don't cd into the google-ads-php folder. You should do this at your own project directory (the parent of vendor)

publish-web commented 1 year ago

I finished to figure it out on my own, it works now! Thanks for your help!