Not a bug "The site is currently being upgraded. Please check back later." with invalid Guzzle HTTP request

Jake B.

Well-known member
Affected version
2.0.2
If Guzzle ever attempts to make an invalid HTTP request XF catches this and throws a white page that just says "The site is currently being upgraded. Please check back later.". Just a bit annoying trying to figure out what exactly is wrong with the request when this happens :)
 
Turns out it had nothing to do with an invalid request, it just happened when I was attempting to use Guzzle 6 syntax:

Code:
$client = \XF::app()->http()->createClient(['base_uri' => 'http://somedomain.com']);
$url = '/some-path';
$request = $client->request('get', $url);

Once I updated it to use Guzzle 5's syntax it worked fine
 
BTW, it sounds like you have an add-on stuck in the "is_processing" state, which we've seen some reports of but never reproduced. It likely indicates that an install/upgrade/rebuild was never properly completed.
 
Ah yep, there was one stuck with is_processing as 1. What actually triggers the "your board is being upgraded" message though? it only seemed to happen specifically when I was running that code in my previous post? I've never had it happen on any other PHP errors, which is interesting
 
If an add-on is being processed, it's considered that an upgrade of some sort is happening and the error is very likely caused by an inconsistent state. Thus we display that error message.

(The is_processing flag should only be set while an install/upgrade/rebuild of an add-on is happening. It's cleared at the end. If it doesn't get finished, then you can get stuck in that state but you should generally have been aware of issues happening with the process at some point.)
 
Back
Top Bottom