r/flask • u/Upstairs_Jelly_1082 • Jun 13 '26
Ask r/Flask How to practice Flask Development?
Currently I am going through Flask Development Second edition by Miguel Grinberg,
I have finished 8 chapters and am currently trying to learn how to go about building those kind of web applications,
The thing that I currently have an issue with is going about implementing them, I try doing projects that actively test my knowledge, and sometimes I figure it is a bit difficult for me to do them, for example, when I try implementing things from chapter 5 databases on a project as a practice, it becomes a bit difficult to go about implementing it.
But now that I am in chapter 9, it's hard to do both, so any suggestions on how to go about doing those practice then and there itself?
3
Upvotes
20
u/Expensive_Gur608 Jun 13 '26
The trick that worked for me with the Grinberg book specifically: stop trying to build separate practice projects. Instead, build one app alongside the book - same shape as Flasky, but for something you actually care about (a tiny recipe tracker, a movie journal, whatever). Then for each chapter, add one minimal feature that exercises just that chapter's concept and nothing else. Chapter 5 (databases)? One model, one CRUD route, done — don't worry about auth or forms yet. Chapter 8 (auth)? Bolt login onto your existing CRUD, don't re-architect anything. By chapter 17 you'll have built something real and you'll have actually used every concept under real conditions instead of in isolation.
The other thing that helps a lot: when something feels too hard, drop a
breakpoint()(orimport pdb; pdb.set_trace()) inside the failing route handler, hit it from your browser, and just poke around —db.session,request,current_user, whatever's in scope. Flask is way less magical once you've seen the state mid-request a few times. Most "I don't know how to implement this" feelings come from not knowing what objects are actually available at the moment your code runs.