MW-Peachy / Peachy

The official MediaWiki PHP bot framework. Current Version: 2.0 alpha 8
GNU General Public License v3.0
26 stars 21 forks source link

Can't seem to make edits #81

Closed Jarry1250 closed 10 years ago

Jarry1250 commented 10 years ago

Assert fails, and turning off assertion checks doesn't seem to help. Definitely some sort of regression/breaking change since 2908db46c08c7dbf3d7d42922e05da895207659c (5 March).

cyberpower678 commented 10 years ago

You're right about the issue, but it hasn't been occurring until your commit. I'm not pointing fingers however. With limited resources at hand right now, I can't diagnose the issue right now. I'll have to look at in a week.

cyberpower678 commented 10 years ago

I checked the adminstats logs and it seems it last ran successfully on the 18th. Ever since, it started getting assert failures.

cyberpower678 commented 10 years ago

I looked at your commit and there's nothing there that stands out to me. So I'll have to start up the debugger next week.

Jarry1250 commented 10 years ago

I think the issue is the incidental change I made where I corrected the line (approx line #680):

$data['error']['code'] == 'assertuserfailed';

to

$data['error']['code'] = 'assertuserfailed';

(I will test this theory.)

cyberpower678 commented 10 years ago

I don't know. I don't see it.

Jarry1250 commented 10 years ago

Oh no, this is my fault I think, in 9714ca366c3b184254a014b112ed9655ab6b24b6 I change a "else break;" (which is an illegal syntax, since we're not in a loop) to "else return true;", when really if you want to cut execution of the function short you need "else return $data;".

Jarry1250 commented 10 years ago

Oh, actually, the statement should just be moved inside the loop. I wonder how it got pushed out (probably by me).

Jarry1250 commented 10 years ago

Fix now merged.