Hi Vadim,

We cannot guarantee Parsoid will continue to function with older MW versions. We have enough complexity as is and we do not intend to take on workarounds to deal with older MW versions.

That said, we are considering an option where you can "hack up" a base config file that you can use with your wiki that can fill in missing gaps in the API. This is at best a hack and no guarantees it will do what you need, but it could very well do the trick. See the discussion on https://gerrit.wikimedia.org/r/#/c/194030/ . We cannot work on this task on a high priority, but once done, this might help with some of the issues you are encountering.

Best,
Subbu.

On 04/22/2015 10:56 AM, Vadim Shlyakhov wrote:
Hello,

Some older versions of Mediawiki (1.16) do not provide "mediatype" in "iiprop" for media. Then its worker crashes when it tries to parse a reply from a server.

Here is workaround for an issue:

--- ext.core.LinkHandler.js-    2015-04-22 15:30:04.000000000 +0300
+++ ext.core.LinkHandler.js    2015-04-22 17:03:11.000000000 +0300
@@ -1011,7 +1012,11 @@
         // Add (read-only) information about original file size (T64881)
         img.addAttribute( 'data-file-width', info.width );
         img.addAttribute( 'data-file-height', info.height );
-        img.addAttribute( 'data-file-type', info.mediatype.toLowerCase() );
+        if (info.mediatype) {
+            img.addAttribute( 'data-file-type', info.mediatype.toLowerCase() );
+        }
     }
 
     if ( hasImageLink ) {



Is it possible implement it into the Parsoid.

Regards
Vadim


_______________________________________________
Wikitext-l mailing list
Wikitext-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikitext-l