Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ERROR: Too many values supplied for parameter "titles" #592

Closed
kelson42 opened this issue Feb 22, 2019 · 9 comments
Closed

ERROR: Too many values supplied for parameter "titles" #592

kelson42 opened this issue Feb 22, 2019 · 9 comments
Assignees
Labels
Milestone

Comments

@kelson42
Copy link
Collaborator

[info] [2019-02-22T20:24:25.193Z] Getting JSON from [https://bm.wikipedia.org/w/api.php?action=query&prop=redirects&format=json&rdprop=title&rdlimit=max&rawcontinue=&titles=La_Serena|D%C3%A4ttlikon|Alger|Gautama_Buddha|Djamana_d%C3%A9kourou_sanfe_bada_bon_ka_fada_dogona_(UNHCR)|Lom%C3%A9|Bisau|Bourg-la-Reine|Antony|Asni%C3%A8res-sur-Seine|Bagneux_(Hauts-de-Seine)|Bois-Colombes|Boulogne-Billancourt|Ch%C3%A2tenay-Malabry|Ch%C3%A2tillon_(Hauts-de-Seine)|Chaville|Clamart|Clichy|Colombes|Courbevoie|Fontenay-aux-Roses|Garches|Gennevilliers|Issy-les-Moulineaux|La_Garenne-Colombes|Le_Plessis-Robinson|Levallois-Perret|Chaource|Antibes|Biot|Cannes|Grasse|Edirne|Arcachon|Bordeaux|Coutras|Atlanta|Boston|Chicago|Dallas|El_Paso_(Texas)|Fresno|Greensboro|Houston|Indianapolis|Jacksonville|Kansas_City_(Missouri)|Las_Vegas|Austin_(Texas)|Columbus_(Ohio)|Fort_Worth|Charlotte|D%C3%A9troit|Baltimore]
[info] [2019-02-22T20:24:25.194Z] Getting JSON from [https://bm.wikipedia.org/w/api.php?action=query&prop=redirects&format=json&rdprop=title&rdlimit=max&rawcontinue=&titles=Denver|Louisville_(Kentucky)|Albuquerque|Long_Beach|Colorado_Springs|Cleveland|Arlington_(Texas)|Bakersfield|Honolulu|Anaheim|Corpus_Christi|Lexington_(Kentucky)|Anchorage|Buffalo_(New_York)|Cincinnati|La_Baule-Escoublac|Gu%C3%A9rande|Corsept|La_Bernerie-en-Retz|Chauv%C3%A9|Les_Moutiers-en-Retz|Ch%C3%A9m%C3%A9r%C3%A9|Brains|Cheix-en-Retz|Bouaye|La_Montagne|La_Plaine-sur-Mer|Cou%C3%ABron|La_Chapelle-sur-Erdre|Abbaretz|Basse-Goulaine|Carquefou|La_Marne|Machecoul-Saint-M%C3%AAme|Bouguenais|Avessac|Conquereuil|Derval|Gu%C3%A9men%C3%A9-Penfao|Jans|La_Grigonnais|Jou%C3%A9-sur-Erdre|La_Meilleraye-de-Bretagne|Grand-Auvern%C3%A9|Iss%C3%A9|Les_Touches|Casson|Erbray|Louisfert|Ch%C3%A2teaubriant|Juign%C3%A9-des-Moutiers|Divatte-sur-Loire|Le_Cellier|Couff%C3%A9]
[info] [2019-02-22T20:24:25.194Z] Getting JSON from [https://bm.wikipedia.org/w/api.php?action=query&prop=redirects&format=json&rdprop=title&rdlimit=max&rawcontinue=&titles=Lign%C3%A9|Ancenis|Anetz|La_Roche-Blanche_(Loire-Atlantique)|Aigrefeuille-sur-Maine|Ch%C3%A2teau-Th%C3%A9baud|Le_Bignon|La_Chapelle-Glain|Blois|Bourges|Chartres|Ch%C3%A2teauroux|Gien|Liran]
[warn] [2019-02-22T20:24:25.486Z] Invalid JSON resonse: { error:
   { code: 'too-many-titles',
     info:
      'Too many values supplied for parameter "titles". The limit is 50.',
     '*':
      'See https://bm.wikipedia.org/w/api.php for API usage. Subscribe to the mediawiki-api-announce mailing list at <https://lists.wikimedia.org/mailman/listinfo/mediawiki-api-announce> for notice of API deprecations and breaking changes.' },
  servedby: 'mw1314' }
@kelson42 kelson42 added the bug label Feb 22, 2019
@kelson42 kelson42 added this to the 1.8 milestone Feb 22, 2019
@kelson42
Copy link
Collaborator Author

@ISNIT0 BTW, there is a typo in the error msg: Invalid JSON resonse

@ISNIT0
Copy link
Contributor

ISNIT0 commented Feb 22, 2019

This is not a bug, the wikis all have different settings - we automatically reduce the number over time. I did consider picking the limit out of the error code, but this seems fragile.

@kelson42
Copy link
Collaborator Author

@ISNIT0 If this is not an error, then the log should not report an error, the message should be clear that everything is normal.

@ISNIT0
Copy link
Contributor

ISNIT0 commented Feb 22, 2019

Yes, there was a typo with the code checking, I've opened a PR.

@kelson42
Copy link
Collaborator Author

@ISNIT0 Are you informed about any mediawiki instance with MAX<50? Otherwise I would just stick to that upper limit.

@ISNIT0
Copy link
Contributor

ISNIT0 commented Feb 22, 2019

@kelson42 The documentation says it's 500 (5000 for bots).
https://en.wikipedia.org/w/api.php?action=help&modules=query%2Bredirects

@kelson42
Copy link
Collaborator Author

@ISNIT0 If there is a discrepency between the doc and the reality, please open a bug immediatly on Phabricator and make a ref here.

@ISNIT0
Copy link
Contributor

ISNIT0 commented Feb 22, 2019

@ISNIT0
Copy link
Contributor

ISNIT0 commented Feb 23, 2019

I had mis-understood the documentation. Have created a fix here :)

ISNIT0 added a commit that referenced this issue Feb 23, 2019
🐛 fixed redirect queue issue #592
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants