Page MenuHomePhabricator

Edit pages only if edit size/number of characters changed is above threshold
Open, LowestPublic

Description

It would be really useful if pywikibot edits could be set up to happen only if the size of the edit would surpass threshold.

Especially useful if you want to run standalone cosmetic_changes but want to make the edit happen only if it is "significant", for example not removing only the newline somewhere, but making a larger edit.

Maybe it would be easier to make this happen if the threshold would be in "number of characters changed".


We need to add a parameter to scripts/cosmetic_changes.py script. It'll allow to add a limitation before the save of the edit : -lengthchange:20 would say that the edit will be saved only if 20 characters are changed in the page content.

Event Timeline

Wesalius renamed this task from edit pages only if edit size is above treshold to edit pages only if edit size/ńumber of characters changed is above treshold.Nov 23 2016, 8:38 AM
Wesalius updated the task description. (Show Details)
Dvorapa renamed this task from edit pages only if edit size/ńumber of characters changed is above treshold to edit pages only if edit size/number of characters changed is above treshold.May 28 2017, 11:51 AM
Dvorapa added a subscriber: Dvorapa.

@jayvdb @Wesalius what is the easiest way to do this comparison ? pwb already estimates that., where ?

I am not completely sure what I meant by pwb already estimates that (deleted from the description now, but I guess
it was either that pwb shows for ex. @@ -130,2 +130,2 @@ above the proposed edit or it tells you the bytes it has changed after the save edit (which is not estimating, I know).

Xqt triaged this task as Lowest priority.May 27 2018, 5:04 AM

@Dvorapa: Do you plan to mentor this task? If so feel free to create it on the GCI site. :)

Shreyasminocha renamed this task from edit pages only if edit size/number of characters changed is above treshold to Edit pages only if edit size/number of characters changed is above threshold.Nov 5 2018, 2:02 PM
Shreyasminocha updated the task description. (Show Details)

Yes, I'll find some spare time and make GCI tasks for this

@Dvorapa: You have two more weeks for Google-Code-in-2018, if you still plan to. :)