Classes/Console/Extension/ExtensionCompatibilityCheck.php
public function isCompatible($extensionKey, $configOnly = false)
    {
        try {
            if ($configOnly) {
                return $this->canLoadExtLocalconfFile($extensionKey);
            }

            return $this->canLoadExtTablesFile($extensionKey);
        } catch (\Throwable $e) {
            return false;
        }
    }
public function isCompatible($extensionKey, $configOnly = false)
    {
        try {
            if ($configOnly) {
                return $this->canLoadExtLocalconfFile($extensionKey);
            }

            return $this->canLoadExtTablesFile($extensionKey);
        } catch (\Throwable $e) {
            return false;
        }
    }
This method is meant to be called form a sub process
specifically from upgrade:checkextensioncompatiblity command

@param string $extensionKey
@param bool $configOnly
@return bool