#264 10 tips every Flask developer should know


Manage episode 261625872 series 83399
By Michael Kennedy and Michael Kennedy (@mkennedy). Discovered by Player FM and our community — copyright is owned by the publisher, not Player FM, and audio is streamed directly from their servers. Hit the Subscribe button to track updates in Player FM, or paste the feed URL into other podcast apps.
Are you a web developer who uses Flask? It has become the most popular Python web framework. Even if you have used it for years, I bet we cover at least one thing that will surprise you and make your Flask code better.
Join me as I speak with Miguel Grinberg about his top 10 list for tips and tricks in the Flask world. They're great!

The 10 tips

  1. No need to use jsonify anymore
  2. Do not store sensitive information in the user session
  3. Using a .env file for secrets - python-dotenv
  4. Windows laptops and Chromebooks are both great Python/Flask development machines with their Linux emulation
  5. Differences between App context and Request context
  6. Flask outside of a web server (Celery workers, cron jobs, etc.)
  7. Use https://github.com/TypeError/secure.py
  8. Use httpie instead of curl to send requests to your app
  9. Flask for asyncio: Quart https://pgjones.gitlab.io/quart/
  10. Greenlet frameworks (gevent, eventlet) and Flask
  11. Blueprints

Links from the show
Miguel on Twitter: @miguelgrinberg
Miguel's blog: blog.miguelgrinberg.com
python-dotenv package: pypi.org
httpie package: httpie.org
Quart: pgjones.gitlab.io
Talk Python episode on Quart: talkpython.fm
secure.py package: github.com

Sentry Error Monitoring, Code TALKPYTHON
Talk Python Training

333 episodes