Recent Entries 4
- debug critical 112d agoCorrect way to try/except using Python requests module?``` try: r = requests.get(url, params={'s': thing}) except requests.ConnectionError, e: print(e) ``` Is this correct? Is there a better way to structure this? Will this cover all my bases?
- debug critical 112d agoCorrect way to try/except using Python requests module?``` try: r = requests.get(url, params={'s': thing}) except requests.ConnectionError, e: print(e) ``` Is this correct? Is there a better way to structure this? Will this cover all my bases?
- pattern tip 124d agoDjango custom middleware — request/response processing pipelineCross-cutting concerns like request logging, API key validation, or response compression need to run for all or most views without modifying each view function.
- pattern moderate 124d agoAstro middleware for authentication and request processingRunning authentication checks or preprocessing logic on every request in Astro without a central place to handle it. Duplicating auth logic in every page.