Composer Installation 7.6: Fatal error: require_once(): Failed opening required 'Net/URL2.php'
If I try to get sphinx to wake up, I always end up in a fatal error.Steps to reproduce:
- TYPO3 7.6.5, PHP 5.5
- Installation of CMS and sphinx and restdoc via Composer
- Enable both extensions in Extension Manager
- Then "Configure Extension sphinx" from Extension Manager
- Clicking on No versions of Sphinx available Please run Update script first.
- Fatal error
Fatal error: require_once(): Failed opening required 'Net/URL2.php' (include_path='/var/www/html/domain/vendor/pear/pear_exception:/var/www/html/domain/typo3_src/vendor/pear/http_request2:/var/www/html/domain/typo3_src/vendor/pear/net_url2:.:/usr/share/php:/usr/share/pear') in /var/www/html/domain/vendor/pear/http_request2/HTTP/Request2.php on line 24
#1 Updated by Alex Kellner over 3 years ago
The note under https://github.com/georgringer/page_speed#avoid-error-require_onceneturl2php leads me to the file:
Change both require statements at the top, prevents the Fatal Error:
... require_once __DIR__ . '/../../net_url2/Net/URL2.php'; ... require_once __DIR__ . '/Request2/Exception.php';
But this will lead to:
Could not find any version of Sphinx: Are you currently offline? Does PHP have proper OpenSSL support?
Install Tool and phpinfo() shows on my Ubuntu:
PHP OpenSSL extension installed properly
BTW: sphinx 2.2.0 works on the same machine with TYPO3 6.2 - message:
- Sphinx 1.2.3 has been successfully installed.
- PyYAML successfully installed.
- TypoScript library successfully registered with Pygments.
- Pygments successfully installed.
- TYPO3 RestructuredText Tools successfully installed.
#4 Updated by Xavier Perseguers over 3 years ago
This message means no versions could be extracted from https://github.com/sphinx-doc/sphinx/releases
The fetch is done using
\Causal\Sphinx\Utility\MiscUtility::getUrlWithCache() which uses a local cache. So maybe the only problem is if you switched from a broken version of EXT:sphinx to the master branch in less than 1 day? Make sure you purge any cache file under
typo3temp/sphinx.<md5>.html and try again. If it still fails, have a look at the generated cache file, I basically extract data from the UL list:
<ul class="release-timeline-tags"> ... </ul>
#5 Updated by Alex Kellner over 3 years ago
- I cleaned the complete typo3temp folder
- I tried to run the update script again
- Same error (see screenshot from my last comment)
- Watched in folder typo3temp - there is no sphinx.<md5>.html
- Watched in folder typo3temp/tx_sphinx - there are no files
If I do a var_dump (in another installed extension) on
$html = \Causal\Sphinx\Utility\MiscUtility::getUrlWithCache('https://github.com/sphinx-doc/sphinx/releases');
The result value is "false"
If I would do a
$html = \TYPO3\CMS\Core\Utility\GeneralUtility::getUrl('https://github.com/sphinx-doc/sphinx/releases');
the html is loaded correctly