When i try to open configuration page of search API module i am getting the below error:

The website encountered an unexpected error. Please try again later. Error: Class "Composer\InstalledVersions" not found in Solarium\Client::getVersion() (line 59 of vendor\solarium\solarium\src\Client.php).

I have checked the place where it is stating error but it is updated as per the recent package.

use Composer\InstalledVersions;

 * Returns the version string.
 * @return string
public static function getVersion(): string
    static $version;

    if (!$version) {
        $version = InstalledVersions::getPrettyVersion('solarium/solarium');

    return $version;

Help me to fix the issue.

  • That looks like an auto loader problem. It will be difficult to answer this without more information.
    – cilefen
    Dec 22, 2022 at 11:31
  • Hi @cilefen, Can you please tell me the details required for answering or how to fix this issue.
    – sudhan
    Dec 22, 2022 at 11:33
  • In short it means vendor/composer/InstalledVersions.php is missing or cannot be autoloaded. That is all I can say given the information you provided.
    – cilefen
    Dec 22, 2022 at 13:34


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.