Cannot reproduce Undefined index: user_selectable

Most of these errors (and the other one you just mentioned me in) are indicative mostly of the expected cache data not being available for some reason. Particularly the setGroupStyles and setMediaSites ones as that data comes straight from the cache.

I'm going to run my local install with file system caching for a bit to see if I can reproduce a similar issue, but it potentially is just indicative of the files not being read for some reason, or the reads taking longer than they're supposed to.

If there are any patterns to when the errors occur, such as at particularly busy times or similar then that could be quite telling.

The days these occurred were all over the map, Wed/Sat/Sun. Times all over the place too, so I can't find reason as of yet!
 
These two issues (Argument 1 passed to XF\Pub\Controller\AbstractController::getRequestIpConstraintCached()) and (Undefined index: user_selectable) (and some of the others) are very likely the same root cause - they seem to be related to data coming from the cache which either isn't in the cache when it should be, or isn't in a valid format when it comes out of the cache so I've merged them together.
 
Got another of the getRequestIpConstraintCached()) ones above while I was sleeping...

What should all the permissions be inside the various cache directories and files within (we only use filecache), and I'll double check those in detail as well?

Thanks!
 
Usually you'd just ensure that internal_data is recursively writable and owned by the appropriate user. Admittedly, they should already be like that, seeing as presumably things like attachments and code_cache (where we store compiled templates) are working fine.

I'm not sure if there are any other factors that could make it fall over, but it's a good start :)
 
Got the same error last night (once) by a logged in user.

ErrorException: [E_NOTICE] Undefined index: user_selectable src/XF/Style.php:275

Stacktrace:

Code:
#0 src/XF/Style.php(275): XF::handlePhpError(8, '[E_NOTICE] Unde...', '/var/www/html...', 275, Array)
#1 src/XF/Pub/App.php(417): XF\Style->offsetGet('user_selectable')
#2 src/XF/Mvc/Dispatcher.php(395): XF\Pub\App->preRender(Object(XF\Mvc\Reply\View), 'json')
#3 src/XF/Mvc/Dispatcher.php(58): XF\Mvc\Dispatcher->render(Object(XF\Mvc\Reply\View), 'json')
#4 src/XF/App.php(2184): XF\Mvc\Dispatcher->run()
#5 src/XF.php(391): XF\App->run()
#6 index.php(20): XF::runApp('XF\\Pub\\App')
#7 {main}

Request state
Code:
array(4) {
  ["url"] => string(27) "/login/keep-alive"
  ["referrer"] => string(66) "REDACTED"
  ["_GET"] => array(0) {
  }
  ["_POST"] => array(2) {
    ["_xfResponseType"] => string(4) "json"
    ["_xfToken"] => string(8) "********"
  }
}

Caching is indeed enabled (but haven't gotten any similar error in the past and I can confirm it is setup properly).
 
Top Bottom