Page MenuHomePhabricator

Users can exceed the max number of pages allowed in a collection ($wgCollectionMaxArticles)
Open, MediumPublic

Description

Currently the extension doesn't seems to respect the max number of articles which a book could have ($wgCollectionMaxArticles = 500 [1]).

You can confirm this by going to a big category of Wikipedia, with more than 500 articles (e.g. [[Category:Living_people]]), and adding it to a collection. The extension will add only 500 pages, but then it should display the warning from [[MediaWiki:coll-limit_exceeded_text]] ("Your book is too big. No more pages can be added."), and it doesn't.

Besides this, if you go to another article wich is not in you big book (e.g. [[Sport]])), and add it, your book will have 501 pages and no warning will be displayed.

A user can also easily create a book page ([[Category:Wikipedia books (community books)]]) with more than 500 pages and then load it into [[Special:Book]].

This inconsistent use of $wgCollectionMaxArticles should be fixed.

[1] http://svn.wikimedia.org/viewvc/mediawiki/trunk/extensions/Collection/Collection.php?view=markup#l86


Version: unspecified
Severity: normal
URL: http://en.wikipedia.org/w/index.php?title=Special:Book&bookcmd=add_category&cattitle=Living+people
See Also:
T71003: Book with 3000 entries failed rendering
http://web.archive.org/web/20111002214238/http://code.pediapress.com/wiki/ticket/374

Details

Reference
bz26775

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 21 2014, 11:13 PM
bzimport added a project: Collection.
bzimport set Reference to bz26775.
bzimport added a subscriber: Unknown Object (MLST).

This seems easy, but also a non-issue ... it doesn't explode when it said it should?

Is it really necessary to have a variable to set a limit on the number of pages a book could have? Maybe the option could just be dropped since it doesn't works (currently) and nothing bad seems to happens because of that...

(In reply to comment #4)

Is it really necessary to have a variable to set a limit on the number of pages
a book could have? Maybe the option could just be dropped since it doesn't
works (currently) and nothing bad seems to happens because of that...

BTW: If someone fix this limit, I will need to be changed from its default value, since some Wikimedia wikis have books with more than 500 pages. E.g. [[pt:b:Wikilivros:Livros/Livro de receitas]], which has 1993 pages!

(In reply to Helder from comment #0)

Besides this, if you go to another article wich is not in you big book (e.g.
[[Sport]])), and add it, your book will have 501 pages and no warning will
be displayed.

Is the 501-pages book actually exported? If it is, then I wouldn't bother too much. If it fails, then that's confusing for users.

The export fails with this message:
"Book rendering failed

There was an error while attempting to render your book.

Return to Wikilivros:Página principal."

(the error does not happens after I remove the 501th page from the book and try again)