Skip to content

samdoghor/myte

Myte Documentation

Python web project tooling made easy.

Last commit GitHub Release GitHub License PyPI - Version PyPI - Python Version

Myte is a framework-aware command-line toolkit for starting and running Python web applications. It gives Python developers a consistent project workflow across Flask, FastAPI, Tornado, Bottle, Pyramid, and CherryPy without forcing every framework into the same shape. Each generated project keeps the conventions of its chosen framework, while Myte provides the common tooling layer around it: template discovery, project creation, dependency installation, development server startup, file watching, reloads, URL display, and clearer startup hints.

Most Python web frameworks are excellent once the application is already running, but the first few minutes of a project often feel repetitive: choose a folder structure, create environment files, wire a server entrypoint, remember the right command, install dependencies, and configure reload behavior. Myte handles that setup path and records the important project metadata in myte.toml, so the generated app is not just a copied folder. It becomes a Myte-aware project that can be inspected, installed, and run through one predictable CLI.

The goal is to bring the smoothness people expect from tools like Vite into the Python web ecosystem. myte create starts the project, myte templates shows what is available, myte install installs project dependencies, and myte dev starts the correct framework server with reloads and local URL output. Myte does not replace Flask, FastAPI, or any other framework; it coordinates them so switching between project types does not mean relearning the basic development workflow every time.

Myte is still early, but the core tooling direction is in place: every supported framework now has both fullstack and REST API templates, and the CLI is designed to grow into a broader local development companion for Python web projects.

Why Use Myte

Use Myte when you want a fast, opinionated start for a Python web app without reducing your project to a disposable boilerplate folder. A Myte project gives you a working server entrypoint, environment configuration, health route, dependency file, and development workflow from the first command.

Myte is useful when:

  • You want to compare frameworks without rebuilding the same starter structure by hand.
  • You need a repeatable way to create fullstack apps and REST APIs.
  • You want generated projects to include enough structure for real development, not only a hello-world file.
  • You want one command, myte dev, to start the right framework server and show where it is running.
  • You want file watching and restarts handled consistently across framework templates.
  • You want new contributors to run a project without first learning framework-specific startup details.

Features

  • Project scaffolding from bundled templates
  • Template discovery from the CLI
  • Non-interactive creation for scripts and repeatable workflows
  • Interactive creation for guided setup
  • Project metadata via myte.toml
  • Framework-aware development server with myte dev
  • File watching and process restarts during development
  • Local URL display with --host and --port options
  • Clearer Myte hints when framework startup fails
  • Dependency installation command with myte install
  • Health checks with myte doctor
  • Legacy create-myte command kept for compatibility

Supported Templates

Framework Template Status
Flask Fullstack Completed
Flask Restful API Completed
FastAPI Fullstack Completed
FastAPI Restful API Completed
Tornado Fullstack Completed
Tornado Restful API Completed
Bottle Fullstack Completed
Bottle Restful API Completed
Pyramid Fullstack Completed
Pyramid Restful API Completed
CherryPy Fullstack Completed
CherryPy Restful API Completed

Installing

It is recommended to install Myte outside a project virtual environment if you want it available globally for bootstrapping new projects.

pip install myte

or

python -m pip install myte

Usage

List available templates:

myte templates

Create a project without prompts:

myte create myte-project --framework flask --template fullstack

Create a REST API project:

myte create api-project -f flask -t restful-api

Create the same shape with another framework:

myte create api-project -f fastapi -t restful-api
myte create site-project -f tornado -t fullstack

Use the guided wizard:

myte create --interactive

The old command still works:

create-myte

Project Workflow

After creating a project:

cd myte-project
myte install
myte dev

myte dev starts the framework recorded in myte.toml, prints the local URL, keeps the framework debugger output visible, and restarts the process when project files change. You can also choose the host and port:

myte dev --host 0.0.0.0 --port 8000

Disable Myte-managed reloads:

myte dev --no-reload

Generated projects include a myte.toml file that records the framework, template, and default commands. This gives Myte a project identity to build on as more lifecycle commands are added.

[project]
framework = "flask"
template = "fullstack"
entry = "src/server.py"

[commands]
dev = "python src/server.py"
install = "pip install -r requirements.txt"

CLI Commands

Command Description
myte create Create a project from a template
myte templates List bundled templates
myte inspect <framework> <template> Show template details
myte install [path] Install dependencies for a generated project
myte dev [path] Run a generated project with URL display, reloads, and clearer error hints
myte doctor Check Myte runtime and template availability

Contribution

See Contributing Guide.

License

MIT.

About

A versatile command-line tool designed to streamline your web development process in Python.

Topics

Resources

License

Code of conduct

Contributing

Stars

Watchers

Forks

Sponsor this project

  •  

Packages

 
 
 

Contributors