Skip to content

feat: Add worker --reload option #21

@eelkevdbos

Description

@eelkevdbos

Context
In contrast to the web server, these is no option for the worker to reload on code changes. Incorporating this would speed up development and prevent a lot of manual rebooting the plain dev command.

Current workaround
Watchdog to facilitate this, but it feels like the frameworks setup would be to provide it 'batteries included'.

[tool.plain.dev.run]
worker = {cmd = "uv run watchmedo auto-restart --patterns='*.py' --recursive uv run plain worker run"}

Proposed solution
Having a --reload option for the worker run command that does the reloading for us (e.g. plain worker run --reload). Maybe even let it be the default if going for convention over configuration.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions