> Message: 5
> Date: Wed, 8 Feb 2012 23:31:37 +0400
> From: Max Semenik <[email protected]>
> To: MediaWiki API announcements & discussion
>       <[email protected]>,    Wikimedia developers
>       <[email protected]>
> Subject: [Wikitech-l] Proposed removal of some API output formats
> Message-ID: <[email protected]>
> Content-Type: text/plain; charset=utf-8
>
> Hi, this idea had floated around for quite some time, but now that
> bug 34257[1] was added to the long list of problems, I would like to
> step up and start some progress. We[2] propose to remove the following
> formats[3]:
>
> * WDDX - doesn't seem to be used by anyone. Doesn't look sane either.
> * YAML - we don't serve real YAML anyway, currently it's just a subset
> of JSON.
> * rawfm - was created for debugging the JSON formatter aeons ago, not
> useful for anything now.
> * txt, dbg, dump - the only reason they were added is that it was
> possible to add them, they don't serve the purpose of
> machine/machine communication.
>
> So, only 3 formats would remain:
> * JSON - *the* recommended API format
> * XML - evil and clumsy but sadly used too widely to be revoved in the
> foreseeable future
> * php - this one is used by several extensions and probably by some
> third-party reusers, so we won't remove it this time. However,
> any new uses of it should be discouraged.
>
> We plan to remove the aforementioned formats as soon as MediaWiki 1.19
> is branched so that these changes will take effect in 1.20, but would
> like to hear from you first if there are good reasons why we shouldn't
> do it or postpone it. Please have your say.
>
> ------
> [1] https://bugzilla.wikimedia.org/show_bug.cgi?id=34257
> [2] Me and Roan Kattouw, one of API's primary developers
> [3] https://www.mediawiki.org/wiki/API:Data_formats
>
> --
> Best regards,
> Max Semenik ([[User:MaxSem]])
>


I have scripts that use the txt format. (Things that were originally
super hacky shell scripts, that became more permanently run scripts
[but still hacky beyond belief]). txt is mostly easy to process with
grep (So was the older version of yaml formatting). However, hopefully
not too many people were stupid enough to try to parse the api output
using grep. (In case anyone is wondering if using shell scripts to
access the api is really as bad as it sounds, I assure you its even
worse than you think).

If json becomes the new recommended format, does that mean that not
passing a format parameter would result in jsonfm instead of xmlfm?
(Probably not since the jsonfm pretty printer isn't all that pretty at
the moment).

> For a stable API, that's far too fast of a deprecation path. We don't even
> remove core functions that fast (or shouldn't). I'd suggest throwing some
> kinds of warnings in the output for at least one release (1.20) and then
> target them for removal in 1.21.
>
> -Chad

+1.

--
-bawolff

_______________________________________________
Wikitech-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikitech-l

Reply via email to