When a user releases a new version of a Scribunto module in GitLab, MediaWiki can start fetching it, but it can't allow users to switch the deployed state of the package until fetching is complete. So users need to be able to see whether a package has been fetched or not.
Also, if dependencies between packages are allowed, there needs to be a tool for helping users to update multiple packages as required by the specified version constraints.
Users should be informed when the deployed version of a package is out of date.
As such, wikitext is not ideal as a UI for specifying deployed versions of packages. There needs to be a proper HTML/JS user interface.
I think this interface should be shared between Scribunto and Gadgets. A package can provide Lua modules, or it can provide a gadget. There's no real difference between the release, fetch and update tools between these two use cases. The present work only calls for Scribunto integration, but I think package management belongs in a separate extension (Produnto). Scribunto will provide a package type.
A package will have a JSON manifest analogous to extension.json.
The canonical deployment state would be backed by a wiki page, for auditing and abuse control. Manual rollback would be possible. Arbitrary edits would be possible but would generate error messages which would be difficult to interpret and resolve. Fetching would not be triggered by a wikitext edit, it would be API only.
Mockup suggestion:
Supporting action API
- List packages
- Name
- Type (scribunto)
- Localised description
- Doc URL
- Source URL
- Deployed version
- Latest version
- List package versions
- Version
- Dependencies
- Release notes?
Write actions will be done by editing the deployment page (T412323)
