Skip to content
This repository has been archived by the owner on Feb 8, 2022. It is now read-only.

Getting an error page when looking up particular domains #107

Open
bvanrijn opened this issue Dec 13, 2016 · 5 comments
Open

Getting an error page when looking up particular domains #107

bvanrijn opened this issue Dec 13, 2016 · 5 comments

Comments

@bvanrijn
Copy link

bvanrijn commented Dec 13, 2016

Go to https://jsonp.afeld.me/?url=icanhazip.com.

The server (probably) crashes and a CloudFlare 502 error page is shown. JSONProxy starts working after a few minutes.

Maybe this is happening because icanhazip.com contains no valid JSON? I will try with some other sites and post an update here.

@bvanrijn
Copy link
Author

Non-resolvable URLs knock it down as well.

@bvanrijn
Copy link
Author

I even tried google.com and example.com, they worked and showed me their respective HTML pages.

@bvanrijn
Copy link
Author

Related: #63

@bvanrijn bvanrijn changed the title Getting an error page when looking up a particular domain Getting an error page when looking up particular domains Dec 13, 2016
@bvanrijn
Copy link
Author

bvanrijn commented Dec 13, 2016

None of the aforementioned domains failed locally (i.e. responded with an error page, instead of JSON) on Git master branch, but they did return status code 502. It seems CloudFlare implicitly assumes the site's broken once it sends a 502.

Then this is an issue with CloudFlare and not JSONProxy...

@bvanrijn
Copy link
Author

bvanrijn commented Dec 13, 2016

For CloudFlare, however, it seem like it's a feature, not a bug.

Would it make sense to always send a 200 OK response, and have the client figure out if something went wrong? (i.e. the error key is present)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant