Page MenuHomePhabricator

Issues Getting shortURLs to work with VisualEditor -- Error contacting the Parsoid/RESTBase server (HTTP 500)
Closed, ResolvedPublicBUG REPORT

Description

Setup:
Wiki Link
Shared hosting, Siteground

Apache/Nginx Compatible Server

No Root Access
Product Version
MediaWiki 1.35.1
PHP 7.3.25 (cgi-fcgi)
MySQL 5.7.26-29-log
ICU 63.2

My installation is nested in a /w folder.

When the user follows the steps provided by MediaWiki on creating Short URLS outlined in the manual and attempts to use VisualEditor, the following occurs:

Actual Results:

Error contacting the Parsoid/RESTBase server (HTTP 500)

Expected Results:
VisualEditor works as intended, allowing the user to use the extension to edit the page.

Steps to Reproduce:

  1. Install Mediawiki 1.35.1.
  2. Nest your installation in a folder called "w".
  3. In the root folder (in my case, it is public_html), create a new file called ".htaccess".
  4. In LocalSettings.php, enter the following: "$wgScriptPath = "/w"; $wgArticlePath = "/wiki/$1";"
  5. While in LocalSettings.php, enter "wfLoadExtension( 'VisualEditor' );" to enable VisualEditor.
  6. On the site itself, click "edit" and observe the results.

To see the issue Live, I have provided the following credentials on the wiki:
User: Testuser
Pass: debug

Event Timeline

In your Apache config, you should adapt the redirect rules so that https://wiki.twistedfates.net/w/rest.php/wiki.twistedfates.net/v3/page/html/Main_Page/1?redirect=false is handled by the rest.php entry point. I’m not sure what is exatly the Apache config (I know better nginx), but T265043 gives some hints. When it will work, could you can contribute your working config on the help page to help other Apache users?

Also, you should also add AllowEncodedSlashes NoDecode in your Apache config for this entry point (see VisualEditor documentation; absence of this parameter leads to issues when titles contain slashes).

@Seb35 Heya, thanks for reaching out to me!
Unfortunately, I don't have root access as I'm on a shared server, so I think I don't have access to an Apache config file. Thank you for pointing me to #T265043 though, I'll see what I can find!

Heads up, I installed Mediawiki from the site itself, followed the manual, and so far have had no issues with Visual Editor. I initially installed through my hosting provider, Siteground, and it seems like there were some issues with the installation itself?

If it is solved and you have no actionable to debug your original installation, I guess we should close this issue?

Also, if I understand correctly, you initially installed with some automatic installation provided by Siteground? If it is the case and you want to be kind to them, you can drop them a message to let them know that there could be issues with the VisualEditor.

(Nice skin customisations BTW ;)

Oh yeah, totally! I'll reach out to them and let them know. Thank you so much for your help @Seb35!