path('/user/user.username:user/', view_profile) with Willem Van Onsem
summary
Argues that lazy model converters let path converters return proxies that defer DB queries or combine queries per database, concretely reducing roundtrips (demo shows one saved query when linking article and author) and preserving reverse URL generation; implements a management command and GitHub repo. Presents a regex-overlap checker that uses Greenery to compute intersections and flags unreachable or contained patterns, and cites admin pain with CharField PKs like "remove" or "history". URL overlap tool is work in progress.
AI-written summary · about
chapters (9)
- 0:00Advanced path converters
- 1:23Model-based converters
- 8:27Lazy queries with converters
- 14:30Benefits and challenges
- 18:29Overlap detection in URLs
- 25:41Overlap detection tools
- 28:36Implementation status
- 29:00Class-based views with converters
- 30:28Q&A
related talks
28mDo Your Views Know Too Much?
32mWhere did the OO go? Views Should be Objects Too!
40mBlow Up Your Views
25mBrowser History Confessional: Searching My Recent Searches
38mRefactoring Fat Models with Patterns
26mDjango Unstrained
19mDesign like Karpathy is watching
41mOff the Tracks - Challenging the Rails Mindset
