Last modified: 2007-10-15 13:52:56 UTC

Wikimedia Bugzilla is closed!

Wikimedia has migrated from Bugzilla to Phabricator. Bug reports should be created and updated in Wikimedia Phabricator instead. Please create an account in Phabricator and add your Bugzilla email address to it.
Wikimedia Bugzilla is read-only. If you try to edit or create any bug report in Bugzilla you will be shown an intentional error message.
In order to access the Phabricator task corresponding to a Bugzilla report, just remove "static-" from its URL.
You could still run searches in Bugzilla or access your list of votes but bug reports will obviously not be up-to-date in Bugzilla.
Bug 11634 - allpages thingis
allpages thingis
Status: RESOLVED FIXED
Product: MediaWiki
Classification: Unclassified
API (Other open bugs)
unspecified
All All
: Normal enhancement (vote)
: ---
Assigned To: Roan Kattouw
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2007-10-11 15:21 UTC by Carl Fürstenberg
Modified: 2007-10-15 13:52 UTC (History)
1 user (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Carl Fürstenberg 2007-10-11 15:21:33 UTC
apdir - similar to rvdir
apsuffix - the end of the game
apprtype - one value only?
apprlevel - change clear to 'user', to remove the logical ambiguous. Also enable to be able to have multiple values, for example not protected or sysop protected.

appr: to be able to specify more complex types of protections, example: edit protected AND move protected, edit protection is for autoconfirmed and move protection is for sysops (a common setup)
Comment 1 Roan Kattouw 2007-10-11 15:30:51 UTC
(In reply to comment #0)
> apdir - similar to rvdir
So that would be AtoZ and ZtoA. If you want it, you can get it...

> apsuffix - the end of the game
See bug 10808 for why this is not gonna happen anytime soon.

> apprtype - one value only?
So you want to be able to filter on edit|move also? Possible.

> apprlevel - change clear to 'user', to remove the logical ambiguous. Also
> enable to be able to have multiple values, for example not protected or sysop
> protected.
So you want apprlevel=none and multivals. Note, though, that apprtype=edit|move&apprlevel=autoconfirmed|sysop is NOT gonna give you pages that have edit=autoconfirmed;move=sysop. Rather, it's gonna give you all pages that have EITHER edit or move protection set to EITHER autoconfirmed or sysop. Use generator=allpages&prop=info&inprop=protection to distinguish.

> appr: to be able to specify more complex types of protections, example: edit
> protected AND move protected, edit protection is for autoconfirmed and move
> protection is for sysops (a common setup)
> 
That's tricky, I don't know if it's reasonably doable. I'll come back to this when I take a serious look at this bug.

Assigning to self, will attempt a fix after the week end (sorry for the delay).

Comment 2 Roan Kattouw 2007-10-12 20:10:54 UTC
I've written a patch for this that I'll test and apply after the weekend (no access to my public key, test setup or diff program). The patch implements apdir ('AtoZ' or 'ZtoA'), and makes apprlevel and apprtype multivalue parameters. apsuffix is not doable (see bug 10808), and listing unprotected pages is not feasible either: it would result in massive queries that would kill any WMF wiki's database, for which Domas is sure to hunt me down and kill me in turn :D

As to the complex protections request: if you want all pages with edit=autoconfirmed and move=sysop, your best bet is probably to do something like

api.php?action=query&generator=allpages&gapprtype=edit&gapprlevel=autoconfirmed&prop=info&inprop=protection

And filter out all pages that don't have move=sysop. Alternatively, you can search for pages that appear in both the edit=autoconfirmed and move=sysop list, but the latter would probably be polluted too much with edit=sysop;move=sysop pages.
Comment 3 Carl Fürstenberg 2007-10-12 21:24:18 UTC
(In reply to comment #2)
> As to the complex protections request: if you want all pages with
> edit=autoconfirmed and move=sysop, your best bet is probably to do something
> like
> 
> api.php?action=query&generator=allpages&gapprtype=edit&gapprlevel=autoconfirmed&prop=info&inprop=protection
> 
> And filter out all pages that don't have move=sysop. Alternatively, you can
> search for pages that appear in both the edit=autoconfirmed and move=sysop
> list, but the latter would probably be polluted too much with
> edit=sysop;move=sysop pages.
> 


problem with this approach is that you might not get any result, for example if the result limit is 500, and there are 501 pages with edit=autoconfirmed and 500 pages without move=sysop and those are the pages that are returned, you wont get the page(s) you want.
Comment 4 Roan Kattouw 2007-10-13 19:04:54 UTC
(In reply to comment #3)
> problem with this approach is that you might not get any result, for example if
> the result limit is 500, and there are 501 pages with edit=autoconfirmed and
> 500 pages without move=sysop and those are the pages that are returned, you
> wont get the page(s) you want.

True. Maybe I'll add an AND/OR parameter that enables AND queries as well. I'll look into that tomorrow. 

Comment 5 Roan Kattouw 2007-10-15 13:52:56 UTC
Added apdir and multival appr{type,level} in r26725. Enabling AND queries is very tricky due to the DB scheme, so I'm WONTFIXing that part for now.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links