Topic on Project:Support desk

Jump to navigation Jump to search

Bugs in Math Extension after upgrading to 1.35

11
Summary by Fokebox

The issue has been resolved by upgrading extension to curl 7.29.0 (x86_64-redhat-linux-gnu) // A topic on the issue was created on phabricator

Fokebox (talkcontribs)

I have upgraded my Wiki to 1.35. Installed Math Extension and set following settings at my LocalSettings file:

wfLoadExtension( 'Math' );
$wgDefaultUserOptions['math'] = 'mathml';
$wgMathFullRestbaseURL = 'https://en.wikipedia.org/api/rest_';

1) After that I go to any page with math formula I see the error on the top:

Warning: Use of undefined constant CURLMOPT_MAX_HOST_CONNECTIONS - assumed 'CURLMOPT_MAX_HOST_CONNECTIONS' (this will throw an Error in a future version of PHP) in /var/www/u0402490/data/www/mysite/includes/libs/http/MultiHttpClient.php on line 448

Warning: curl_multi_setopt() expects parameter 2 to be int, string given in /var/www/u0402490/data/www/mysite/includes/libs/http/MultiHttpClient.php on line 448

Warning: Use of undefined constant CURLMOPT_MAX_HOST_CONNECTIONS - assumed 'CURLMOPT_MAX_HOST_CONNECTIONS' (this will throw an Error in a future version of PHP) in /var/www/u0402490/data/www/mysite/includes/libs/http/MultiHttpClient.php on line 448

Warning: curl_multi_setopt() expects parameter 2 to be int, string given in /var/www/u0402490/data/www/mysite/includes/libs/http/MultiHttpClient.php on line 448

but math formulas are displayed at the same time. If I refresh the page, the error disappears and never returns.

If I create page with Math formula in Wiki editor and click "Preview" I also see this error, but math formula is shown. I see the same error at: Special:MathStatus. And at this all tested well except this: Comparing the generated SVG with the reference failed

When I use VisualEditor to insert math formulas - all works perfect.

Could you please let me know why I have this error and how can I fix it?

Bawolff (talkcontribs)

is the php curl extension installed (this is a php extension not a mediawiki extension) and what version?

What version of php do you have? Is it at least 7.0.7?

Fokebox (talkcontribs)

Yes, my hosting confirmed that the extension is installed. Just an case here is my page with math status and error: Link

Fokebox (talkcontribs)

Here what I have:

Продукт Версия
MediaWiki 1.35.0
PHP 7.4.10 (cgi-fcgi)
MySQL 5.7.27-30
ICU 50.1.2
Lua 5.1.5
Ammarpad (talkcontribs)

Ask your hosting provider what version of cURL extension is installed.

Fokebox (talkcontribs)

cURL is 7.29.0

Ammarpad (talkcontribs)

The constant was added in cURL 7.30.0, so it's not available in your version.

Fokebox (talkcontribs)

Thank you! I try to request my hosting to update the extension.

Bawolff (talkcontribs)
Fokebox (talkcontribs)

The issue has been resolved by upgrading curl to curl 7.29.0 (x86_64-redhat-linux-gnu) // A topic on the issue was created on phabricator

Fokebox (talkcontribs)

I also requested my hosting to upgrade curl extension. As soon as they do it, I check if everything works fine.