<div dir="ltr">Many thanks for taking time to give good answers.  Lots of useful stuff in there I'll have to process.<div><br></div><div>Regards,</div><div>GoldenRing</div></div><div class="gmail_extra"><br><div class="gmail_quote">On 6 April 2015 at 17:11, Ricordisamoa <span dir="ltr"><<a href="mailto:ricordisamoa@openmailbox.org" target="_blank">ricordisamoa@openmailbox.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
  
    
  
  <div text="#000000" bgcolor="#FFFFFF"><span class="">
    Il 06/04/2015 08:27, Golden Ring ha scritto:<br>
    <blockquote type="cite">
      <div dir="ltr">
        <div class="gmail_extra">
          <div class="gmail_quote">On 6 April 2015 at 14:03,
            Ricordisamoa <span dir="ltr"><<a href="mailto:ricordisamoa@openmailbox.org" target="_blank">ricordisamoa@openmailbox.org</a>></span>
            wrote:<br>
            <blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
              <div text="#000000" bgcolor="#FFFFFF"><span> Il
                  06/04/2015 02:18, Golden Ring ha scritto:<br>
                  <blockquote type="cite">
                    <pre>I've been thinking recently about how to do recent changes patrol
better.  I've prototyped a tool, which you can see at
<a href="http://recent-changes.appspot.com/" target="_blank">http://recent-changes.appspot.com/</a>.</pre>
                  </blockquote>
                  <br>
                </span> Nice. It reminds me of <a href="https://tools.wmflabs.org/pltools/rech/" target="_blank">rech</a>...<span><br>
                  <br>
                </span></div>
            </blockquote>
            <div><br>
            </div>
            <div>Yes, very similar concept.   Is there a reason that
              rech is wikidata only?</div>
          </div>
        </div>
      </div>
    </blockquote>
    <br></span>
    I guess that is because its author, <a href="https://www.wikidata.org/wiki/User:Pasleim" target="_blank">Pasleim</a>, is
    mainly active there and didn't think it may have been useful to
    other projects. Or maybe it's supposed to implement some
    Wikidata-specific features in the future.<span class=""><br>
    <br>
    <blockquote type="cite">
      <div dir="ltr">
        <div class="gmail_extra">
          <div class="gmail_quote">
            <blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
              <div text="#000000" bgcolor="#FFFFFF"><span>
                  <blockquote type="cite">
                    <pre>This is currently implemented on Google AppEngine, basically
becausethat's what I had to hand when I set out and already knew
something about using.  It uses the MediaWiki API to retrieve diffs.
This is not ideal for a few reasons, not least because it wouldn't
take very heavy use of the tool before I'd have to start paying for
it, which would probably mean putting ads on it.  I can't be dealing
with all that.</pre>
                  </blockquote>
                  <br>
                </span> I suppose the cost is related to Google charging
                for bandwidth use beyond a threshold?<br>
                Since the app needs JavaScript anyway, you could simply
                retrieve recent changes on the client, thus avoiding
                much of the server-side traffic.<span><br>
                  <br>
                </span></div>
            </blockquote>
            <div><br>
            </div>
            <div>Yes, Google charges for both CPU time and bandwidth use
              beyond the free quota (1GB bandwidth either way + 28
              instance-hours per day).<br>
            </div>
            <div><br>
            </div>
            <div>Retrieving changes from the client side was what I
              attempted first, but of course it has to be hosted
              somewhere, and unless that's on the wiki concerned, then
              you have to deal with the cross-site nature of the API
              requests.  My impression is that this requires the wiki to
              be configured to explicitly allow requests from the domain
              serving the page.</div>
          </div>
        </div>
      </div>
    </blockquote>
    <br></span>
    Just pass dataType: "jsonp" to $.ajax(), it will magically work! (<a href="https://www.mediawiki.org/wiki/Manual:Ajax#Limitations" target="_blank">background</a>)<span class=""><br>
    <br>
    <blockquote type="cite">
      <div dir="ltr">
        <div class="gmail_extra">
          <div class="gmail_quote">
            <div><br>
            </div>
            <div>[snip] </div>
            <blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
              <div text="#000000" bgcolor="#FFFFFF"><span></span>
                Labs is precisely for external tools, and I'd say Tool
                Labs best fits your needs.<br>
                To enhance MediaWiki's built-in patrolling
                functionality, you should read <a href="https://www.mediawiki.org/wiki/How_to_become_a_MediaWiki_hacker" target="_blank">this</a> instead.<br>
                <a href="https://lists.wikimedia.org/pipermail/wikimedia-l/2014-October/075137.html" target="_blank">Use your judgement and common sense</a>
                to decide whether it's better to develop your tool on
                Tool Labs or as part of MediaWiki (either core or an
                extension).<span><br>
                  <br>
                </span></div>
            </blockquote>
            <div><br>
            </div>
            <div>I'm not absolutely clear on the best choice here.   On
              one hand, I'd like the tool to end up something like <a href="https://en.wikipedia.org/wiki/Special:NewPagesFeed" target="_blank">Special:NewPagesFeed</a>. 
              I guess this points towards developing it as built-in
              mediawiki functionality, rather than an external tool.  On
              the other hand, I've developed it because I actually want
              to use it; my impression is that getting changes into
              mediawiki, and then deployed onto en wikipedia, is not
              easy.  Probably for pretty good reasons, but still not
              easy.</div>
          </div>
        </div>
      </div>
    </blockquote>
    <br></span>
    Only you know how your tool will look like :-)<br>
    Special:NewPagesFeed is provided by the <a href="https://www.mediawiki.org/wiki/Extension:PageTriage" target="_blank">PageTriage
      extension</a>, so if your goal is to improve it or build upon it
    tightly, here you go.<br>
    If you're still undecided, I advise you to install
    MediaWiki+PageTriage on your device and have a look at the code
    while experimenting with Tool Labs.<span class=""><br>
    <br>
    <blockquote type="cite">
      <div dir="ltr">
        <div class="gmail_extra">
          <div class="gmail_quote">
            <div><br>
            </div>
            <div>If I go down the external tool route, then I guess the
              tool gets hosted at eg. <a href="http://tools.wmflabs.org" target="_blank">tools.wmflabs.org</a>;
              is that right?  On the other hand, an external tool hosted
              there doesn't have access to the production wikipedia
              databases and would have to continue getting data through
              the mediawiki API; is that right?</div>
          </div>
        </div>
      </div>
    </blockquote>
    <br></span>
    #1: yes. Follow the links at <a href="https://tools.wmflabs.org" target="_blank">tools.wmflabs.org</a>
    to create a Labs account (if you don't have one yet), request access
    to the Tools project and create a new tool. It will be hosted at
    <a href="http://tools.wmflabs.org/" target="_blank">tools.wmflabs.org/</a><yourtoolname>.<br>
    #2: no. Tools accounts have access to replicas of the production
    databases with private data redacted: read <a href="https://wikitech.wikimedia.org/wiki/Help:Tool_Labs/Database#Connecting_to_the_database_replicas" target="_blank">Connecting
      to the database replicas</a> for access. However, some data are
    only exposed via the API, and (my understanding is that) databases
    are generally only used directly in performance-critical
    applications which benefit from the power of SQL.<span class=""><br>
    <br>
    <blockquote type="cite">
      <div dir="ltr">
        <div class="gmail_extra">
          <div class="gmail_quote">
            <div><br>
            </div>
            <div>TBH I'm not sure I've got a lot of clue about the
              architecture of MediaWiki; is it described anywhere,
              beyond, "It uses PHP, MySQL and jQuery"?</div>
          </div>
        </div>
      </div>
    </blockquote>
    <br></span>
    It seems you're asking for the <a href="https://www.mediawiki.org/wiki/Developer_hub" target="_blank">Developer hub</a>,
    though it may be hard to grasp for a 'newb' ;-)<span class=""><br>
    <br>
    <blockquote type="cite">
      <div dir="ltr">
        <div class="gmail_extra">
          <div class="gmail_quote">
            <div><br>
            </div>
            <div>Sorry for having so many questions!</div>
          </div>
        </div>
      </div>
    </blockquote>
    <br></span>
    You're welcome!<span class=""><br>
    <br>
    <blockquote type="cite">
      <div dir="ltr">
        <div class="gmail_extra">
          <div class="gmail_quote">
            <div><br>
            </div>
            <div>Regards,</div>
            <div>GoldenRing</div>
            <blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
              <div text="#000000" bgcolor="#FFFFFF"><span> </span></div>
            </blockquote>
          </div>
          <br>
        </div>
      </div>
      <br>
      <fieldset></fieldset>
      <br>
      <pre>_______________________________________________
Labs-l mailing list
<a href="mailto:Labs-l@lists.wikimedia.org" target="_blank">Labs-l@lists.wikimedia.org</a>
<a href="https://lists.wikimedia.org/mailman/listinfo/labs-l" target="_blank">https://lists.wikimedia.org/mailman/listinfo/labs-l</a>
</pre>
    </blockquote>
    <br>
  </span></div>

<br>_______________________________________________<br>
Labs-l mailing list<br>
<a href="mailto:Labs-l@lists.wikimedia.org">Labs-l@lists.wikimedia.org</a><br>
<a href="https://lists.wikimedia.org/mailman/listinfo/labs-l" target="_blank">https://lists.wikimedia.org/mailman/listinfo/labs-l</a><br>
<br></blockquote></div><br></div>