New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adding code to detect and report broken links. #13
Conversation
Thanks for this one but instead of raising an exception, Photon should append the url to the |
Hi, Thank you for your reply. |
The |
I want to fix this asap but I am not sure if it would be a good thing to do it myself instead of waiting for you to fix your code 😕 |
Hey, I am doing it now =D |
You may want to do this: >>> response = requests.get('http://example.com/good_page.php')
>>> response.status_code
200
>>> response.status_code == requests.codes.ok
True
>>> response = requests.get('http://example.com/bad_page.php')
>>> response.status_code
404
>>> response.status_code == requests.codes.ok
False |
Hi, Please review changes :) |
Just tested this against |
Tip 💡 : Always use 4 spaces or a tab of equivalent width for indentation, that's the standard. You were using 3, I had to fix it. |
Current Issue: Broken links for which server returns 404 status (or similar error) are not reported as failed links, instead these erroneous pages are parsed for text content.