Skip to content

fix: serve generated routes; install greenlet for async SQLAlchemy - #7

Merged
cultron merged 1 commit into
mainfrom
fix/mount-autogen-router
Oct 29, 2026
Merged

cultron merged 1 commit into
mainfrom
fix/mount-autogen-router

Conversation

@cultron

@cultron cultron commented Oct 29, 2026

Copy link
Copy Markdown
Collaborator

Two bugs that stopped every generated Python service from working:

  1. app/main.py never included autogen_router, so no entity route was served. It now includes it; app/autogen/__init__.py ships an empty router so the import works before the first apso generate (which overwrites that file).
  2. SQLAlchemy 2.1 no longer installs greenlet, and the asyncio extension needs it, so app.main failed to import. The dependency is now sqlalchemy[asyncio].

Tested: pytest tests passes (2 tests) on Python 3.12 with SQLAlchemy 2.1.6; the CLI auth smoke (apsoai/cli feat/jwt-auth) runs CRUD against a generated service on Postgres.

main.py never included app.autogen's autogen_router, so a generated Python
service served no entity routes. The template's app/autogen/__init__.py now
defines an empty router so the import works before the first apso generate.

SQLAlchemy 2.1 no longer installs greenlet, which the asyncio extension needs,
so the app failed to import. Depend on sqlalchemy[asyncio].
@cultron
cultron merged commit 030f90e into main Oct 29, 2026
2 checks passed
@cultron
cultron deleted the fix/mount-autogen-router branch October 29, 2026 03:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant