Code-Society-Lab / Code-Society-Lab/matrixpy
Scheduler: Add `unschedule` method
Open
good first issue
- Dominant language
- Python
- Stars
- 14
- Forks
- 7
- Avg merge
- 8d 19h
- Merged PRs (30d)
- 5
Description
Jobs registered with `schedule()` can't be removed at runtime. This is needed for bots that conditionally disable scheduled tasks.
### Proposed API
```python
def unschedule(self, name: str) -> None
```
### Example
```python
bot.scheduler.unschedule("morning_update")
```
### Before opening a PR
- Write unit tests
- Run `mypy matrix/`
- Run `pytest tests/`
- Run `black .`
Contributor guide
Assessment
This issue has not been assessed yet.