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

Ensure Database is set in Tracker #4603

Closed
anonymous-matomo-user opened this issue Jan 31, 2014 · 3 comments
Closed

Ensure Database is set in Tracker #4603

anonymous-matomo-user opened this issue Jan 31, 2014 · 3 comments
Assignees
Labels
Bug For errors / faults / flaws / inconsistencies etc.
Milestone

Comments

@anonymous-matomo-user
Copy link

When using 2.0.3 and an token_auth for bulk tracking, as well as have PIWIK_TRACKER_MODE set to true.

On every valid bulk request submission I had the following error,

PHP Fatal error: Call to a member function fetchAll() on a non-object in ... /piwik/core/Db.php on line 164

I found that fetchAll() retrieved it's db object from get(), which was calling Tracker::getDatabase(), which was returning null.

I've submitted a fix/pull request here:

#215

Upon adding my check, everything worked.

Please note that if I set PIWIK_TRACKER_MODE to false, then Piwik stops accepting my token_auth key.

I want my fix to be applied upstream, and it was suggested that a bug report needed to be submitted first.
Keywords: buk tracking

@mattab
Copy link
Member

mattab commented Feb 1, 2014

Thanks for the report. So bulk request as explained here:

http://developer.piwik.org/api-reference/tracking-api#bulk-tracking

does not work for you in 2.0.3?

@mattab
Copy link
Member

mattab commented Feb 4, 2014

In 74c865d: Adding integration test for the Bulk Tracking API, it FAILS at present! refs #4603
Thanks for the report, we didn't catch this failure as it wasn't properly continuously tested!

@mattab
Copy link
Member

mattab commented Feb 4, 2014

In a6e4884: Fixes #4603 Adding lazy DB connection call

@anonymous-matomo-user anonymous-matomo-user added this to the 2.1 - Piwik 2.1 milestone Jul 8, 2014
sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
…t! refs matomo-org#4603

Thanks for the report, we didn't catch this failure as it wasn't properly continuously tested!
sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug For errors / faults / flaws / inconsistencies etc.
Projects
None yet
Development

No branches or pull requests

2 participants