[15:19:44] New patchset: Jeroen De Dauw; "bug 42324 Better support for sqlite" [mediawiki/extensions/SemanticMediaWiki] (master) - https://gerrit.wikimedia.org/r/34572 [21:46:41] New review: Jeroen De Dauw; "Really, please test the code or at least have a good second look at it yourself." [mediawiki/extensions/SemanticMediaWiki] (master); V: 0 C: -1; - https://gerrit.wikimedia.org/r/34572 [22:47:49] Hi, I'm trying to get the hang of #get_web_data in json-format. I'm not fully successful, my call only returns the very last item in the json-array. Any hints? (i've already fiddled with $wgHTTPTimeout) [22:49:15] I'm also want to learn how to find debugging output from the extension itself (external_data)? [22:57:21] joru: there's actually a bug in the retrieval of JSON data in the latest version of External Data - I'm pretty sure that's what you're experiencing. [22:57:29] I need to lok iinto it and fix it. [22:57:40] yaron: i just read that in the talk section on the wiki [22:57:44] i'm using 1.4.1 [22:57:48] Oh, okay. [22:58:02] well then i know it's almost working and i'm fine with that [22:58:05] no need to stress [22:58:18] since i'm building up the skeleton of my services atm [22:58:39] So it's still not working for you, with version 1.4.1? [22:58:45] exactly, not working [22:59:00] do you recomment that I should revert even further to see where it fails? [22:59:44] Hm, no - my guess now is that there's an error in your syntax. [23:00:10] I assume you're using #for_external_table, and not #external_value? [23:01:58] yaron: http://pastebin.com/Nxy80yc1 [23:02:22] a simple example [23:03:51] i'm only returning content-type: application/json and charset=utf-8 at the moment and a 200, is more required? [23:05:59] joru: well, all that seems correct - maybe the JSON itself is causing the problem? [23:07:11] yaron: well maybe: I generate it through json_encode(). Hmm. [23:08:13] I don't know - JSON parsing is always more awkward than XML parsing, since with XML you can use Xpath. [23:08:52] I understand [23:10:56] the only think i can think of is that the JSON-array contains strings with swedish characters [23:11:04] there is similar things for json too [23:11:08] e.g. åäö [23:11:23] generated with \xxx [23:11:56] Nikerabbit: is such a thing included in the module in question? [23:12:39] I doubt that [23:12:46] yaron: otherwise i dont know.. i'll see what happens if I go for an XML-format using Xpath [23:12:48] Nikerabbit: ok [23:13:56] yaron: another question that comes in mind, are database column names containing "_" invalid in #get_db_data? [23:15:20] joru: I hope not... if so, that's a bug. [23:18:02] yaron: sorry, no bug, human error. [23:18:21] yaron: do you know any way to check/validate the JSON-array? [23:18:35] (i've mainly worked with XML before) [23:19:31] joru: not anything that's specific to External Data. [23:19:38] ok [23:19:50] There are some online JSON-validation tools, from what I remember... [23:20:24] Ok, i'll do some searching on that [23:22:27] yaron: darn, seems to be valid. Well i'll dwell into an XML-array instead then. [23:29:28] yaron: thanks for caring [23:29:38] :) [23:29:51] Well, I care about the code, and the users. [23:30:20] If there's a bug in the JSON-handling (besides the one I already know about), I'd like to know. [23:30:48] Well I can gladly provide a JSON-array of the data I'm fiddeling with [23:31:04] however i cannot determine if it's a bug or not [23:31:33] the data validated according to e.g. RFC 4627 [23:32:16] joru: yes, if you could pastebin or send me the JSON, that would be helpful. [23:32:37] yaron: you can now reload the pastbin [23:32:52] yaron: earlier version constains the call itself [23:33:43] I only see the last element in the mediawiki table (earlier version of the pastebin) [23:34:04] yaron: hang on [23:34:12] (pastebin issue)