All records count twice

First off, great analytics. Much better to understand than GA. Hehe. Well, I just started trying out Piwik and managed to make it work on my server.

I have a problem though, everything is logged twice on my dashboard. I don’t know why though. Even when I check my chrome’s Network logs, it only logs once per call, but when I look at my Piwik dashboard, it counts two. Even when I track an event, one call from my site is counted twice.

Can anyone help? I don’t know where to start looking. I use the instructions here BTW JavaScript Tracking Client: Integrate - Matomo Analytics (formerly Piwik Analytics) - Developer Docs - v3 and moved the code a bit for my reactJS site.

some example calls
[myserver]/piwik/piwik.php?action_name=%2F&idsite=1&rec=1&r=254781&h=17&m=1&s=49&url=http%3A%2F%2Flocalhost%2F&_id=a37a0cb378ed68c2&_idts=1467276253&_idvc=6&_idn=0&_refts=0&_viewts=1467362873&send_image=0&pdf=1&qt=0&realp=0&wma=0&dir=0&fla=1&java=0&gears=0&ag=0&cookie=1&res=3360x2100&gt_ms=1402

[myserver]/piwik/piwik.php?e_c=custom-event&e_a=Call&e_n=&e_v=&idsite=1&rec=1&r=025990&h=17&m=14&s=21&url=http%3A%2F%2Flocalhost%2Fganso-shabuway-japanese-style-hot-pot-shangri-la-plaza-mall&_id=a37a0cb378ed68c2&_idts=1467276253&_idvc=6&_idn=0&_refts=0&_viewts=1467362873&send_image=0&pdf=1&qt=0&realp=0&wma=0&dir=0&fla=1&java=0&gears=0&ag=0&cookie=1&res=3360x2100&gt_ms=1402

It looks like you are tracking some custom events in your javascript code. Check for trackEvent calls in your code, as they are sending the second type of requests

Thanks for the reply @matthieu. But those are separate calls. I tried them both on separate occasions but they are counted twice and it’s still happening now.

When I see only one request from my chrome console, what could be the reason it’s counting twice? Here’s a screenshot of the request.

Separately, I tried to copy this call from the Chrome’s network tab on console and tried to curl it on my terminal and it only counted once. Could the piwik.js counting it incorrectly? Where could I be wrong here?

I tried to do it on a plain html file and here’s how it looks

<html>
  <head>
    <title>Test tracking</title>
    <script>
      var serverHost = "[hostServer]";
      var siteId = 1;
      var _paq = _paq || [];
      _paq.push(['trackPageView']);

      (function() {
        var u=serverHost;
        _paq.push(['setTrackerUrl', u+'piwik.php']);
        _paq.push(['setSiteId', siteId]);
        var d=document, g=d.createElement('script'), s=d.getElementsByTagName('script')[0];
        g.type='text/javascript'; g.async=true; g.defer=true; g.src=u+'piwik.js'; s.parentNode.insertBefore(g,s);
      })();
      console.log(_paq);
    </script>
  </head>
  <body>
    Tracking...
  </body>
</html>

and I tried to load them only once. Did 5 tests, each changing the filename of the file and this is what I got.

Do you see same behavior in Firefox?