Continue from Parts I–III

Python Foundations Workshop IV

Build Workshop Desk, a browser app with a searchable catalog, sign-in, reservations, and accessible forms.

Python Foundations Workshop IV cover with a browser window, form field, and key
1,000pages
96runnable cases
12chapters
3connected projects

12 chapters

Find a topic

12 chapters

  • 01 Route a browser request

    Route requests by method and path. Decode dynamic IDs and keep URL construction separate from HTML interpolation.

    Pages 5–77 · 8 cases
  • 02 Render HTML with explicit context

    Render HTML with context-aware encoding. Preserve user text without giving it markup or navigation authority.

    Pages 78–150 · 8 cases
  • 03 Forms and server-side validation

    Accept browser form data through a bounded parser. Validate values and relationship rules before a write.

    Pages 151–223 · 8 cases
  • 04 Accessible forms and views

    Use semantic markup, meaningful action labels, errors associated with inputs, and status announcements.

    Pages 224–296 · 8 cases
  • 05 Browser write flows and persistence

    Commit state changes as one transaction. Use unique constraints, check capacity, and redirect after a successful POST.

    Pages 337–409 · 8 cases
  • 06 Session cookies and expiry

    Map a cookie to server-side state. Enforce expiry, rotate at sign-in, and invalidate at sign-out.

    Pages 410–482 · 8 cases
  • 07 CSRF and browser write protection

    Check form tokens before browser writes. Use the current session and apply a deliberate origin policy.

    Pages 483–555 · 8 cases
  • 08 Sign-in and resource ownership

    Verify the actor separately from the requested resource. Scope every private query and mutation to that actor.

    Pages 556–628 · 8 cases
  • 09 Search, filters and pagination

    Design search and pagination as part of the browser interface. Keep current filters and stable sort order in navigation.

    Pages 669–741 · 8 cases
  • 10 Response policies and error pages

    Choose status, headers and user feedback that reflect the real outcome. Keep private documents out of shared caches.

    Pages 742–814 · 8 cases
  • 11 Progressive enhancement and browser UX

    Keep a usable native browser path. Add JavaScript enhancements only when their failure leaves the original flow usable.

    Pages 815–887 · 8 cases
  • 12 Browser integration and release rehearsal

    Test realistic sequences and refused actions. Inspect the stored result and verify keyboard behavior separately from HTTP status.

    Pages 888–960 · 8 cases

Three connected projects

Build Workshop Desk

01 · Render a catalog

Route requests and render semantic HTML with escaped search values and workshop detail pages.

02 · Sign in and reserve

Rotate sessions, validate form tokens, reserve a seat in a transaction, and enforce ownership.

03 · Rehearse an accessible release

Check labels, keyboard navigation, denied writes, logout, and a real local HTTP response.

Look inside

See an actual workbook page

Try a browser routing case in the free 16-page excerpt. Preview the source pages from each project.

Open the 16-page sample

Open a workshop detail page, page 7

Get the complete workbook

The PDF and ZIP include 96 runnable cases with assertions and recorded output, a project suite with tests, and a curriculum index. Use Python 3.12 or newer.

Open the Gumroad listing · $20

USD base price. Applicable tax is calculated at checkout.