Jump to navigation Jump to search
Mediawiki-Japi is a Java framework, intended to make it easy to write Java bots that interact with the MediaWiki API. It handles
- query continuations
- and tokens,
and has a range of helper methods for common tasks as well as for basic interaction with the MediaWiki API.
Particularly notable or useful features of Mediawiki-Japi include:
- Designed and implemented on the basis of the API schema
- Solid codebase and a good set of features
- Has frequently updated unit and integration tests
- A responsive and helpful maintainer
Easy to install
- Installation instructions are correct and easy to find
- Library is packaged for installation through appropriate package library (PyPI, CPAN, npm, Maven, rubygems, etc.)
- Platinum standard: library is packaged for and made available through Linux distributions
It is unusual to ship Java packages with Linux distributions.
Easy to understand
- Well designed--makes all intended API calls available with the intended level of abstraction with no redundancies
Stays 1:1 to message Schema. Each node is represented with the appropriate Java equivalent e.g. Api/Query/Error ...
- Platinum standard: makes the Wikidata API available
- Well documented
- Code is commented and readable
- Documentation is comprehensive, accurate, and easy to find
- Wiki page with example per function.
- Deprecated functions are clearly marked as such
- Platinum standard: Documentation is understandable by a novice programmer
Adequately written Java.
Easy to use
- Has functioning, simple, and well-written code samples for common tasks
- Demonstrates queries
- Demonstrates edits
- Query continuations
- Requests via https, including certificate validation
- gzip compression is used by default
- See tests (
HttpActionClientTest) that proves that gzip is the default of jwbf for what needs to be done.
- Examples show how to create and use a meaningful and unique user-agent header (as in https://meta.wikimedia.org/wiki/User-agent_policy)
- Platinum standard: generates a unique user-agent string given name/email address/repository location
- Efficient usage of API calls
- needs to be worked on
- Can be used with the most recent stable version of the language it is written in (e.g. Python 3 compatible)
Easy to debug
- Contains unit tests for the longest and most frequently modified functions in the library
- Platinum standard: Unit tests for many code paths exist and are maintained
The framework has integration tests as well.
- Terrible hacks/instances of extreme cleverness are clearly marked as such in comments
Comments include FIXMEs
- Documentation links to the relevant section/subpage of the API documentation
Consistently - examples are organized as the API documentation is
Easy to improve
- Library maintainers are responsive and courteous, and foster a thoughtful and inclusive community of developers and users
Maintainer is actively involved and helpful.
- Platinum standard: Project sets clear expectations for conduct for spaces where project-related interactions occur (mailing list, IRC, repository, issue tracker). It should:
- State desired attitudes and behaviors
- Provide examples of unwelcome and harassing behavior
- Specify how these expectations will be enforced
- Pull requests are either accepted or rejected with reason within 3 weeks (Platinum standard: 3 business days)
- Issues/bugs are responded to in some manner within 3 weeks (Platinum standard: 3 business days) (but not necessarily fixed)
There is usually a response within 1 week.
- The library is updated and a new version is released within 3 weeks (Platinum standard: 3 business days) when breaking changes are made to the API
- Platinum standard: library maintainers contact MediaWiki API maintainers with feedback on the API's design and function
contact attempts done e.g. with MER-C
- Library specifies the license it is released under
The gold standard needs to be met to be listed on API:Client code.