Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/matomo-org/matomo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--CHANGELOG.md1
m---------misc/log-analytics0
-rw-r--r--tests/PHPUnit/Framework/Fixture.php19
3 files changed, 16 insertions, 4 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 985bb5fd19..0f1d261128 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -126,6 +126,7 @@ The following changes are recommendations and don't have to be done as we will s
### Other Breaking changes
+* The log importer in `misc/log-analytics` now supports Python 3 (3.5, 3.6 or 3.7), it will no longer run with Python 2. If you have any automated scripts that run the importer, you will have to change them to use the Python 3 executable instead.
* Deprecated `piwik` font was removed. Use `matomo` font instead
* The JavaScript AjaxHelper does not longer support synchronous requests. All requests will be sent async instead.
* The console option `--piwik-domain` has been removed. Use `--matomo-domain` instead
diff --git a/misc/log-analytics b/misc/log-analytics
-Subproject b1b877b2a99eef22fff13bfd69d5c38e15ab8b3
+Subproject 84fe9c9fdc8ce695bcffbe9dfb773f02bc5e414
diff --git a/tests/PHPUnit/Framework/Fixture.php b/tests/PHPUnit/Framework/Fixture.php
index c02f845cec..b76a3b1d66 100644
--- a/tests/PHPUnit/Framework/Fixture.php
+++ b/tests/PHPUnit/Framework/Fixture.php
@@ -124,12 +124,17 @@ class Fixture extends \PHPUnit\Framework\Assert
*/
protected static function getPythonBinary()
{
- if (SettingsServer::isWindows()) {
- return "C:\Python27\python.exe";
+ $matomoPythonPath = getenv('MATOMO_TEST_PYTHON_PATH');
+ if ($matomoPythonPath) {
+ return $matomoPythonPath;
}
- if (SystemTestCase::isTravisCI()) {
- return 'python2.7';
+ if (SettingsServer::isWindows()) { // just a guess really
+ return "C:\Python35\python.exe";
+ }
+
+ if (self::isExecutableExists('python3')) {
+ return 'python3';
}
return 'python';
@@ -149,6 +154,12 @@ class Fixture extends \PHPUnit\Framework\Assert
return $command;
}
+ private static function isExecutableExists(string $command)
+ {
+ $out = `which $command`;
+ return !empty($out);
+ }
+
public static function getTestRootUrl()
{
return self::getRootUrl() . 'tests/PHPUnit/proxy/';