<!-- mobian-agent-page publisher="dailydev" canonical="https://daily.dev/posts/an-exceptional-junior-nx5paxpfa" -->

---
title: An Exceptional Junior | daily.dev
description: A junior developer, tasked with implementing error handling in a Python Flask application, created a convoluted function to determine if an object is an...
canonical: https://daily.dev/posts/an-exceptional-junior-nx5paxpfa
twitter:card: summary_large_image
twitter:site: @dailydotdev
og:type: website
og:site_name: daily.dev
og:title: An Exceptional Junior | daily.dev
og:description: A junior developer, tasked with implementing error handling in a Python Flask application, created a convoluted function to determine if an object is an...
og:url: https://daily.dev/posts/an-exceptional-junior-nx5paxpfa
og:image: https://api.daily.dev/og/posts/nx5PAxpFA.png
og:image:alt: An Exceptional Junior
og:image:width: 1200
og:image:height: 630
og:locale: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# An Exceptional Junior

**[The Daily WTF](https://daily.dev/sources/thedailywtf)** · 4 min read · 36 upvotes · 2 comments

## Summary

A junior developer, tasked with implementing error handling in a Python Flask application, created a convoluted function to determine if an object is an exception. The function uses type comparisons and exception handling inappropriately, demonstrating a common mistake of misusing exception handling and misunderstanding proper code reuse strategies. The junior's intent was to reuse a single function as both a request and error handler, leading to unnecessary complexity.

## Full article

daily.dev links to this article rather than hosting it. Read it at the original source: <https://thedailywtf.com/articles/an-exceptional-junior>

## Community discussion

Top comments from developers on daily.dev.

**@rv0** · 4 upvotes

> ![image](https://res.cloudinary.com/daily-now/image/upload/s--3rdSzKLQ--/f_auto/v1723162204/ugc/content_4541ecfd-2721-4e17-9bcc-354a2440a88c)

**@a\_meb\_a** · 1 upvotes

> as a junior dev, yeah dude the way "we code" can be very rigid at the beginning.. very sorry for our Seniors or TL -_-

---

Tags: [#webdev](https://daily.dev/tags/webdev), [#python](https://daily.dev/tags/python), [#flask](https://daily.dev/tags/flask)

[View this post on daily.dev](https://daily.dev/posts/an-exceptional-junior-nx5paxpfa)

```json
{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://daily.dev/#organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180},"sameAs":["https://twitter.com/dailydotdev","https://github.com/dailydotdev","https://www.linkedin.com/company/daily-dev-ltd"]},{"@type":"WebSite","@id":"https://daily.dev/#website","url":"https://daily.dev","name":"daily.dev","publisher":{"@id":"https://daily.dev/#organization"},"potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://daily.dev/search?q={search_term_string}"},"query-input":"required name=search_term_string"}}]}
{"@context":"https://schema.org","@type":"TechArticle","headline":"An Exceptional Junior","url":"https://daily.dev/posts/an-exceptional-junior-nx5paxpfa","mainEntityOfPage":{"@type":"WebPage","@id":"https://daily.dev/posts/an-exceptional-junior-nx5paxpfa"},"datePublished":"2024-07-29T10:42:22.438Z","dateModified":"2024-10-05T18:34:01.842Z","description":"A junior developer, tasked with implementing error handling in a Python Flask application, created a convoluted function to determine if an object is an...","image":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/8b1b05f1d37d4ce032f91ef813127d14?_a=AQAEuiZ","thumbnailUrl":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/8b1b05f1d37d4ce032f91ef813127d14?_a=AQAEuiZ","isAccessibleForFree":true,"articleSection":"The Daily WTF","inLanguage":"en","publisher":{"@type":"Organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180}},"author":{"@type":"Organization","name":"The Daily WTF","logo":"https://media.daily.dev/image/upload/t_logo,f_auto/v1/logos/d21a6aa61a7244d893a3b3284df8e2ef","url":"https://daily.dev/sources/thedailywtf"},"commentCount":2,"discussionUrl":"https://daily.dev/posts/an-exceptional-junior-nx5paxpfa","interactionStatistic":[{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":36},{"@type":"InteractionCounter","interactionType":{"@type":"CommentAction"},"userInteractionCount":2}],"keywords":"webdev,python,flask","timeRequired":"PT4M"}
{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://daily.dev"},{"@type":"ListItem","position":2,"name":"The Daily WTF","item":"https://daily.dev/sources/thedailywtf"},{"@type":"ListItem","position":3,"name":"An Exceptional Junior"}]}
{"@context":"https://schema.org","@type":"WebPage","@id":"https://daily.dev/posts/an-exceptional-junior-nx5paxpfa","comment":[{"@type":"Comment","text":"","datePublished":"2024-08-09T00:10:07.661Z","url":"https://daily.dev/posts/nx5PAxpFA#c-2JERAtdFo","author":{"@type":"Person","name":"rv0","url":"https://daily.dev/rv0","image":"https://media.daily.dev/image/upload/s--BAFGLr7O--/f_auto/v1717788944/avatars/avatar_88RktXx9a9jVkKmJDLk6N"},"interactionStatistic":{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":4}},{"@type":"Comment","text":"as a junior dev, yeah dude the way “we code” can be very rigid at the beginning… very sorry for our Seniors or TL -_-","datePublished":"2024-09-10T10:38:48.680Z","url":"https://daily.dev/posts/nx5PAxpFA#c-SHJcSqK3x","author":{"@type":"Person","name":"Phillippe Michel Weir","url":"https://daily.dev/a_meb_a","image":"https://media.daily.dev/image/upload/s--BwH-uTMq--/f_auto/v1740136991/avatars/avatar_N403VFK9lAHNRwlSAhl1h"},"interactionStatistic":{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":1}}]}
```

