Use plugins to load workers and expose cli options
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 42
- Forks
- 31
- Avg merge
- 5h 22m
- Merged PRs (30d)
- 19
Description
Right now, any cli argument is managed directly in the cli.py module. It passes all unknown arguments directly through to all workers. This was good for rapid iteration on worker functionality, but means that exposing arguments for a given worker requires modifying the cli.py module directly (as well as the worker itself).
Instead, consider an approach that is more modular, where the cli config for a worker is managed entirely in the worker. Where workers are "registered" as plugins with watchmaker, and that registration informs watchmaker how to expose the cli options for that worker. Look to pytest and pytest plugins for an example.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reading cli.py and the worker implementations to understand how arguments currently flow to every worker. Compare that structure with pytest and its plugin model. Done means worker-owned CLI configuration can be exposed through registration without requiring direct changes to cli.py, but the issue does not specify the plugin API or tests.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- cli, tooling
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100