Page MenuHomePhabricator

ApiEdit: Unknown error: AS_END
Closed, ResolvedPublic


Author: Bryan.TongMinh

The AS_END return code is not caught and thus an unknownerror is thrown.

Version: 1.14.x
Severity: normal



Event Timeline

bzimport raised the priority of this task from to Medium.Nov 21 2014, 10:18 PM
bzimport set Reference to bz15444.

Reminder to self: AS_END is returned when updateArticle() fails. We don't check for insertNewArticle()'s return value, though, while we probably should.

Fixed in r40383, but not probably not the way you expected ;)

AS_END is only returned if something weird happens, like an UPDATE on page_latest failing because it was UPDATEd after the edit conflict check. Similar conditions are possible for other write operations (such as move and rollback), and they, too, return 'unknownerror'. As documented on [[mw:API:Errors and warnings]] (added it just now, but it was there when the errors were still listed on separate pages), 'unknownerror' really means that something very weird happened and that you should retry the request.