Overview

TurboGears 2.5, released on February 18, 2022, adds Python 3.13 support, pyproject.toml configuration, and is the last significant release of the framework.

Main Features

pyproject.toml

The project now supports pyproject.toml configuration, following modern Python packaging standards.

toml
[project]
name = "myproject"
version = "1.0.0"
dependencies = [
    "TurboGears2>=2.5",
    "SQLAlchemy",
]

[project.scripts]
myproject = "myproject.cli:main"

Last significant release

TurboGears 2.5 is the last significant release of the framework. Active development has slowed, but the framework remains functional for existing projects.

python
from tg import expose, TGController
from tg import AppConfig

class RootController(TGController):
    @expose('json')
    def index(self):
        return {'framework': 'TurboGears', 'version': '2.5'}

config = AppConfig(minimal=True, root_controller=RootController())
app = config.make_wsgi_app()

Sources