CoverMe, hosted on Wikimedia Toolforge
Test coverage is a useful metric, but it can be difficult to figure out exactly where to start. That's where CoverMe is useful - it sorts functions by how often they're called on Wikimedia production servers, and then displays their coverage status.

Try it out! You can filter by Git repository and entry point (index.php, load.php, etc.). So if you look at the api.php entry point, you'll see mostly API related code. If I look at the Linter extension, I can see that the RecordLintJob::run
is well covered, while ApiRecordLint::run
is not covered at all. If some extensions simply aren't called that frequently, there might not be any function call data at all.
The function call data comes from the daily Xenon logs that are used for profiling FlameGraphs, and the CI test coverage data. CoverMe fetches updated data on the hour if it's available.
The source code is published on Phabricator and licensed under the AGPL v3, or any later version.
Originally posted on mastodon.technology.
Preview of a project I've been working on: identifying the most valuable parts of our code to write tests for by sorting test coverage data by number of times the function is called in production.
#mediawiki #testcoverage
Originally posted on mastodon.technology.
So now matrix.org requires you to confirm that you're over 16 before you can use it. I hope this doesn't become the new reality - I got started on IRC a few years before I turned 16. :|
I couldn't find any age requirement for freenode (https://freenode.net/policies).
Oh, and Slack also requires everyone to be 16 and over.
Originally posted on mastodon.technology.
Hanging out with @taylorswift13 tonight! #taylornation #reputation
Originally posted on mastodon.technology.
Today I found a legitimate use for https://github.com/danielquinn/python-php
Python's default ConfigParser requires each ini file to have a [section]. PHP doesn't, so to read a PHP-formatted INI file in Python requires some kind of custom parser (maybe it would be possible to extend ConfigParser?), where the python-php project came in handy. It even removed the quotes around string values like PHP would.
The author's reaction when someone filed a bug report (https://github.com/danielquinn/python-php/issues/1#issuecomment-237299687): "Wow, someone's actually using this?"
I've created a new tool to make it easier for humans to browse Wikimedia's APT repository: apt.wikimedia.org. Wikimedia's servers run Debian (Ubuntu is nearly phased out), and for the most part use the standard packages that Debian provides. But in some cases we use software that isn't in the official Debian repositories, and distribute it via our own APT repository.
For a while now I've been working on different things where it's helpful for me to be able to see which packages are provided for each Debian version. I was unable to find any existing, reusable HTML browsers for APT repositories (most people seem to use the commandline tools), so I quickly wrote my own.
Introducing the Wikimedia APT browser. It's a short (less than 100 lines) Python and Flask application that reads from the Package/Release files that APT uses, and presents them in a simple HTML page. You can see the different versions of Debian and Ubuntu that are supported, the different sections in each one, and then the packages and their versions.
There's nothing really Wikimedia-specific about this, it would be trivial to remove the Wikimedia branding and turn it into something general if people are interested.
The source code is published on Phabricator and licensed under the AGPL v3, or any later version.