Mounts included.
When native events don’t make it through, polling keeps an eye on your Docker, Vagrant, and network folders.
Explore pollingYour code. Back in motion.
A small watcher for your Python projects. Pyreload restarts your app when files change, even across Docker and Vagrant mounts.
Python 3.8+ · macOS, Linux & Windows · One command
$ pip install pyreload-cli
Successfully installed pyreload-cli
$ pyreload app.py
Watching for changes in *.py
Hello, world.
Restarting due to file changes...
Hello, next idea.
pip install pyreload-cliA shorter loop
Keep your attention on the code. Pyreload handles the stop-and-start in between.
Try the quick startRun pyreload app.py in your project. Python files are watched by default.
Matching changes stop the current process and start it again with your latest code.
Add watch patterns, ignore noisy files, or keep project defaults in a simple JSON file.
A command for your kind of work
A script on your laptop. A module in a terminal. A folder mounted into a container. Pick a starting point and make it yours.
Start in your project directory. Pyreload watches Python files recursively and restarts your script when a matching file changes.
Script quick startpyreload app.pyPython files are watched by default.
Small tool. Useful details.
When native events don’t make it through, polling keeps an eye on your Docker, Vagrant, and network folders.
Explore pollingWatch Python, templates, or configuration. Ignore caches and generated files. Keep your defaults with the project.
Choose your patternsRun a Python module or a shell command. Restart on demand with rs, or use clean mode when there’s no terminal input.
Run a commandLess noise. More intention.
Templates count. Logs don’t have to. Keep your watch and ignore rules in a small JSON file, right next to your code.
Make it a project defaultSave as .pyreloadrc in your project, then run pyreload app.py.
{
"watch": ["*.py", "*.html"],
"ignore": ["*.log", "*__pycache__*"]
}With these rules
app.pyRestartstemplates/index.htmlRestartsdebug.logIgnored__pycache__/app.pycIgnoredA few things worth knowing
Everything else is in the docs, from your first command to the details of process handling.
Explore the documentationNo. Run your existing script with pyreload app.py. Pyreload watches files from the current directory and manages restarting the child process.
Get startedYes. Repeat --watch to include patterns such as *.html or *.yaml, or keep your watch and ignore lists in a project configuration file.
Choose watch patternsTry --polling inside the container. Some mounted filesystems do not forward native change events. Polling checks for changes periodically, at the cost of additional CPU use.
Set up DockerType rs and press Enter in the running terminal. Type help for interactive commands. In clean mode, terminal input is disabled.
See interactive commandsPyreload is built for the development loop. It restarts its immediate child process; it does not supervise a full process tree or provide production deployment orchestration.
Understand process handlingYour next save is the start
pip install pyreload-cli