Fatal error: Class 'Piwik\SettingsServer' on installation

Hello all,

Just re-uploaded Matomo to my web server since my old one broke when i made an automatic update.
Also, there was plenty of error calling API.

So, since i lost all other data, i wanted to reinstall it back.
Uploaded to webserver, got Fatal error: Class ‘Piwik\Settings Server’ not found

I just want to know how can it occur, i’m not sure to use Matomo since this software is full of bug and unstable (10 091 issues on GiHub (this is craaaaazy)), but just want to know, because, i’m pretty sure that this is the developer team forgot to upload somes files.

Tried every possible way, also tried directly with Git, got this same error.

Anybody already had this error ?

Thanks

I have the same problem. It looks like this version (Matomo 3.9.1 from Changelog file lates version from https://builds.matomo.org/matomo-latest.zip ) includes a wrong fork of code. At least the OLD NAME “PIWIK” is used. Maybe a confusion or copy paste error of a class.
Fatal error: Class ‘Piwik\SettingsServer’ not found in SERVERPATH_/matomo/core/testMinimumPhpVersion.php on line 87
Maybe You can check this.
Thank You.
Martin

Hi @atbirder,

This is not a typo, many parts of the code are still called Piwik as changing it would break all plugins and more.

Piwik\SettingsServer should definitly exist in the core/SettingsServer.php file. Can you check if it by chance got corrupted?

I found why i got this error.

So, imagine that the version of Github can not be deployed in public.
Matomo had the brillant (not at all) idea to make Github repositorie available only to developper.

I know, it’s very bizzard, even stupid.
So, you have to download the build ZIP from

https://builds.piwik.org/

There’s a lack of documentation for Matomo project.

Hi,

As every Github release explains the version from git is not intended to be used in production as a few manual steps need to be made

You can see the script that creates the zip from the git repository here:
https://github.com/matomo-org/matomo-package/blob/master/scripts/build-package.sh

The main difference is that git submodules are checked out and composer dependencies are downloaded.

Tbh, i never saw any Github project that didn’t allow production deployment.

Edit: @Lukas, You can see the script that creates the zip from the git repository here: matomo-package/build-package.sh at master · matomo-org/matomo-package · GitHub

I did not know anything about that. I did not see it in the documentation.
Thanks for that, and sorry for what I said, it’s rather me the stupid who did not do his research.

Thanks alot Lukas.

Dear Lukas,
Thakn You for Your reply.

I checked the line on PHP version. Looks OK.

    /**
     * Returns `true` if this PHP version/build supports timezone manipulation
     * (e.g., php >= 5.2, or compiled with **EXPERIMENTAL_DATE_SUPPORT=1** for
     * php < 5.2).
     *
     * @return bool
     * @api
     */
    public static function isTimezoneSupportEnabled()
    {

Best, Martin