Wikipedia:井戸端/subj/注意:Bot、ガジェット、ユーザースクリプトが機能しなくなる可能性があります
|
注意:Bot、ガジェット、ユーザースクリプトが機能しなくなる可能性があります
[編集]原題:Your attention please: bots, gadgets and user scripts on this wiki may break soon
Hi everybody. Apologies for using English for this message, but I couldn't find a translator in time. Maybe someone can translate the first lines of this announcement, if necessary?
Next week, a major change will happen to Wikimedia APIs.
This update has been planned, discussed and announced for years (covered in Tech News, etc.), but I wanted to make sure you got yet another announcement about it, because it will reach the wikis since 30 June 2015, and if affected bots, gadgets and user scripts on this wikis are not updated, they will stop working.
No reasons to panic, though :) Please just make sure that bot writers/maintainers see the message below. Thank you, --Elitre (WMF)(会話) 2015年6月27日 (土) 10:19 (UTC)
翻訳を試みてみました。
|
---|
|
- Is a bot, gadget, or user script you wrote in use on this wiki?
The breaking change involves API calls. This change has been planned for two years. The WMF will start making this change on 30 June 2015. A partial list of affected bots can be seen here: https://lists.wikimedia.org/pipermail/wikitech-l/2015-June/081931.html This includes all bots that are using pywikibot compat. Some of these bots have already been fixed. However, if you write user scripts or operate a bot that uses the API, then you should check your code, to make sure that it will not break.
What, exactly, is breaking? The "default continuation mode" for action=query requests to api.php will be changing to be easier for new coders to use correctly. To find out whether your script or bot may be affected, then search the source code (including any frameworks or libraries) for the string "query-continue". If that is not present, then the script or bot is not affected. In a few cases, the code will be present but not used. In that case, the script or bot will continue working.
This change will be part of 1.26wmf12. It will be deployed to test wikis (including mediawiki.org) on 30 June, to non-Wikipedias (such as Wiktionary) on 1 July, and to all Wikipedias on 2 July 2015.
If your bot or script is receiving the warning about this upcoming change (as seen at https://www.mediawiki.org/w/api.php?action=query&list=allpages ), it's time to fix your code!
- The simple solution is to simply include the "rawcontinue" parameter with your request to continue receiving the raw continuation data (example <https://www.mediawiki.org/w/api.php?action=query&list=allpages&rawcontinue=1>). No other code changes should be necessary.
- Or you could update your code to use the simplified continuation documented at https://www.mediawiki.org/wiki/API:Query#Continuing_queries (example <https://www.mediawiki.org/w/api.php?action=query&list=allpages&continue=>), which is much easier for clients to implement correctly.
Either of the above solutions may be tested immediately, you'll know it works because you stop seeing the warning. Here are a couple of examples of code being fixed at enwiki: [1], [2] .
- Do you need help with your own bot or script? In case you can't find help locally, please feel free to ask questions in e-mail on the mediawiki-api or wikitech-l mailing lists. Volunteers at m:Tech or w:en:WP:Village pump (technical) or w:en:Wikipedia:Bot owners' noticeboard may also be able to help you.
- Are you using someone else's gadgets or user scripts? Most scripts are not affected. To find out if a script you use needs to be updated, then post a note at the discussion page for the gadget or the talk page of the user who originally made the script.
コメント 恐らく、query-continue を利用していないコードには問題が起きないものと思います。もし、利用しているコードがあるのであれば、rawcontinue パラメータを挿入するか、continue パラメータを使った新しい(そして簡単な)コードに書き換えてください。ご自身で管理しているコードを把握できる範囲で確認してください。この件に関する相談は、ここを利用するか、「プロジェクト:ウィキ技術部」の方にお願いします。動かなくて困っている機能がありましたら「Wikipedia:バグの報告」の方にお願いします。--Frozen-mikan(会話) 2015年6月29日 (月) 12:44 (UTC)