getgrav / grav-plugin-admin

Grav Admin Plugin
http://getgrav.org
MIT License
355 stars 227 forks source link

Web server is returning an unknown error #993

Open Athunik opened 7 years ago

Athunik commented 7 years ago

Hello,

After updating admin panel, I've been getting a quite strange error. Usually I'm getting it when looking at dashboard, but not always. Sometimes getting it, when editing pages as well. chrome_2017-02-21_17-16-13

I really don't know what to do.. Few hours ago I did reinstall to my VPS, because I was out of ideas really. But seems like replacing Debian 7 with Debian 8 didn't resolve this problem. And clean install of GRAV didn't fix this problem as well. I have no idea what is the problem and _publichtml/logs folder has no sign of the problem.

After all this trouble, I'm getting CloudFlare errors from time to time as well. The error message of CloudFlare is... Error 520: Web server is returning an unknown error

Could someone guide me? Is it just me or this happens to everyone?

w00fz commented 7 years ago

Check the XHR response in the browser developer tools Network tab. Buried down there is the full body error.

Also, still in the XHR response, check which request is actually failing and what URL is getting called.

rhukster commented 7 years ago

Is it possible to disable CloudFlare? This error appears to be related: https://support.cloudflare.com/hc/en-us/articles/200171936-Error-520-Web-server-is-returning-an-unknown-error

Athunik commented 7 years ago

Huh, that XHR is pretty neat little tool.

Using this little tool, I found out that CloudFlare causes this problem. Or at least amplifies it.. somehow.. Now I'm using Hurricane Electric DNS and everything seems to be fine.. almost. The old error is gone, completely. But now I have new one, but this doesn't look that serious, because at least now I can change stuff on my website. However I would like to fix this one as well.. Here are the errors and XHR results..

getupdates chrome_2017-02-22_14-37-28

flaviocopes commented 7 years ago

If you click on that, what's in the Response tab? e.g.

screen shot 2017-02-22 at 13 55 55

Athunik commented 7 years ago

It fails to load response data, when this error appears. chrome_2017-02-22_15-07-04

But when getUpdates does work, then I'm getting something like this..

{"status":"success","payload":{"resources":{"total":0,"plugins":[],"themes":[]},"grav":{"isUpdatable":false,"assets":{"grav-admin":{"name":"grav-admin-v1.1.17.zip","type":"application\/octet-stream","size":7166786,"download":"https:\/\/getgrav.org\/download\/core\/grav-admin\/1.1.17"},"grav-update":{"name":"grav-update-v1.1.17.zip","type":"application\/octet-stream","size":2633172,"download":"https:\/\/getgrav.org\/download\/core\/grav-update\/1.1.17"},"grav":{"name":"grav-v1.1.17.zip","type":"application\/octet-stream","size":4087011,"download":"https:\/\/getgrav.org\/download\/core\/grav\/1.1.17"}},"version":"1.1.17","available":"1.1.17","date":"2017-02-17T22:34:08Z","isSymlink":false},"installed":9,"flushed":true}}

OleVik commented 7 years ago

Since the DNS appears to interfere with functionality you could make it ignore the admin-folder, at least in CloudFlare (I'm not sure if Hurricane Electric DNS has a similar option). This is of course not a fix, but bypassing the problem. Like when disabling JS-optimization, you can add a page-rule for example.com/admin that hinders any of their functionality there.

joinboone commented 6 years ago

My site is Error 520 https://melidl.com/ https://melidl.com/category/مالتی-مدیا/مستند/ https://melidl.com/category/مالتی-مدیا/فیلم/ https://melidl.com/8643-bazaar/

joinboone commented 6 years ago

https://www.robotkhabar.ir/fa/news/details/1432/-پیام-آیت‌الله-هاشمی-شاهرودی-به-آیت‌الله-مدرسی-یزدی-/ https://www.robotkhabar.ir/