After upgrade to 3.11 I receive this message from update.php page:

Unresolved dependency Google Analytics (Version !=7.x-2.4 required)
Google Analytics for Ubercart requires this module and version. Currently using Google Analytics version 2.4.

Is it an issue or is it normal?.
I wait for response. Thanks

Comments

cozzamara created an issue. See original summary.

Infinitee’s picture

Same issue with me trying to update Version: 7.x-2.4. Looks like the version "!=" is the problem. It shows up on the modules admin page as well. I also make it so you can not turn the Google Analytics module off to update Ubercart.

Unresolved dependency Google Analytics (Version !=7.x-2.4 required)
Google Analytics for Ubercart requires this module and version. Currently using Google Analytics version 2.4

TR’s picture

Status: Active » Fixed

Google Analytics version 7.x-2.4 is broken - it has a syntax error when running PHP 5.3. This syntax error is fixed in Google Analytics 7.x-2.x-dev, which is why Ubercart has the dependency that you DON'T use GA 7.x-2.4. There is nothing wrong with the dependency or the != syntax - that means "not equal to", and that's what it's supposed to be.

Your choices are:

  1. Upgrade to Google Analytics 7.x-2.x-dev. Nothing further is required.
  2. Downgrade to Google Analytics 7.x-2.3. Nothing further is required.
  3. Apply the Google Analytics patch https://cgit.drupalcode.org/google_analytics/commit/?id=bde441d , which fixes the syntax error. Then make the modification below.
  4. Use PHP 5.4 or higher so this Google Analytics bug won't affect you. Then make the modification below.

If you choose #3 or #4, you will have to modify uc_googleanalytics.info and change:
dependencies[] = googleanalytics (!=7.x-2.4)
to read:
dependencies[] = googleanalytics

Sorry for the problem, but I don't maintain Google Analytics and they won't publish a new release just to fix this bug. (They did patch -dev, but there is no stable release with this bugfix yet). If Ubercart didn't have this dependency and you tried to upgrade while running PHP 5.3, then your site would have had a whitescreen and fatal error, which I think is a much bigger problem. With the dependency at least you get a readable message that tells you there's a problem with the Google Analytics version, so you are informed and can do something about it.

Infinitee’s picture

Well, installing Google Analytics 7.x-2.x-dev didn't work and all my sites are running on PHP 7.0.6. so, changing the uc_googleanalytics.info from:

dependencies[] = googleanalytics (!=7.x-2.4)
to read:
dependencies[] = googleanalytics

Is the only thing that worked for me.

Thank TR!

TR’s picture

@Infinitee: I believe if you download the GA -dev with git, the version information is not present in the .info file so Drupal can't tell what version it is. If you download from the project page, using the .tar.gz or the .zip, then the Drupal packager puts in a version that should work.

cozzamara’s picture

Thanks TR I use php 7.

BigMike’s picture

TR,

Thank you as always for your work.

In case others are wondering if this works, I encountered the error yesterday and took a hunch on the dev version and as TR reports above it does fix the issue (I am on PHP 5.3.29).

Regards,
BigMike

kingofdeal’s picture

After installing the developer version it solve my problem

TR’s picture

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.

kruser’s picture

@BigMike - The Dev version of Ubercart or GA?