@sgiehl opened this Issue on May 30th 2022 Member

When the visits log is disabled globally or in website setting, loading reports for a period that has not yet been archived (without browser trigger), might currently show the error "Visits log is deactivated in website settings..."

The problem seems to be that the raw data check might try to perform a request to Live.getLastVisitsDetails in https://github.com/matomo-org/matomo/blob/6ab9923d6324c3d98765881e525d7ecf8ba9d831/plugins/CoreHome/vue/src/ReportingPage/ReportingPage.vue#L275-L279

That method is not available with deactivated visit log.

We should check if we can use or create another API method that provides the needed information, or maybe avoid the call completely if it doesn't make sense in that case.

@tsteur commented on May 30th 2022 Member

Nice find 👍 I actually ran into this issue recently and by the time I wanted to create a bug report I couldn't reproduce it anymore. Likely because data had been archived by then vs in the beginning it hadn't. And DEV-2830 is probably the same issue.

@tsteur commented on August 24th 2022 Member

Ran into this one again a few times recently while looking at reports on the Cloud. Eg happens for me on https://demo-web.matomo.org/index.php?module=CoreHome&action=index&idSite=12&period=week&date=today#?idSite=12&period=day&date=2022-08-24&category=Goals_Goals&subcategory=8 when no data is archived yet.

@mattab commented on September 15th 2022 Member

Fixing this issue might fix https://github.com/matomo-org/matomo/issues/19736 so i'd suggest to schedule both at the same time.

@sgiehl commented on September 15th 2022 Member

A very quick fix for this and similar issues would be to introduce a new API method like getMostRecentVisitsDateTime. That would allow any part of Matomo to check if there are visits for the current period even if getLastVisitsDetails is disabled in config.

This could actually also be some performance improvement for those parts currently checking this using getLastVisitsDetails...

Powered by GitHub Issue Mirror