Page MenuHomePhabricator

Migrate AWB to using JSON instead of XML for API requests
Open, Needs TriagePublic

Description

Migrate AWB to using JSON instead of XML for API requests. This should be done using the Json.NET library that has been in the AWB repo for a while now.

Going to require a lot of work

Something "isolated" like the SiteInfo or SiteMatrix code may be a good starting point.

Stuff that needs doing:

  • SiteInfo::GetMessages()
  • Tools::ExpandTemplate()
  • SiteInfo::LoadSiteInfo()/LoadFromNetwork()
  • SiteMatrix::LoadFromNetwork()
  • ApiEdit::QueryApi() (used for list providers et al)
  • ApiEdit (rest of actions)

Event Timeline

Reedy created this task.Mar 1 2015, 11:17 PM
Reedy claimed this task.
Reedy raised the priority of this task from to Needs Triage.
Reedy updated the task description. (Show Details)
Reedy added a project: AutoWikiBrowser.
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptMar 1 2015, 11:17 PM
Reedy added a comment.EditedMar 7 2015, 1:22 AM

https://github.com/reedy/AutoWikiBrowser/compare/5eba2e5...cdfa8a6

And so it begins with SiteInfo::GetMessages(). T91852 is a semi blocker for this. Allowing us to write better code for the transition...

Josve05a moved this task from Backlog to Doing on the AutoWikiBrowser board.Apr 6 2015, 1:29 AM
Josve05a moved this task from Doing to Backlog on the AutoWikiBrowser board.May 14 2015, 10:38 PM
Reedy updated the task description. (Show Details)Jul 27 2015, 12:22 AM
Reedy set Security to None.
Reedy added a comment.Jul 27 2015, 4:18 AM
Find all "format=xml", Subfolders, Find Results 1, Entire Solution, ""
  D:\programming\autowikibrowser\AWB\WikiFunctions\API\ApiEdit.cs(329):            return ApiURL + "?format=xml" + BuildQuery(request);
  D:\programming\autowikibrowser\AWB\WikiFunctions\API\ApiEdit.cs(1122):            string result = HttpGet(ApiURL + "?action=query&format=xml&" + queryParamters);
  D:\programming\autowikibrowser\AWB\WikiFunctions\Parse\SiteMatrix.cs(117):            string strMatrix = Tools.GetHTML("https://en.wikipedia.org/w/api.php?action=sitematrix&format=xml");
  D:\programming\autowikibrowser\AWB\WikiFunctions\SiteInfo.cs(149):            siteinfoOutput = Editor.HttpGet(ApiPath + "?action=query&meta=siteinfo&siprop=general|namespaces|namespacealiases|statistics|magicwords&format=xml");
  Matching lines: 4    Matching files: 3    Total files searched: 435
Reedy updated the task description. (Show Details)Jul 27 2015, 10:38 PM
Reedy updated the task description. (Show Details)Jul 27 2015, 10:59 PM
Restricted Application added a subscriber: StudiesWorld. · View Herald TranscriptFeb 26 2016, 6:18 PM
Aklapper removed Reedy as the assignee of this task.Jun 19 2020, 4:17 PM
Aklapper added a subscriber: Reedy.

This task has been assigned to the same task owner for more than two years. Resetting task assignee due to inactivity, to decrease task cookie-licking and to get a slightly more realistic overview of plans. Please feel free to assign this task to yourself again if you still realistically work or plan to work on this task - it would be welcome!

For tips how to manage individual work in Phabricator (noisy notifications, lists of task, etc.), see https://phabricator.wikimedia.org/T228575#6237124 for available options.
(For the records, two emails were sent to assignee addresses before resetting assignees. See T228575 for more info and for potential feedback. Thanks!)