NEW Piwik 2.0 Beta release!

Dear Piwik users,

We are extremely excited to announce the first public beta release of Piwik 2.0!

Piwik 2.0 is a major update from Piwik 1.12 and is the result of 5 months of work on the platform!

What’s changed?

We focused on upgrading Piwik source code quality and maintainability: upgraded to PHP 5.3 using namespaces, changed templating library to Twig, started using composer, using Less as well as css, improved QA tests, introduced new Screenshots tests, refactored translations to nice JSON format, refactored LOTS of code, added documentation…

There also performance improvements, in particular the “All Websites Dashboard” is now usable with 20,000+ websites!

As well as improvements in the platform, we have fixed countless bugs from Piwik 1.12 and added some very-special-and-exciting-new features. Piwik 2 is the open platform for analytics!

-> List of all closed tickets in Piwik 2.0 [link][/url]. See also our [url=http://piwik.org/blog/2013/10/september-2013-piwik-development-update-2/]dev update blog post.

How to update to latest beta?
[ol]
[li] You can tell Piwik to use the latest beta from within the user interface. See this FAQ: Update - Analytics Platform - Matomo
[/li][li] or alternatively you may download the latest beta from the build server, upload these files on top of your existing piwik files, and visit Piwik to upgrade.
[/li][/ol]

Beta cycle
We will fix quickly any bug or issue you experience with 2.0. The stable release is in planned for mid-November.

-> Please post any issue or question as a reply to this post <-

“There also also performance improvements, …” (one “also” too much)

Congrats to the effort. Can’t wait to see the final Piwik 2 in action. :slight_smile:

Would that also applicable in android mobile?

Hi,

I’m experiencing an issue since attempting to use the auto-updater to install the beta. Once I pressed the first button of the updater I was redirected to a blank page.

I checked and found an error_log entry:

[18-Oct-2013 15:16:32 UTC] PHP Fatal error: Class ‘Piwik\Plugins\CoreVisualizations\Visualizations\HtmlTable’ not found in /home/username/public_html/piwik/plugins/CoreVisualizations/Visualizations/HtmlTable/AllColumns.php on line 31

Any help in resolving this error would be appreciated! :)-D

do you use xcache on your server?
looks like this

just a post to unfollow this topic. I keep getting mails…

[quote=maartenvc]
do you use xcache on your server?
looks like this[/quote]

I did have xcache installed and enabled on my whm host. Changing the settings to match yours hasn’t helped though unfortunately.

I already restarted Apache/Nginx.

If anyone knows how to properly fix the xcache issue we are interested. We fixed Piwik so it works with APC and Opcache and would like to add support for Xcache.

[quote=matt]
If anyone knows how to properly fix the xcache issue we are interested. We fixed Piwik so it works with APC and Opcache and would like to add support for Xcache.[/quote]

matt,

While I haven’t found a way to make Xcache and Piwik behave together, I had luck in completing the upgrade. I disabled all Xcache references and now it works.

What’s strange is that Piwik worked flawlessly before this update with Xcache, so bit of a mystery there!

Rich

I’m very glad to update to 2.0b1 ,but today i met this problem ,so ask for help at here,
thanks alot

https://lh5.googleusercontent.com/-XhP43pLLtFs/UmoTeB7KpsI/AAAAAAAABI8/rCwA_mbFJv8/s0/overview.png

Hi all,

I upgraded to this on a test system and importing apache logs failed with the following error:


Traceback (most recent call last):
  File "/path/to/piwik/log-analytics/import_logs.py", line 1663, in <module>
    main()
  File "/path/to/piwik/misc/log-analytics/import_logs.py", line 1627, in main
    parser.parse(filename)
  File "/path/to/piwik/misc/log-analytics/import_logs.py", line 1536, in parse
    hit.length = int(format.get('length'))
ValueError: invalid literal for int() with base 10: '-'
PHP Notice:  Use of undefined constant DEBUG_BACKTRACE_IGNORE_ARGS - assumed 'DEBUG_BACKTRACE_IGNORE_ARGS' in /path/to/piwik/core/Log.php on line 439
PHP Notice:  Use of undefined constant DEBUG_BACKTRACE_IGNORE_ARGS - assumed 'DEBUG_BACKTRACE_IGNORE_ARGS' in /path/to/piwik/core/Log.php on line 439

I use the following in /etc/cron.daily/ if it matters


python /path/to/piwik/misc/log-analytics/import_logs.py --url=https://example.com/ --enable-reverse-dns --recorders=4 --enable-bots --useragent-exclude='nagios-plugins' --useragent-exclude='Apache (internal dummy connection)' --useragent-exclude='libwww-perl/6.04' --useragent-exclude='SiteUptime.com' --useragent-exclude='Wget' --useragent-exclude='CloudFlare' --useragent-exclude='WordPress' --useragent-exclude='Pingdom' --useragent-exclude='Ezooms' --add-sites-new-hosts /var/log/piwik/access_log-$(date +%Y%m%d).gz > /var/log/piwik/logs/import.log

php /path/to/piwik/misc/cron/archive.php --url=https://example.com/ > /var/log/piwik/logs/archive.log

Please note I’ve edited my cron so it doesn’t contain my site URL/path, it obviously doesn’t use example.com as the domain haha

@Mooash it seems the problem in your case might be the log which may have wrong data, or data in non expected format. We could catch this exception as invalid log lines. If you can find the line which causes the problem please create a ticket at dev.piwik.org so we can reproduce & fix

Hi,

I have the same problem since the upgrade in 2.0b2 and my log format is good. In 2.0b1 it work very well.

Can you send small log file that lets us reproduce the issue?

Hi Matt,

I’ve send you à MP with a link to download a small log file sample.

This is the debug execution and the stack trace.2013-10-29 01:00:08,465: [DEBUG] Detecting the log format

2013-10-29 01:00:08,465: [DEBUG] Check format icecast2
2013-10-29 01:00:08,465: [DEBUG] Format icecast2 does not match
2013-10-29 01:00:08,465: [DEBUG] Check format iis
2013-10-29 01:00:08,465: [DEBUG] Format iis does not match
2013-10-29 01:00:08,466: [DEBUG] Check format common
2013-10-29 01:00:08,466: [DEBUG] Format common matches
2013-10-29 01:00:08,466: [DEBUG] Check format common_vhost
2013-10-29 01:00:08,466: [DEBUG] Format common_vhost does not match
2013-10-29 01:00:08,466: [DEBUG] Check format nginx_json
2013-10-29 01:00:08,466: [DEBUG] Format nginx_json does not match
2013-10-29 01:00:08,466: [DEBUG] Check format s3
2013-10-29 01:00:08,466: [DEBUG] Format s3 does not match
2013-10-29 01:00:08,466: [DEBUG] Check format ncsa_extended
2013-10-29 01:00:08,466: [DEBUG] Format ncsa_extended matches
2013-10-29 01:00:08,467: [DEBUG] Check format common_complete
2013-10-29 01:00:08,467: [DEBUG] Format common_complete does not match
2013-10-29 01:00:08,467: [DEBUG] Format ncsa_extended is the best match
Traceback (most recent call last):
File “/dsi/www/piwik.dsi.hachette-livre.fr/WebContent/misc/log-analytics/import_logs.py”, line 1663, in
main()
File “/dsi/www/piwik.dsi.hachette-livre.fr/WebContent/misc/log-analytics/import_logs.py”, line 1627, in main
parser.parse(filename)
File “/dsi/www/piwik.dsi.hachette-livre.fr/WebContent/misc/log-analytics/import_logs.py”, line 1536, in parse
hit.length = int(format.get(‘length’))
ValueError: invalid literal for int() with base 10: ‘-’

@sremene Thanks for the report!

it was fixed in Fixes ValueError: invalid literal for int() with base 10: '-' http:/… · matomo-org/matomo@36088b5 · GitHub and tests added in Adding tests with invalid request (see prev commit) · matomo-org/matomo@466dd37 · GitHub

I have a problem with the newser 2.0-b3 and Internet Explorer 8.

in [quote=/var/www/piwik/tmp/assets/asset_manager_global_js.js]

[/quote] seems to be the problem, according to my colleaque. console is not supported on IE8.

greetings
max

Thanks for the report! fixed in: IE8 has no console · matomo-org/matomo@af7d42a · GitHub

can you please apply this patch, then delete all files in: piwik/tmp/assets/*
and try refresh. If the error still appear (or another one) under IE8 please let me know (we don’t run windows only linux and macos so we don’t test with IE8 too often)

ignore this :sunglasses:

tried to reply on this topic, but somehow it seems i made a new topic. can you approve my thread and merge? edit: found it in javascript.back()…

[quote=matt]
Thanks for the report! fixed in: IE8 has no console · matomo-org/matomo@af7d42a · GitHub

can you please apply this patch, then delete all files in: piwik/tmp/assets/*
and try refresh. If the error still appear (or another one) under IE8 please let me know (we don’t run windows only linux and macos so we don’t test with IE8 too often)[/quote]

thanks for the quick support. in my case it was in these files:


$grep -r "Plugin file loaded" /var/www/piwik/
/var/www/piwik/plugins/ExamplePluginTemplate/javascripts/plugin.js:    //console.log('Plugin file loaded');
/var/www/piwik/plugins/CoreConsole/templates/plugin/javascripts/plugin.js:    //console.log('Plugin file loaded');
/var/www/piwik/plugins/ExamplePlugin/javascripts/plugin.js:    //console.log('Plugin file loaded');

i checked out the current master and there it is only in one, so seems fixed.

but still not working in IE8. I managed to find the problem: it is based by jqPlots use of array.reduce() which is not supported by IE8. see MSDN[/url] and/or [url=http://stackoverflow.com/questions/7094935/ie-js-reduce-on-an-object]StackOverflow


# grep -r "series.reduce(" /var/www/piwik/
/var/www/piwik/tmp/assets/asset_manager_global_js.js:var self=this;setTimeout(function(){self.render();},1);},_setJqplotParameters:function(params){defaultParams={grid:{drawGridLines:false,borderWidth:0,shadow:false},title:{show:false},axesDefaults:{pad:1.0,tickRenderer:$.jqplot.CanvasAxisTickRenderer,tickOptions:{showMark:false,fontSize:'11px',fontFamily:window.piwik.jqplotLabelFont||'Arial'},rendererOptions:{drawBaseline:false}},axes:{yaxis:{tickOptions:{formatString:'%d'}}}};this.jqplotParams=$.extend(true,{},defaultParams,params);this._setColors();},_setTooltipPercentages:function(){this.tooltip={percentages:[]};for(var seriesIdx=0;seriesIdx!=this.data.length;++seriesIdx){var series=this.data[seriesIdx];var sum=series.reduce(function(previousValue,currentValue){if($.isArray(currentValue)&&currentValue[1]){return previousValue+currentValue[1];}
/var/www/piwik/plugins/CoreVisualizations/javascripts/jqplot.js:                var sum = series.reduce(function (previousValue, currentValue) {

i tried the solution from Mozilla and just pasted the function in top of /var/www/piwik/plugins/CoreVisualizations/javascripts/jqplot.js


if ('function' !== typeof Array.prototype.reduce) {
  Array.prototype.reduce = function(callback, opt_initialValue){
    'use strict';
    if (null === this || 'undefined' === typeof this) {
      // At the moment all modern browsers, that support strict mode, have
      // native implementation of Array.prototype.reduce. For instance, IE8
      // does not support strict mode, so this check is actually useless.
      throw new TypeError(
          'Array.prototype.reduce called on null or undefined');
    }
    if ('function' !== typeof callback) {
      throw new TypeError(callback + ' is not a function');
    }
    var index, value,
        length = this.length >>> 0,
        isValueSet = false;
    if (1 < arguments.length) {
      value = opt_initialValue;
      isValueSet = true;
    }
    for (index = 0; length > index; ++index) {
      if (this.hasOwnProperty(index)) {
        if (isValueSet) {
          value = callback(value, this[index], index, this);
        }
        else {
          value = this[index];
          isValueSet = true;
        }
      }
    }
    if (!isValueSet) {
      throw new TypeError('Reduce of empty array with no initial value');
    }
    return value;
  };
}

IE8 is still common in some huge companies, just like my customer that pays my coffee :sunglasses: