Forums

Reload problem

Hello,

I've made some changes on the timeout settings on my elasticsearch client. That led to the message: Your webapp took a long time to reload. It probably reloaded, but we were unable to check it." when I tried to reload. I changed the settings back to the version where it was working, but I can't get rid of the reload problem. The "running tasks" show nothing. Could you please kill the processes, it seems there's something working in the background?

Thank you!

Is your elastic search client an http(s)-based client and is the server on the whitelist? If not, then the connection is probably just timing out and causing your web app to fail.

There is nothing "working in the background" for us to kill.

I think it's http, it's the official es python client. https://elasticsearch-py.readthedocs.io/en/v7.13.3/# This problem is going on for many hours now, and I never had this problem although I was working intensively with it. After my apparently wrong settings with the timeout the process stuck and I reloaded the python server. Before I restarted this was in the error log:

> 2021-07-15 10:12:21,836: OSError: write error 2021-07-15 10:12:21,838:
> OSError: write error 2021-07-15 10:12:21,838: OSError: write error
> 2021-07-15 10:12:21,839: OSError: write error 2021-07-15 10:12:21,840:
> OSError: write error 2021-07-15 10:12:21,840: OSError: write error

After the restart the was a bunch of BlockingIOErrors like this:

2021-07-15 11:07:33,153: BlockingIOError: [Errno 11] write could not complete without blocking
2021-07-15 11:07:33,153:   File "/var/www/mmps_pythonanywhere_com_wsgi.py", line 9, in <module>
.....

Another thing is that it takes only some seconds to display the "Your webapp took a long time to reload..." error, conversely I had in the past reload times of a minute, and it was fine. I can also run scripts from the console and interact with elasticsearch What can I do now?

Read the rest of that traceback . It will indicate to you what your code was trying to do when that error was raised and you can use that to start working out what is causing it.

I changed what was causing the error

I deleted the file, then re-uploaded, commented out the traceback errors, then uncommented, now it works. No clue why it wasn't before.. thanks anyway for your quick replies!