BookServer web application
TODO: this is how the docs should be organized.
(routing/toctree) Endpoints
How routing works
overview of a request for a page
overview of an api call
(schema.py) Pydantic to validate/convert from HTTP params to Python vars / database access
How Runestone Components interacts with endpoints
(routine/books.py) Book routing/interaction with a book built with Runestone Components.
(routing/assessment.py) Loading data into Runestone Components
(routing/rslogging.py) Storing data from Runestone Components
Security
(routers/auth.py) Shared authentication – same password, different cookies. (Does this belong in another section?)
(db.py?) Database
Why sqlalchemy.
Why we use the sqlalchemy core instead of the ORM.
Use of _and, _or instead of &&, || operators.
Async operations
(crud.py) Put queries into crud.py
(models.py) web2py instructor interface and this app share the database; each “owns” different tables
(alembic/) Migration strategy
- Design
- Development guidelines
- main.py - Define the BookServer
- models.py - definition of database models
- schemas.py – Define validation for endpoint query parameters
- db.py - Database configuration
- session.py - Session Management
- applogger.py - Configure logging for the BookServer
- crud.py - reusable functions for our data model
- Routers
- Internals – TODO a good description here
- login.html - template for the login page
- config.py - Configuring Runestone BookServer
- __main__.py - Provide a simple method to run the server