Jump to content

Extension talk:VisualEditor/2017/02

Add topic
From mediawiki.org

Please note that the Wikimedia Foundation does not provide support for installing VisualEditor on third-party wikis. However, if you have a question we may try to help.

Parsoid error: Error loading data from server: 404: parsoidserver-http: HTTP 404

[edit]

Hello, Visual Editor cannot connect to Parsoid properly, the web browser displays the message Error loading data from server: 404: parsoidserver-http: HTTP 404.

The mediawiki is running inside an intranet at http://172.18.200.40/himtwiki/, I have disabled short URLs for now, it is a private wiki.

$wgGroupPermissions['*'    ]['read']            = false;
  • The system is running on openSUSE 13.1 (Bottle) (x86_64).
  • MediaWiki: 1.25
  • Parsoid: 0.6.1 / 2016-11-14
  • NodeJS: v4.2.4

Parsoid

[edit]
  • I followed the steps from Parsoid/Developer Setup
  • Parsoid resides in /root/parsoid/ for testing now
  • Created config.yaml as following:
        # Configure Parsoid to point to your MediaWiki instances.
        mwApis:
        - # This is the only required parameter,
          # the URL of you MediaWiki API endpoint.
          uri: 'http://172.18.200.40/himtwiki/api.php'
          # The "domain" is used for communication with Visual Editor
          # and RESTBase.  It defaults to the hostname portion of
          # the `uri` property below, but you can manually set it
          # to an arbitrary string.
          domain: 'localhost'  # optional
          prefix: 'localhost'
  • Service is running node bin/server.js
  • Command line output:
{"name":"parsoid","hostname":"server223","pid":793,"level":30,"levelPath":"info/service-runner","msg":"master(793) initializing 4 workers","time":"2017-02-07T13:08:11.107Z","v":0}
{"name":"lib/index.js","hostname":"server223","pid":802,"level":30,"levelPath":"info","msg":"loading ...","time":"2017-02-07T13:08:11.858Z","v":0}
{"name":"lib/index.js","hostname":"server223","pid":802,"level":30,"levelPath":"info","msg":"ready on :8000","time":"2017-02-07T13:08:11.879Z","v":0}
{"name":"lib/index.js","hostname":"server223","pid":807,"level":30,"levelPath":"info","msg":"loading ...","time":"2017-02-07T13:08:12.637Z","v":0}
{"name":"lib/index.js","hostname":"server223","pid":807,"level":30,"levelPath":"info","msg":"ready on :8000","time":"2017-02-07T13:08:12.656Z","v":0}
{"name":"lib/index.js","hostname":"server223","pid":812,"level":30,"levelPath":"info","msg":"loading ...","time":"2017-02-07T13:08:13.403Z","v":0}
{"name":"lib/index.js","hostname":"server223","pid":812,"level":30,"levelPath":"info","msg":"ready on :8000","time":"2017-02-07T13:08:13.422Z","v":0}
{"name":"lib/index.js","hostname":"server223","pid":817,"level":30,"levelPath":"info","msg":"loading ...","time":"2017-02-07T13:08:14.171Z","v":0}
{"name":"lib/index.js","hostname":"server223","pid":817,"level":30,"levelPath":"info","msg":"ready on :8000","time":"2017-02-07T13:08:14.189Z","v":0}
{"name":"parsoid","hostname":"server223","pid":793,"level":40,"levelPath":"warn/service-runner","msg":"Startup finished","time":"2017-02-07T13:08:14.190Z","v":0}

Visual Editor

[edit]
  • I can try to edit existing pages with the Visual Editor, but it fails with Error loading data from server: 404: parsoidserver-http: HTTP 404, now I am looking at other users´ issues with the same error, but nothing has helped so far.
  • Question: I could not really figure out, whether I really need Extension:UniversalLanguageSelector? This one fails to run with error 500.

LocalSettings.php:

wfLoadExtension( 'VisualEditor' );

// Enable by default for everybody
// $wgDefaultUserOptions['visualeditor-enable'] = 1;

// Optional: Set VisualEditor as the default for anonymous users
// otherwise they will have to switch to VE
// $wgDefaultUserOptions['visualeditor-editor'] = "visualeditor";

// Don't allow users to disable it
// $wgHiddenPrefs[] = 'visualeditor-enable';

// OPTIONAL: Enable VisualEditor's experimental code features
#$wgDefaultUserOptions['visualeditor-enable-experimental'] = 1;

$wgVirtualRestConfig['modules']['parsoid'] = array(
	// URL to the Parsoid instance
	// Use port 8142 if you use the Debian package
	'url' => 'http://localhost:8000',
	// Parsoid "domain", see below (optional)
	'domain' => 'localhost',
	// Parsoid "prefix", see below (optional)
	'prefix' => 'localhost'
);
$wgSessionsInObjectCache = true;

Settings for private wiki from https://www.mediawiki.org/wiki/Extension:VisualEditor#Linking_with_Parsoid_in_private_wikis are added, I have also tried switching the wiki to public already.

// This feature requires a non-locking session store. The default session store will not work and
// will cause deadlocks (connection timeouts from Parsoid) when trying to use this feature.
$wgSessionsInObjectCache = true;

// Forward users' Cookie: headers to Parsoid. Required for private wikis (login required to read).
// If the wiki is not private (i.e. $wgGroupPermissions['*']['read'] is true) this configuration
// variable will be ignored.
//
// WARNING: ONLY enable this on private wikis and ONLY IF you understand the SECURITY IMPLICATIONS
// of sending Cookie headers to Parsoid over HTTP. For security reasons, it is strongly recommended
// that $wgVirtualRestConfig['modules']['parsoid']['url'] be pointed to localhost if this setting is enabled.
$wgVirtualRestConfig['modules']['parsoid']['forwardCookies'] = true;

Logs

[edit]
  • /var/log/apache2/error_log shows
    [Wed Feb 08 14:02:15.578020 2017] [php5:error] [pid 8819] [client 172.18.241.85:52765] PHP Notice: Undefined index: prefix in /srv/www/htdocs/himtwiki/includes/libs/virtualrest/ParsoidVirtualRESTService.php on line 71, referer: http://172.18.200.40/himtwiki/index.php/Text_editor?veaction=edit
    but only if prefix is not explicitly defined
  • wiki/tmp/wiki.log
Start request GET /himtwiki/api.php?action=visualeditor&format=json&paction=parse&page=Text_editor&uselang=en
HTTP HEADERS:
HOST: 172.18.200.40
CONNECTION: keep-alive
ACCEPT: application/json, text/javascript, */*; q=0.01
X-REQUESTED-WITH: XMLHttpRequest
USER-AGENT: Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/56.0.2924.87 Safari/537.36
DNT: 1
REFERER: http://172.18.200.40/himtwiki/index.php/Text_editor?veaction=edit
ACCEPT-ENCODING: gzip, deflate, sdch
ACCEPT-LANGUAGE: de,en-US;q=0.8,en;q=0.6
COOKIE: templates-used-list=expanded; himtwikiUserID=170; himtwikiUserName=Imo; himtwikiToken=adc6df740fb9cb31ba950042d64e03d6; himtwiki_session=mg4fnk3071t700afah9bliasf2fknjljfjn0di4hq0sukrv1h5v1; wikiEditor-0-toolbar-section=advanced
[caches] main: EmptyBagOStuff, message: SqlBagOStuff, parser: SqlBagOStuff
Connected to database 0 at 172.18.200.40
Connected to database 0 at 172.18.200.40
[caches] LocalisationCache: using store LCStoreDB
[caches] main: EmptyBagOStuff, message: SqlBagOStuff, parser: SqlBagOStuff
[caches] main: EmptyBagOStuff, message: SqlBagOStuff, parser: SqlBagOStuff
Unstubbing $wgParser on call of $wgParser::setHook from ExtDynamicPageList::setupDPL
Parser: using preprocessor: Preprocessor_DOM
[caches] LocalisationCache: using store LCStoreDB
[caches] LocalisationCache: using store LCStoreDB
Fully initialised
User: cache miss for user 170
[MessageCache] MessageCache::load: Loading en... got from global cache
Gadget::loadStructuredList: MediaWiki:Gadgets-definition parsed, cache entry himtwiki:gadgets-definition:7 updated
User: loading options for user 170 from database.
User: logged in from session
[visualeditor] called on 'Text editor' with paction: 'parse'
[MessageCache] MessageCache::load: Loading en... got from global cache
[MessageCache] MessageCache::load: Loading en... got from global cache
[gitinfo] Computed cacheFile= for /srv/www/htdocs/himtwiki/extensions/VisualEditor
[gitinfo] Cache incomplete for /srv/www/htdocs/himtwiki/extensions/VisualEditor
ApiMain::setCacheMode: setting cache mode private
IP: 172.18.241.85
[GlobalTitleFail] MessageCache::parse called by VisualEditorDataModule::getScript/Message::parse/Message::toString/Message::parseText/MessageCache::parse with no title set.
[GlobalTitleFail] MessageCache::parse called by VisualEditorDataModule::getScript/Message::parse/Message::toString/Message::parseText/MessageCache::parse with no title set.
[GlobalTitleFail] MessageCache::parse called by VisualEditorDataModule::getScript/Message::parse/Message::toString/Message::parseText/MessageCache::parse with no title set.
[GlobalTitleFail] MessageCache::parse called by VisualEditorDataModule::getScript/Message::parse/Message::toString/Message::parseText/MessageCache::parse with no title set.
[GlobalTitleFail] MessageCache::parse called by VisualEditorDataModule::getScript/Message::parse/Message::toString/Message::parseText/MessageCache::parse with no title set.
[GlobalTitleFail] MessageCache::parse called by VisualEditorDataModule::getScript/Message::parse/Message::toString/Message::parseText/MessageCache::parse with no title set.
[GlobalTitleFail] MessageCache::parse called by VisualEditorDataModule::getScript/Message::parse/Message::toString/Message::parseText/MessageCache::parse with no title set.


Thanks in advance Escalatr (talk) 13:40, 8 February 2017 (UTC)Reply

Have you checked Troubleshooting section? Could you create a new page with VE? I'm almost sure the problem is this:
Usually for new installs, this is due to "curl", "php5-curl", or "php7.0-curl" not being installed on your server.
Spas.Z.Spasov (talk) 09:19, 9 February 2017 (UTC)Reply
I can create a new page but Visual Editor fails to save it. I have already checked the Troubleshooting section, missing curl would actually cause a different one: error 500.
r223:/etc/init.d # curl zypper search curl
Loading repository data...
Warning: Repository 'openSUSE-13.1-Update' appears to be outdated. Consider using a different mirror or server.
Reading installed packages...
S | Name                | Summary                                                  | Type
--+---------------------+----------------------------------------------------------+-----------
i | curl                | A Tool for Transferring Data from URLs                   | package
  | curl                | A Tool for Transferring Data from URLs                   | srcpackage
  | curlftpfs           | Filesystem for mounting FTP hosts using FUSE and libcurl | package
  | curlftpfs           | Filesystem for mounting FTP hosts using FUSE and libcurl | srcpackage
  | flickcurl           | Command-Line Tools for the Flickr Web Service            | package
  | flickcurl           | Command-Line Tools for the Flickr Web Service            | srcpackage
  | flickcurl-doc       | C Library API to the Flickr Web Service (Documentation)  | package
  | libcurl-devel       | A Tool for Transferring Data from URLs                   | package
  | libcurl-devel-32bit | A Tool for Transferring Data from URLs                   | package
i | libcurl4            | Version 4 of cURL shared library                         | package
  | libcurl4-32bit      | Version 4 of cURL shared library                         | package
  | libflickcurl-devel  | C Library API to the Flickr Web Service                  | package
  | libflickcurl0       | C Library API to the Flickr Web Service                  | package
  | libflickcurl0-32bit | C Library API to the Flickr Web Service                  | package
  | perl-WWW-Curl       | Perl extension interface for libcurl                     | package
i | php5-curl           | PHP5 Extension Module                                    | package
i | python-pycurl       | PycURL -- cURL library module                            | package
  | python-pycurl-doc   | Documentation for python-curl                            | package
  | python3-pycurl      | PycURL -- cURL library module                            | package
  | python3-pycurl-doc  | Documentation for python-curl                            | package
  | tclcurl             | Tcl Binding to libcurl                                   | package
  | xmms2-plugin-curl   | Curl Support for xmms2                                   | package
According to https://www.mediawiki.org/wiki/Offline_content_generator/Installation/en#Starting I called netstat -tuln, the output:
server223:/etc/init.d # netstat -tuln
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address           Foreign Address         State
tcp        0      0 0.0.0.0:873             0.0.0.0:*               LISTEN
tcp        0      0 127.0.0.1:6379          0.0.0.0:*               LISTEN
tcp        0      0 0.0.0.0:80              0.0.0.0:*               LISTEN
tcp        0      0 0.0.0.0:9200            0.0.0.0:*               LISTEN
tcp        0      0 0.0.0.0:9300            0.0.0.0:*               LISTEN
tcp        0      0 0.0.0.0:21              0.0.0.0:*               LISTEN
tcp        0      0 0.0.0.0:22              0.0.0.0:*               LISTEN
tcp        0      0 127.0.0.1:25            0.0.0.0:*               LISTEN
tcp        0      0 0.0.0.0:6556            0.0.0.0:*               LISTEN
tcp        0      0 :::8000                 :::*                    LISTEN
tcp        0      0 :::873                  :::*                    LISTEN
tcp        0      0 :::3306                 :::*                    LISTEN
tcp        0      0 :::22                   :::*                    LISTEN
udp        0      0 0.0.0.0:57053           0.0.0.0:*
udp        0      0 0.0.0.0:57231           0.0.0.0:*
udp        0      0 0.0.0.0:33014           0.0.0.0:*
udp        0      0 0.0.0.0:54328           0.0.0.0:*
udp        0      0 0.0.0.0:5353            0.0.0.0:*
udp        0      0 0.0.0.0:43376           0.0.0.0:*
udp        0      0 0.0.0.0:47603           0.0.0.0:*
udp        0      0 :::38093                :::*
udp        0      0 :::5353                 :::*
  • tcp 0 0  :::8000  :::* LISTEN should belong to Parsoid, however the address :::8000 looks suspicious to me, should it be 0.0.0.0:8000 with zeros instead, like the other entries? Or even something different like 127.0.0.1:8000?
  • Question: does Parsoid require Redis server (https://redis.io/) to run? I have installed and started Redis service according to https://www.mediawiki.org/wiki/Offline_content_generator/Installation/en#Prerequisites, so tcp 0 0 127.0.0.1:6379 0.0.0.0:* LISTEN belongs to Redis. Escalatr (talk) 09:53, 9 February 2017 (UTC)Reply
  • Is there any chance to debug the URL request by VisualEditor? I have already tried to trace it with Xdebug, but with no success.
  • I am comparing it with mwoffliner.js script which uses Parsoid for dumping Mediawiki content. It gives at least a more concrete message
    Unable to download content [1] http://localhost:8142/Main_Page?oldid=28384 (statusCode=404).
    In my understanding he URL is pointing to a wrong path, it should be something like http://localhost:8142/localhost/v3/page/html/Main_Page/8384 instead (?)
  • The only error messages I can find in wiki.log
    [visualeditor] called on 'Text editor' with paction: 'parse' [MessageCache] MessageCache::load: Loading en... got from global cache [MessageCache] MessageCache::load: Loading en... got from global cache [gitinfo] Computed cacheFile= for /srv/www/htdocs/himtwiki/extensions/VisualEditor [gitinfo] Cache incomplete for /srv/www/htdocs/himtwiki/extensions/VisualEditor ApiMain::setCacheMode: setting cache mode private IP: 172.18.241.85 [GlobalTitleFail] MessageCache::parse called by VisualEditorDataModule::getScript/Message::parse/Message::toString/Message::parseText/MessageCache::parse with no title set. [GlobalTitleFail] MessageCache::parse called by VisualEditorDataModule::getScript/Message::parse/Message::toString/Message::parseText/MessageCache::parse with no title set. [GlobalTitleFail] MessageCache::parse called by VisualEditorDataModule::getScript/Message::parse/Message::toString/Message::parseText/MessageCache::parse with no title set. [GlobalTitleFail] MessageCache::parse called by VisualEditorDataModule::getScript/Message::parse/Message::toString/Message::parseText/MessageCache::parse with no title set. [GlobalTitleFail] MessageCache::parse called by VisualEditorDataModule::getScript/Message::parse/Message::toString/Message::parseText/MessageCache::parse with no title set. [GlobalTitleFail] MessageCache::parse called by VisualEditorDataModule::getScript/Message::parse/Message::toString/Message::parseText/MessageCache::parse with no title set. [GlobalTitleFail] MessageCache::parse called by VisualEditorDataModule::getScript/Message::parse/Message::toString/Message::parseText/MessageCache::parse with no title set.
    Escalatr (talk) 08:01, 13 February 2017 (UTC)Reply
I have the same problem, plz let me know if you fix it one day. WeitongYan (talk) 08:50, 2 March 2018 (UTC)Reply
I could not fix anything yet, probably need to update Mediawiki and all the software Escalatr (talk) 07:53, 4 April 2018 (UTC)Reply
8000 means that IPv6 is used (also on my ubuntu 18.04 server).
Remove the "-" in the parsoid config:
mwApis:
- # This is the only required parameter,
Dont know why there is a "-" in the standard-config but this is one issue ...
After that it was possible to change port and so on. 84.112.225.67 (talk) 11:23, 26 January 2019 (UTC)Reply
the webside removed the ":::" at beginning ... ":::8000" means ipv6 84.112.225.67 (talk) 11:25, 26 January 2019 (UTC)Reply

Images (edit-mode) not shown with https-wiki

[edit]

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


Hi all,

We've a problem when using the Visual Editor with a https-protected wiki (MW version 1.27.1): images in a wikipage aren't displayed when editing a page where this does happen in Read mode.

View source of the page contains:

<a href="/wiki/index.php/File:MyImage.jpg" class="image"><img alt="MyImage.jpg" src="/images/5/5a/MyImage.jpg" width="208" height="199" />

Console of the browser gives this error message: "GET https://localhost/images/5/5a/MyImage.jpg net::ERR_CONNECTION_REFUSED".

How can I fix this problem?

Regards, Jethro Waanders (talk) 19:19, 16 February 2017 (UTC)Reply

I think that problems with images may be the most common difficulty for people that are trying to install VisualEditor. Unfortunately, I don't know how to solve your problem. Perhaps some of the previous threads might hold a clue to your problem? Talk:VisualEditor/2015#h-VE_not_loading_big_pages-2015-11-16T08:33:00.000Z, Extension talk:VisualEditor/2015#h-Missing_picture_during_Visual_Editing.-2015-11-30T13:35:00.000Z and Extension talk:VisualEditor/2013#h-Is_picture_search_in_VE_wikicommons_only?-2013-07-03T06:53:00.000Z look like they might be somewhat related. Whatamidoing (WMF) (talk) 18:25, 20 February 2017 (UTC)Reply
Thanks. Only Extension talk:VisualEditor/2015#h-Missing_picture_during_Visual_Editing.-2015-11-30T13:35:00.000Z is related. I've asked him how he solved the problem, hoping for a reply. Waanders (talk) 13:07, 22 February 2017 (UTC)Reply
If you figure it out, please post the answer at Extension:VisualEditor#Troubleshooting. Whatamidoing (WMF) (talk) 18:31, 22 February 2017 (UTC)Reply
Still a problem unfortunately. Has something to do with domainname wiki. It works okay with our wiki not using a www-address (but ip-address), and NOT with our wiki using a domainname. Waanders (talk) 18:53, 4 April 2017 (UTC)Reply
Fixed! By filling $wgServer in LocalSettings.php with domain name: https://www.mediawiki.org/wiki/Manual:LocalSettings.php#Server_name. Apparently that "automatic detection" did not work for location images. Waanders (talk) 11:27, 5 April 2017 (UTC)Reply
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

Question about <translate> tag

[edit]

Is it possible these tags <translate> ... </translate> to be ignored from VisualEditor? And if the answer is yes how can I do that? Spas.Z.Spasov (talk) 09:38, 17 February 2017 (UTC)Reply

Unfortunately, it's not possible now. This is a problem that the team is thinking about. There is some information about this problem at phab:T155133 and phab:T131516. Whatamidoing (WMF) (talk) 18:16, 20 February 2017 (UTC)Reply

Hello i getting error docserver-http-error: (curl error: 7) Couldn't connect to server

[edit]

After creating new page ant trying to save it i geting error

docserver-http-error: (curl error: 7) Couldn't connect to server

plz help Mindaugasbartusevicius (talk) 21:09, 21 February 2017 (UTC)Reply

Hi,
I've got this error too while trying to edit pages on my Wiki ...
Is there a way to find more debugging infos concerning this ?
I would appreciate to find a way to solve this ! Jeff i (talk) 22:26, 17 April 2017 (UTC)Reply
Same here. Force HSTS enabled. 106.187.39.132 (talk) 10:20, 18 April 2017 (UTC)Reply
I've tried adding most of the debugging parameters into my LocalSettings.php conf file (mentioned here) but maybe too much ! Or probably not revenant returns coz I don't find anything related to any curl error ...
I'm running with my synology NAS and curl binary is a standalone one (ie. not part of a busybox binary :
curl 7.36.0 (i686-pc-linux-gnu) libcurl/7.36.0 OpenSSL/1.0.1t zlib/1.2.8 libssh2/1.4.3
Protocols: dict file ftp ftps gopher http https imap imaps ldap ldaps pop3 pop3s rtsp scp sftp smtp smtps telnet tftp
Features: AsynchDNS IPv6 Largefile NTLM NTLM_WB SSL libz TLS-SRP Jeff i (talk) 20:17, 18 April 2017 (UTC)Reply
Here at the bottom he is suggesting the problem is in SELINUX. I have no idea what that is. I am on Ubuntu 16.
Extension talk:VisualEditor/2015#h-Couldn't_connect_to_server:_parsoidserver-http-error:_(curl_error:_7)-2015-12-07T00:47:00.000Z NitaiDas (talk) 16:36, 11 May 2017 (UTC)Reply
Hello everyone,
This one solved my same exact problem:
Talk:Parsoid/2017#h-parsoidserver-http-error:_(curl_error:_7)_Couldn't_connect_to_server.-2017-01-28T20:13:00.000Z
Formatting as described in above link solved curl 7 error.
So try to achive the exact same on your /etc/mediawiki/parsoid/config.yaml file:
        # Configure Parsoid to point to your MediaWiki instances.
        mwApis:
        - # This is the only required parameter,
         uri: 'https://wiki0.yourdomainname.com/api.php'
         domain: 'wiki0.yourdomainname.com'
        - # This is the only required parameter,
         uri: 'https://wiki1.yourdomainname.com/api.php'
         domain: 'wiki1.yourdomainname.com'
        - # This is the only required parameter,
         uri: 'https://wiki2.yourdomainname.com/api.php'
         domain: 'wiki2.yourdomainname.com'
       # We pre-define wikipedias as 'enwiki', 'dewiki' etc. Similarly
        # for other projects: 'enwiktionary', 'enwikiquote', 'enwikibooks',
        # 'enwikivoyage' etc.
        # The default for this is false. Uncomment the line below if you want
        # to load WMF's config for wikipedias, etc.
        #loadWMF: true
After that my only problem was ssl connection error. Simply drop https in both config.yaml and LocalSettings.php when referring to uri. 176.63.20.111 (talk) 18:09, 22 October 2017 (UTC)Reply
same here cant find any solution.
I insatl 1.29 wiki on centos 6. 59.124.222.126 (talk) 09:44, 1 June 2018 (UTC)Reply
Also have this problem. Having trouble solving it. from what I gather this is error is evidence that my parsoid is not connecting to my mediawiki instance, but I don't understand why. AslanFrench (talk) 21:03, 18 October 2018 (UTC)Reply
Talk:Parsoid/2017#h-parsoidserver-http-error:_(curl_error:_7)_Couldn't_connect_to_server.-2017-01-28T20:13:00.000Z solved my issue too.
In /etc/mediawiki/parsoid/config.yaml, I deleted all empty space before the uri line and made sure there are only spaces (no tabs) before them. Restart parsoid, apache and voila, it works! 73.77.55.61 (talk) 04:26, 21 November 2018 (UTC)Reply
I have wiki running on Ubuntu 18.04 and got the same issue.
I have solved it by uncommenting line 79 of /etc/mediawiki/parsoid/config.yaml which contains "serverPort: 8000".
Of course, you have to restart parsoid after that.
And this port 8000 must be the same in LocalSettings.php in $wgVirtualRestConfig array.

159.69.8.112 (talk) 07:23, 16 February 2019 (UTC)Reply
also getting the same error. using the latest installer. anyway to trace? i did an F12 and don't see any errors Lumengl (talk) 08:14, 28 September 2020 (UTC)Reply

VisualEditor and 500 error in Apache access log

[edit]
Screen shots of errors:
https://drive.google.com/open?id=0B4sThiozQugYTTRzWVFNVEQ3ams
https://drive.google.com/open?id=0B4sThiozQugYekVFbERBN0dNZFE
Apache error shows:
IP ADDRESS - - [26/Feb/2017:00:39:12 +0000] "POST /w/api.php HTTP/1.1" 500 792 "https://wiki.mysite.com/w/index.php?title=Programming_and_IT_Standards&action=edit&redlink=1" "Mozilla/5.0 (Macintosh... 73.115.43.126 (talk) 05:01, 26 February 2017 (UTC)Reply
The Apache error line contains "https://wiki.mysite.com/w/". This isn't a valid address. If you've used that in a config file somewhere, that is your problem: it's supposed to be just an example that has to be replaced with the URL of your MediaWiki site (or have I misunderstood and that line is just a "cleaned-up" version of the real error line?).
Have you verified that your Parsoid server is up and running by visiting http://yourparsoidserver.com:8000/ (or 8142, depending on which flavour of Parsoid you installed)? And yourparsoidserver.com can be a valid URL if the Apache and Parsoid servers are on different machines, or it can be localhost if they are on the same machine. JohnNew (talk) 05:35, 26 February 2017 (UTC)Reply
Thanks John, you're right I cleaned up the logs to remove any identifying information. I'm using port 8143 (which then connects on the backend to 8142) in the below link because I've enabled Stunnel for a secure connection. Even though they're on the same server I thought maybe because I was using SSL exclusively in Apache that it was causing an issue. I have valid signed certificates tied to both services. I only get a 500 error when using VisualEditor either immediately when trying to Edit or when I try to save a page I created. I've even enabled all logging in PHP and turned on showing errors. No PHP errors are generated. The only error I'm getting is the one above in the Apache access.log when it attempts to POST. I'm including more log entries below.
IPADDRESS - - [26/Feb/2017:04:59:56 +0000] "GET /w/load.php?debug=false&lang=en&modules=ext.visualEditor.desktopArticleTarget.noscript%7Cmediawiki.helplink%2CsectionAnchor%2Cspecial%2Cui%7Cmediawiki.legacy.commonPrint%2Cshared%7Cmediawiki.skinning.interface%7Cmediawiki.special.search.styles%7Cmediawiki.ui.button%2Cinput%7Cmediawiki.widgets.SearchInputWidget.styles%7Cmediawiki.widgets.styles%7Coojs-ui-core.styles%7Coojs-ui.styles.icons%2Cindicators%2Ctextures%7Cskins.vector.styles&only=styles&skin=vector HTTP/1.1" 304 429 "https://wiki.mysite.com/w/index.php?search=Problems&title=Special%3ASearch&go=Go" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_3) AppleWebKit/602.4.8 (KHTML, like Gecko) Version/10.0.3 Safari/602.4.8"
IPADDRESS - - [26/Feb/2017:04:59:56 +0000] "GET /w/opensearch_desc.php HTTP/1.1" 200 811 "-" "com.apple.Safari.SearchHelper/12602.4.8 CFNetwork/807.2.14 Darwin/16.4.0 (x86_64)"
IPADDRESS - - [26/Feb/2017:04:59:58 +0000] "GET /w/index.php?title=Problems&action=edit&redlink=1 HTTP/1.1" 200 5999 "https://wiki.mysite.com/w/index.php?search=Problems&title=Special%3ASearch&go=Go" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_3) AppleWebKit/602.4.8 (KHTML, like Gecko) Version/10.0.3 Safari/602.4.8"
IPADDRESS - - [26/Feb/2017:04:59:58 +0000] "GET /w/load.php?debug=false&lang=en&modules=ext.visualEditor.desktopArticleTarget.noscript%7Cmediawiki.action.edit.styles%7Cmediawiki.legacy.commonPrint%2Cshared%7Cmediawiki.sectionAnchor%7Cmediawiki.skinning.interface%7Cskins.vector.styles&only=styles&skin=vector HTTP/1.1" 304 291 "https://wiki.mysite.com/w/index.php/Main_Page?action=edit&veswitched=1" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_3) AppleWebKit/602.4.8 (KHTML, like Gecko) Version/10.0.3 Safari/602.4.8"
IPADDRESS - - [26/Feb/2017:04:59:58 +0000] "GET /w/opensearch_desc.php HTTP/1.1" 200 811 "-" "com.apple.Safari.SearchHelper/12602.4.8 CFNetwork/807.2.14 Darwin/16.4.0 (x86_64)"
IPADDRESS - - [26/Feb/2017:05:00:00 +0000] "GET /w/api.php?action=visualeditor&format=json&paction=parse&page=Problems&uselang=en&oldid=0 HTTP/1.1" 200 972 "https://wiki.mysite.com/w/index.php?title=Problems&action=edit&redlink=1" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_3) AppleWebKit/602.4.8 (KHTML, like Gecko) Version/10.0.3 Safari/602.4.8"
IPADDRESS - - [26/Feb/2017:05:00:00 +0000] "POST /w/api.php HTTP/1.1" 200 790 "https://wiki.mysite.com/w/index.php?title=Problems&action=edit&redlink=1" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_3) AppleWebKit/602.4.8 (KHTML, like Gecko) Version/10.0.3 Safari/602.4.8"
IPADDRESS - - [26/Feb/2017:05:00:00 +0000] "POST /w/api.php HTTP/1.1" 200 790 "https://wiki.mysite.com/w/index.php?title=Problems&action=edit&redlink=1" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_3) AppleWebKit/602.4.8 (KHTML, like Gecko) Version/10.0.3 Safari/602.4.8"
IPADDRESS - - [26/Feb/2017:05:00:01 +0000] "GET /w/index.php?title=Problems&action=edit&redlink=1 HTTP/1.1" 200 5989 "https://wiki.mysite.com/w/index.php?title=Problems&action=edit&redlink=1" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_3) AppleWebKit/602.4.8 (KHTML, like Gecko) Version/10.0.3 Safari/602.4.8"
IPADDRESS - - [26/Feb/2017:05:00:04 +0000] "POST /w/api.php HTTP/1.1" 500 655 "https://wiki.mysite.com/w/index.php?title=Problems&action=edit&redlink=1" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_3) AppleWebKit/602.4.8 (KHTML, like Gecko) Version/10.0.3 Safari/602.4.8"
IPADDRESS - - [26/Feb/2017:05:00:06 +0000] "POST /w/api.php HTTP/1.1" 500 792 "https://wiki.mysite.com/w/index.php?title=Problems&action=edit&redlink=1" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_3) AppleWebKit/602.4.8 (KHTML, like Gecko) Version/10.0.3 Safari/602.4.8"
If I send "curl -L https://wiki.mysite.com:8143/wiki.mysite.com/v3/page/html/Main_Page"
<!DOCTYPE html>
<html prefix="dc: http://purl.org/dc/terms/ mw: http://mediawiki.org/rdf/" about="https://wiki.mysite.com/w/index.php/Special:Redirect/revision/1"><head prefix="mwr: https://wiki.mysite.com/w/index.php/Special:Redirect/"><meta charset="utf-8"/><meta property="mw:articleNamespace" content="0"/><link rel="dc:replaces" resource="mwr:revision/0"/><meta property="dc:modified" content="2017-02-15T19:19:34.000Z"/><meta property="mw:revisionSHA1" content="3b35bb5dedd5f6980415f4918b3d60d2248c89cb"/><meta property="mw:html:version" content="1.2.1"/><meta property="mw:data-parsoid:version" content="0.0.2"/><link rel="dc:isVersionOf" href="https://wiki.mysite.com/w/index.php/Main_Page"/><title>Main_Page</title><base href="https://wiki.mysite.com/w/index.php/"/><link rel="stylesheet" href="//wiki.mysite.com/w/load.php?modules=mediawiki.legacy.commonPrint,shared|mediawiki.skinning.content|mediawiki.skinning.content.parsoid|mediawiki.skinning.elements|mediawiki.skinning.interface|site|skins.vector.styles|ext.cite.style&amp;only=styles&amp;skin=vector"/></head><body data-parsoid='{"dsr":[0,717,0,0]}' lang="en" class="mw-content-ltr sitedir-ltr ltr mw-body mw-body-content mediawiki" dir="ltr"><p data-parsoid='{"dsr":[0,46,0,0]}'><strong data-parsoid='{"stx":"html","dsr":[0,46,8,9]}'>MediaWiki has been installed.</strong></p>
<p data-parsoid='{"dsr":[48,164,0,0]}'>Consult the <a rel="mw:ExtLink" href="https://meta.wikimedia.org/wiki/Help:Contents" data-parsoid='{"targetOff":107,"contentOffsets":[107,119],"dsr":[60,120,47,1]}'>User's Guide</a> for information on using the wiki software.</p>
<h2 data-parsoid='{"dsr":[166,187,2,2]}'> Getting started </h2>
<ul data-parsoid='{"dsr":[188,717,0,0]}'><li data-parsoid='{"dsr":[188,299,1,0]}'> <a rel="mw:ExtLink" href="https://www.mediawiki.org/wiki/Special:MyLanguage/Manual:Configuration_settings" data-parsoid='{"targetOff":271,"contentOffsets":[271,298],"dsr":[190,299,81,1]}'>Configuration settings list</a></li>
<li data-parsoid='{"dsr":[300,378,1,0]}'> <a rel="mw:ExtLink" href="https://www.mediawiki.org/wiki/Special:MyLanguage/Manual:FAQ" data-parsoid='{"targetOff":364,"contentOffsets":[364,377],"dsr":[302,378,62,1]}'>MediaWiki FAQ</a></li>
<li data-parsoid='{"dsr":[379,477,1,0]}'> <a rel="mw:ExtLink" href="https://lists.wikimedia.org/mailman/listinfo/mediawiki-announce" data-parsoid='{"targetOff":446,"contentOffsets":[446,476],"dsr":[381,477,65,1]}'>MediaWiki release mailing list</a></li>
<li data-parsoid='{"dsr":[478,603,1,0]}'> <a rel="mw:ExtLink" href="https://www.mediawiki.org/wiki/Special:MyLanguage/Localisation#Translation_resources" data-parsoid='{"targetOff":566,"contentOffsets":[566,602],"dsr":[480,603,86,1]}'>Localise MediaWiki for your language</a></li>
<li data-parsoid='{"dsr":[604,717,1,0]}'> <a rel="mw:ExtLink" href="https://www.mediawiki.org/wiki/Special:MyLanguage/Manual:Combating_spam" data-parsoid='{"targetOff":679,"contentOffsets":[679,716],"dsr":[606,717,73,1]}'>Learn how to combat spam on your wiki</a></li></ul></body></html> P924s87 (talk) 17:10, 26 February 2017 (UTC)Reply
Have you ever gotten VE/Parsoid to work, even on a non-SSL setup? I know I am battling my own demons when it comes to VE/Parsoid/RESTBase and SSL. Maybe if you could disable SSL temporarily it would at least remove one variable from the equation for now (hopefully this isn't a production setup).
Also, what does the Network Console say in your browser when you try to load VE? You can get lots of good troubleshooting info from that panel that might help. JohnNew (talk) 17:47, 26 February 2017 (UTC)Reply