Python 100 project #17: 404 page for Flask

So far the website I created, there is no error handling. First of all, I implemented 404 page, which is used in case there is no page(or files) found for the requested directory.

 

Output Example:

– Default 404 page … This page does serve the what it’s supposed to (to inform the user there is no file found), but I like it to be more unique.

– Customized 404 page … I pasted a image so that it looks more distinctive. At this moment, it’s not responsive at all, and the image size is fixed.

 

Here is the changes I made (for full history you can check my github repository):

– This is 404 page html template.

– This is error handling module. I used separate module rather than using existing routes module.

– This is init file to include newly created error routing.