Page MenuHomePhabricator

Unify negative page generators
Open, LowPublic

Description

There is -ns:not and -titleregexnot and -onlyifnot and -withoutinterwiki. We should make them behave similar.

Is better:

  • -ns:not
  • -titleregexnot
  • -withoutinterwiki

Or anything else?

Related Objects

Event Timeline

Change 499199 had a related patch set uploaded (by Dvorapa; owner: Dvorapa):
[pywikibot/core@master] [IMPR] Unify negative page generators

https://gerrit.wikimedia.org/r/499199

Change 499199 abandoned by Dvorapa:
[IMPR] Unify negative page generators

Reason:
accidentally openned

https://gerrit.wikimedia.org/r/499199

Dvorapa renamed this task from Rename -titleregexnot to -titleregex:not to Unify negative page generators.Mar 26 2019, 2:02 PM
Dvorapa removed a project: Patch-For-Review.
Dvorapa updated the task description. (Show Details)
Dvorapa updated the task description. (Show Details)

Hi @Dvorapa I would like to work on this task. I found all of those commands in this file: https://phabricator.wikimedia.org/diffusion/PWBC/browse/master/pywikibot/pagegenerators.py.
Can someone hint me what needs to be done here? Thanks!

@Dvorapa I'd like to ask for some clarification here. Are you suggesting that it'd be best to drop some negative page generator arguments in favor of a not suffix to positive arguments, i.e.:

-titleregexnot --> titleregex:not,

and

-withoutinterwiki --> interwiki:not

etc.? From the feature request and the previous name of the request, I assume this is what you want.

Also, one other pair not mentioned is grep and grepnot, I assume unification is desired here as well

Xqt triaged this task as Low priority.May 15 2021, 5:29 AM

Change 692755 had a related patch set uploaded (by Chris Maynor; author: Chris Maynor):

[pywikibot/core@master] pagegenerators: Unify negative page generation

https://gerrit.wikimedia.org/r/692755

See also T103779. Probably a good idea to circumvent the <option>:not problem.

@Xqt could you elaborate? I believe I've implement something pretty similar in the latest patch set, except it's 'not:<option>' instead of 'not-<option>'.