Learning-Python-Team / UnTruth

Develop a mechanism that uses a classifier to differentiate between a Real and a Fake news. it must be able to read a link and perform analysis to suggest the probability of it being either legit or made-up. A visual interface may be added in the future for interactivity
MIT License
3 stars 6 forks source link

Handle Exceptions #17

Open asiffarhankhan opened 5 years ago

asiffarhankhan commented 5 years ago

The program returns lines of errors when websites that aren't supported by newspaper library is entered as news_url

AttributeError is thrown when websites like 'google.com' are entered in the url. Its better we give a more reasonable error to the user by placing that code inside a try except block

mandjevant commented 5 years ago

We could, for now, simply catch the exception. Since the fake news detector is going to have more modules and functions and a separate mainframe, it might be best to make our own exceptions at the end.