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

Heartbeat timer should ensure that the "Time on page" metric is correct in "Pages" reports #9748

Open
hpvd opened this issue Feb 10, 2016 · 5 comments
Labels
Bug For errors / faults / flaws / inconsistencies etc. c: Data Integrity & Accuracy

Comments

@hpvd
Copy link

hpvd commented Feb 10, 2016

actions/pages "average time on page" seems to be broken

please see attachments for example:

2 visits (filtert by shown segment)

  • only one site visit
  • only pageview
  • no events etc...

show visit times in visitorlog (total and for page on hover)
but in actions/pages average time is 0:00

2016-02-10_17h24_36

2016-02-10_17h26_48

2016-02-10_17h31_59

2016-02-10_17h25_27

@tsteur
Copy link
Member

tsteur commented Feb 10, 2016

It's currently like this "by design". We might fix this in Piwik 3.0 but it's not clear yet. We cannot fix it in 2.X as it requires DB schema change for log tables which would take a very long time.

Background: The avg_time_on_page is not written for last action, only visit_total_time is updated for heartbeat. To do proper calculation we always need to know what last_idlink_va was and update time spent on the actual action, not on the next action. To have it backwards compatible with existing data will be quite challenging but doable.

@hpvd
Copy link
Author

hpvd commented Feb 10, 2016

thanks for fast and detailed answer.
I think it's quite important to have a possibility to see average time on special types of pages.
Background:
it's important to see when making changes on a page how these are liked by visitors.
On lots of types of pages this could be done easily looking on development of average time on page.
If it rises, the visitor likes it more than before. If average time on page is lowered the change works opposite as planned...

(since it's not working as expected, one could think of giving it a bug label, couldn't one?)

@tsteur tsteur added the Bug For errors / faults / flaws / inconsistencies etc. label Feb 10, 2016
@tsteur
Copy link
Member

tsteur commented Feb 10, 2016

It's definitely a bug and a fix is needed at some point indeed. Otherwise the avg_time_on_page in the Actions report is simply not correct.

@mattab mattab modified the milestones: 2.16.x (LTS), 3.0.0 Mar 31, 2016
@mattab mattab changed the title actions/pages "average time on page" broken Heartbeat timer should ensure that the "Time on page" metric is correct in "Pages" reports Apr 18, 2018
@mattab
Copy link
Member

mattab commented Nov 20, 2019

Could we maybe fix this in Matomo 4 @tsteur ? assigning tentatively

@tsteur
Copy link
Member

tsteur commented Nov 20, 2019

I'm not sure we're wanting to this as it means more selects/updates in the tracker... I would certainly not do this in Matomo 4 though as it's not a breaking change and does not require any DB updates etc and can always be done afterwards. It will only delay the release by a few more days which is not worth it.

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. c: Data Integrity & Accuracy
Projects
None yet
Development

No branches or pull requests

3 participants