Indeed, this scheme would require the resulting extension to be deployed,
along with all the red tape that that entails. (The red tape isnt as bad as
it used to be imo, but there still is some)

Im unsure if it would have to follow the usual rules for deployed
extensions if it solely consisted of js modules that are never loaded by
default (e.g. extension requires initial security review, all changes have
to be code reviewed by someone other than the author of the patch)

--
Brian

On Friday, April 7, 2017, Felipe Schenone <[email protected]> wrote:
> Brion, that's just brilliant. But wouldn't the extension need to be
> installed on each Wikipedia for the module to be available?
>
> On Fri, Apr 7, 2017 at 4:12 PM Chico Venancio <[email protected]>
> wrote:
>
>> Brian,
>> No, and I always felt there was a better way to do this. I'll look into
>> that, thanks,
>>
>> Chico Venancio
>>
>> 2017-04-07 15:45 GMT-03:00 Brian Wolff <[email protected]>:
>>
>> > On Friday, April 7, 2017, Felipe Schenone <[email protected]> wrote:
>> > > Hi all! I'm the main developer of the ProveIt gadget
>> > > <https://commons.wikimedia.org/wiki/Help:Gadget-ProveIt>, a reference
>> > > manager for Wikipedia. The code is tracked via Phabricator, reviewed
>> via
>> > > Gerrit, and served to the various Wikipedias from Commons. Each wiki
>> has
>> > a
>> > > unique initialization code
>> > > <https://en.wikipedia.org/wiki/MediaWiki:Gadget-ProveIt.js> that sets
>> > some
>> > > local config and then requests the main code from Commons
(JavaScript,
>> > CSS
>> > > and JSON). Every time I merge a new change via Gerrit, I need to
>> manually
>> > > update the Commons pages so that the Wikipedias have the latest code.
>> > >
>> > > This is sub-optimal. Ideally, the Wikipedias should request the code
>> > > directly from Diffusion, so that when developers merge new changes,
>> they
>> > > are immediately available (and we don't need interface rights or
manual
>> > > work in Commons). However, when I go to the Diffusion of the gadget
>> > > <https://phabricator.wikimedia.org/diffusion/1884/>, click on the
main
>> > > proveit.js file, and click on "View Raw File", I get to a URL like
the
>> > > following:
>> > >
>> > https://phab.wmfusercontent.org/file/data/iapd7kogqo5x2naywwlq/PHID-
>> > FILE-dkxynh42aocsg5gmepxw/proveit.js
>> > > The URL of the raw file changes with every click and doesn't have the
>> > > proper MIME type header, so it's useless for serving the code.
>> > >
>> > > I think it would be very useful, for my case and others, to have a
>> stable
>> > > URL that serves the latest code with the proper MIME type heading. In
>> > other
>> > > words, a CDN, which may or may not be integrated with Diffusion.
>> > >
>> > > Thanks!
>> > > _______________________________________________
>> > > Wikitech-l mailing list
>> > > [email protected]
>> > > https://lists.wikimedia.org/mailman/listinfo/wikitech-l
>> >
>> > Hmm, we should do something better for this. In the mean time, have you
>> > considered packaging the javascript as a mediawiki extension that just
>> adds
>> > it as a module? Then the gadget could simply be a mw.loader.load(
>> > moduleName ) call.
>> >
>> > --
>> > bawolff
>> > _______________________________________________
>> > Wikitech-l mailing list
>> > [email protected]
>> > https://lists.wikimedia.org/mailman/listinfo/wikitech-l
>> >
>> _______________________________________________
>> Wikitech-l mailing list
>> [email protected]
>> https://lists.wikimedia.org/mailman/listinfo/wikitech-l
> _______________________________________________
> Wikitech-l mailing list
> [email protected]
> https://lists.wikimedia.org/mailman/listinfo/wikitech-l
_______________________________________________
Wikitech-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikitech-l

Reply via email to