[MediaWiki-l] is there a way to get all js/css module dependencies for a given wikimedia page ?

Damien Accorsi damien.accorsi at free.fr
Wed Apr 5 08:54:17 UTC 2017


Le 05/04/2017 à 09:31, Côme HUGUIES a écrit :
> Hello,
>
> I'm Côme (Skylsmoi) and I am working with Kelson (from Kiwix) on the
> mwoffliner.
> I am trying to mirror locally every js and css resources from original
> articles for an offline use.
>
> [...]
Hello all,

I'm working with Skylsmoi on the project. The global question we are 
trying to answer is : "how to get the exhaustive list of ressources 
required by a given wikimedia page". The example Skylsmoi worked on is 
the page of Lyon city - https://en.wikipedia.org/wiki/Lyon

The problem is that the page depends on some modules which depends on 
some other modules which... a recursive dependency workflow based on 
javascript dynamic code. So... it is pretty impossible to get the fully 
exhaustive dependency list without to execute the javascript code itself.

As you may (or may not) know, kiwix is the project that target to allow 
to mirror some wikimedia-based website in order to give access offline. 
mwoffliner (the module we are working on) is in charge of downloading 
all required stuff. That's why we try to get the exhaustive list.

/Kelson/ initially pointed us to the load.php endpoint which returns 
some dependancies... unfortunatelly, it does not return all dependencies 
(or we do not use it the right way).

Better than to reverse-engineer the entire wikimedia source code, asking 
for ideas / directions here, on the mailing list can help. (or even if 
the response is "it's impossible" will help)

Thanks in advance for any help you can give us.

Have a great day.

Damien



More information about the MediaWiki-l mailing list