https://bugzilla.wikimedia.org/show_bug.cgi?id=28541

             Bug #: 28541
           Summary: api can't output binary data, like icu sortkeys
           Product: MediaWiki
           Version: wikimedia-deployment
          Platform: All
               URL:
                    http://translatewiki.net/w/api.php?action=query&list=c
                    ategorymembers&cmprop=sortkey&cmtitle=Category:User%20
                    en&cmlimit=1
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: Low
         Component: API
        AssignedTo: roan.katt...@gmail.com
        ReportedBy: bawolff...@gmail.com
                CC: bryan.tongm...@gmail.com, s...@reedyboy.net,
                    soxre...@gmail.com, vasi...@gmail.com
    Classification: Unclassified


When doing an api query that could return binary data (icu sortkeys for
example), if the binary data isn't valid utf-8 (which will happen most of the
time) it will output an empty string instead.

For example:
http://translatewiki.net/w/api.php?action=query&list=categorymembers&cmprop=sortkey&cmtitle=Category:User%20en&cmlimit=1

Expected output is a big long binary string.

This is rather confusing when trying to debug stuff, although arguably much of
the time this behaviour does kind of make sense. Anyways, caused by
ApiResult::cleanUpUTF8.

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.

_______________________________________________
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l

Reply via email to