Whoops \ Exception \ ErrorException (E_WARNING)
fopen(/tmp/vufind_sessions/sess_h64v6o2g9obajselufmpeqckfo): failed to open stream: No space left on device Whoops\Exception\ErrorException thrown with message "fopen(/tmp/vufind_sessions/sess_h64v6o2g9obajselufmpeqckfo): failed to open stream: No space left on device" Stacktrace: #15 Whoops\Exception\ErrorException in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php:151 #14 fopen in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php:151 #13 VuFind\Session\File:saveSession in /usr/local/vufind/module/VuFind/src/VuFind/Session/AbstractBase.php:185 #12 VuFind\Session\AbstractBase:write in [internal]:0 #11 session_write_close in /usr/local/vufind/vendor/laminas/laminas-session/src/SessionManager.php:240 #10 Laminas\Session\SessionManager:writeClose in /usr/local/vufind/module/VuFind/src/VuFind/Session/Settings.php:75 #9 VuFind\Session\Settings:disableWrite in /usr/local/vufind/module/VuFind/src/VuFind/Controller/QRCodeController.php:79 #8 VuFind\Controller\QRCodeController:showAction in /usr/local/vufind/vendor/laminas/laminas-mvc/src/Controller/AbstractActionController.php:77 #7 Laminas\Mvc\Controller\AbstractActionController:onDispatch in /usr/local/vufind/vendor/laminas/laminas-eventmanager/src/EventManager.php:331 #6 Laminas\EventManager\EventManager:triggerListeners in /usr/local/vufind/vendor/laminas/laminas-eventmanager/src/EventManager.php:188 #5 Laminas\EventManager\EventManager:triggerEventUntil in /usr/local/vufind/vendor/laminas/laminas-mvc/src/Controller/AbstractController.php:103 #4 Laminas\Mvc\Controller\AbstractController:dispatch in /usr/local/vufind/vendor/laminas/laminas-mvc/src/DispatchListener.php:138 #3 Laminas\Mvc\DispatchListener:onDispatch in /usr/local/vufind/vendor/laminas/laminas-eventmanager/src/EventManager.php:331 #2 Laminas\EventManager\EventManager:triggerListeners in /usr/local/vufind/vendor/laminas/laminas-eventmanager/src/EventManager.php:188 #1 Laminas\EventManager\EventManager:triggerEventUntil in /usr/local/vufind/vendor/laminas/laminas-mvc/src/Application.php:331 #0 Laminas\Mvc\Application:run in /usr/local/vufind/public/index.php:71
15
Whoops\Exception\ErrorException
/module/VuFind/src/VuFind/Session/File.php151
14
fopen
/module/VuFind/src/VuFind/Session/File.php151
13
VuFind\Session\File saveSession
/module/VuFind/src/VuFind/Session/AbstractBase.php185
12
VuFind\Session\AbstractBase write
[internal]0
11
session_write_close
/vendor/laminas/laminas-session/src/SessionManager.php240
10
Laminas\Session\SessionManager writeClose
/module/VuFind/src/VuFind/Session/Settings.php75
9
VuFind\Session\Settings disableWrite
/module/VuFind/src/VuFind/Controller/QRCodeController.php79
8
VuFind\Controller\QRCodeController showAction
/vendor/laminas/laminas-mvc/src/Controller/AbstractActionController.php77
7
Laminas\Mvc\Controller\AbstractActionController onDispatch
/vendor/laminas/laminas-eventmanager/src/EventManager.php331
6
Laminas\EventManager\EventManager triggerListeners
/vendor/laminas/laminas-eventmanager/src/EventManager.php188
5
Laminas\EventManager\EventManager triggerEventUntil
/vendor/laminas/laminas-mvc/src/Controller/AbstractController.php103
4
Laminas\Mvc\Controller\AbstractController dispatch
/vendor/laminas/laminas-mvc/src/DispatchListener.php138
3
Laminas\Mvc\DispatchListener onDispatch
/vendor/laminas/laminas-eventmanager/src/EventManager.php331
2
Laminas\EventManager\EventManager triggerListeners
/vendor/laminas/laminas-eventmanager/src/EventManager.php188
1
Laminas\EventManager\EventManager triggerEventUntil
/vendor/laminas/laminas-mvc/src/Application.php331
0
Laminas\Mvc\Application run
/public/index.php71
        foreach (glob($this->path . "/sess_*") as $filename) {
            if (filemtime($filename) + $maxlifetime < time()) {
                unlink($filename);
            }
        }
        return true;
    }
 
    /**
     * A function that is called internally when session data is to be saved.
     *
     * @param string $sessId The current session ID
     * @param string $data   The session data to write
     *
     * @return bool
     */
    protected function saveSession($sessId, $data)
    {
        $sessFile = $this->path . '/sess_' . $sessId;
        if ($handle = fopen($sessFile, "w")) {
            $return = fwrite($handle, $data);
            fclose($handle);
            if ($return !== false) {
                return true;
            }
        }
        // If we got this far, something went wrong with the file output...
        // It is tempting to throw an exception here, but this code is called
        // outside of the context of exception handling, so all we can do is
        // echo a message.
        echo 'Cannot write session to ' . $sessFile . "\n";
        return false;
    }
}
 
        foreach (glob($this->path . "/sess_*") as $filename) {
            if (filemtime($filename) + $maxlifetime < time()) {
                unlink($filename);
            }
        }
        return true;
    }
 
    /**
     * A function that is called internally when session data is to be saved.
     *
     * @param string $sessId The current session ID
     * @param string $data   The session data to write
     *
     * @return bool
     */
    protected function saveSession($sessId, $data)
    {
        $sessFile = $this->path . '/sess_' . $sessId;
        if ($handle = fopen($sessFile, "w")) {
            $return = fwrite($handle, $data);
            fclose($handle);
            if ($return !== false) {
                return true;
            }
        }
        // If we got this far, something went wrong with the file output...
        // It is tempting to throw an exception here, but this code is called
        // outside of the context of exception handling, so all we can do is
        // echo a message.
        echo 'Cannot write session to ' . $sessFile . "\n";
        return false;
    }
}
 
        // Anecdotal testing Today and Yesterday seems to indicate destroy()
        //   is called by the garbage collector and everything is good.
        // Something to keep in mind though.
        return true;
    }
 
    /**
     * Write function that is called when session data is to be saved.
     *
     * @param string $sessId The current session ID
     * @param string $data   The session data to write
     *
     * @return bool
     */
    public function write($sessId, $data)
    {
        if ($this->writesDisabled) {
            return true;
        }
        return $this->saveSession($sessId, $data);
    }
 
    /**
     * A function that is called internally when session data is to be saved.
     *
     * @param string $sessId The current session ID
     * @param string $data   The session data to write
     *
     * @return bool
     */
    abstract protected function saveSession($sessId, $data);
}
 
     *
     * @return void
     */
    public function writeClose()
    {
        // The assumption is that we're using PHP's ext/session.
        // session_write_close() will actually overwrite $_SESSION with an
        // empty array on completion -- which leads to a mismatch between what
        // is in the storage object and $_SESSION. To get around this, we
        // temporarily reset $_SESSION to an array, and then re-link it to
        // the storage object.
        //
        // Additionally, while you _can_ write to $_SESSION following a
        // session_write_close() operation, no changes made to it will be
        // flushed to the session handler. As such, we now mark the storage
        // object isImmutable.
        $storage = $this->getStorage();
        if (! $storage->isImmutable()) {
            $_SESSION = $storage->toArray(true);
            session_write_close();
            $storage->fromArray($_SESSION);
            $storage->markImmutable();
        }
    }
 
    /**
     * Attempt to set the session name
     *
     * If the session has already been started, or if the name provided fails
     * validation, an exception will be raised.
     *
     * @param  string $name
     * @return SessionManager
     * @throws Exception\InvalidArgumentException
     */
    public function setName($name)
    {
        if ($this->sessionExists()) {
            throw new Exception\InvalidArgumentException(
                'Cannot set session name after a session has already started'
    /**
     * Session manager (if instantiated)
     *
     * @var SessionManager
     */
    protected $manager = null;
 
    /**
     * Disable session writes after this point in time.
     *
     * @return void
     */
    public function disableWrite()
    {
        // Set the flag
        $this->disableWrite = true;
 
        // If the session manager is already instantiated, close it!
        if (null !== $this->manager) {
            $this->manager->writeClose();
        }
    }
 
    /**
     * Have session writes been disabled?
     *
     * @return bool
     */
    public function isWriteDisabled()
    {
        return $this->disableWrite;
    }
 
    /**
     * Set a session manager instance.
     *
     * @param SessionManager $sessionManager Session manager
     *
     * @return Settings
     */
    /**
     * Constructor
     *
     * @param Loader          $loader QR Code Loader
     * @param SessionSettings $ss     Session settings
     */
    public function __construct(Loader $loader, SessionSettings $ss)
    {
        $this->loader = $loader;
        $this->sessionSettings = $ss;
    }
 
    /**
     * Send QRCode data for display in the view
     *
     * @return \Laminas\Http\Response
     */
    public function showAction()
    {
        $this->sessionSettings->disableWrite(); // avoid session write timing bug
 
        $params = [];
        foreach ($this->loader->getDefaults() as $param => $default) {
            $params[$param] = $this->params()->fromQuery($param, $default);
        }
        $this->loader->loadQRCode($this->params()->fromQuery('text'), $params);
        return $this->displayQRCode();
    }
 
    /**
     * Return the default 'qrcode not found' information
     *
     * @return \Laminas\Http\Response
     */
    public function unavailableAction()
    {
        $this->sessionSettings->disableWrite(); // avoid session write timing bug
        $this->loader->loadUnavailable();
        return $this->displayQRCode();
    }
     */
    public function onDispatch(MvcEvent $e)
    {
        $routeMatch = $e->getRouteMatch();
        if (! $routeMatch) {
            /**
             * @todo Determine requirements for when route match is missing.
             *       Potentially allow pulling directly from request metadata?
             */
            throw new Exception\DomainException('Missing route matches; unsure how to retrieve action');
        }
 
        $action = $routeMatch->getParam('action', 'not-found');
        $method = static::getMethodFromAction($action);
 
        if (! method_exists($this, $method)) {
            $method = 'notFoundAction';
        }
 
        $actionResponse = $this->$method();
 
        $e->setResult($actionResponse);
 
        return $actionResponse;
    }
}
 
        }
 
        if ($this->sharedManager) {
            foreach ($this->sharedManager->getListeners($this->identifiers, $name) as $priority => $listeners) {
                $listOfListenersByPriority[$priority][] = $listeners;
            }
        }
 
        // Sort by priority in reverse order
        krsort($listOfListenersByPriority);
 
        // Initial value of stop propagation flag should be false
        $event->stopPropagation(false);
 
        // Execute listeners
        $responses = new ResponseCollection();
        foreach ($listOfListenersByPriority as $listOfListeners) {
            foreach ($listOfListeners as $listeners) {
                foreach ($listeners as $listener) {
                    $response = $listener($event);
                    $responses->push($response);
 
                    // If the event was asked to stop propagating, do so
                    if ($event->propagationIsStopped()) {
                        $responses->setStopped(true);
                        return $responses;
                    }
 
                    // If the result causes our validation callback to return true,
                    // stop propagation
                    if ($callback && $callback($response)) {
                        $responses->setStopped(true);
                        return $responses;
                    }
                }
            }
        }
 
        return $responses;
    }
            $event->setParams($argv);
        }
 
        return $this->triggerListeners($event, $callback);
    }
 
    /**
     * @inheritDoc
     */
    public function triggerEvent(EventInterface $event)
    {
        return $this->triggerListeners($event);
    }
 
    /**
     * @inheritDoc
     */
    public function triggerEventUntil(callable $callback, EventInterface $event)
    {
        return $this->triggerListeners($event, $callback);
    }
 
    /**
     * @inheritDoc
     */
    public function attach($eventName, callable $listener, $priority = 1)
    {
        if (! is_string($eventName)) {
            throw new Exception\InvalidArgumentException(sprintf(
                '%s expects a string for the event; received %s',
                __METHOD__,
                (is_object($eventName) ? get_class($eventName) : gettype($eventName))
            ));
        }
 
        $this->events[$eventName][(int) $priority][0][] = $listener;
        return $listener;
    }
 
    /**
     * @events dispatch.pre, dispatch.post
     * @param  Request $request
     * @param  null|Response $response
     * @return Response|mixed
     */
    public function dispatch(Request $request, Response $response = null)
    {
        $this->request = $request;
        if (! $response) {
            $response = new HttpResponse();
        }
        $this->response = $response;
 
        $e = $this->getEvent();
        $e->setName(MvcEvent::EVENT_DISPATCH);
        $e->setRequest($request);
        $e->setResponse($response);
        $e->setTarget($this);
 
        $result = $this->getEventManager()->triggerEventUntil(function ($test) {
            return ($test instanceof Response);
        }, $e);
 
        if ($result->stopped()) {
            return $result->last();
        }
 
        return $e->getResult();
    }
 
    /**
     * Get request object
     *
     * @return Request
     */
    public function getRequest()
    {
        if (! $this->request) {
            $this->request = new HttpRequest();
        }
            );
            return $this->complete($return, $e);
        } catch (\Throwable $exception) {
            $return = $this->marshalBadControllerEvent($controllerName, $e, $application, $exception);
            return $this->complete($return, $e);
        } catch (\Exception $exception) {  // @TODO clean up once PHP 7 requirement is enforced
            $return = $this->marshalBadControllerEvent($controllerName, $e, $application, $exception);
            return $this->complete($return, $e);
        }
 
        if ($controller instanceof InjectApplicationEventInterface) {
            $controller->setEvent($e);
        }
 
        $request  = $e->getRequest();
        $response = $application->getResponse();
        $caughtException = null;
 
        try {
            $return = $controller->dispatch($request, $response);
        } catch (\Throwable $ex) {
            $caughtException = $ex;
        } catch (\Exception $ex) {  // @TODO clean up once PHP 7 requirement is enforced
            $caughtException = $ex;
        }
 
        if ($caughtException !== null) {
            $e->setName(MvcEvent::EVENT_DISPATCH_ERROR);
            $e->setError($application::ERROR_EXCEPTION);
            $e->setController($controllerName);
            $e->setControllerClass(get_class($controller));
            $e->setParam('exception', $caughtException);
 
            $return = $application->getEventManager()->triggerEvent($e)->last();
            if (! $return) {
                $return = $e->getResult();
            }
        }
 
        return $this->complete($return, $e);
        }
 
        if ($this->sharedManager) {
            foreach ($this->sharedManager->getListeners($this->identifiers, $name) as $priority => $listeners) {
                $listOfListenersByPriority[$priority][] = $listeners;
            }
        }
 
        // Sort by priority in reverse order
        krsort($listOfListenersByPriority);
 
        // Initial value of stop propagation flag should be false
        $event->stopPropagation(false);
 
        // Execute listeners
        $responses = new ResponseCollection();
        foreach ($listOfListenersByPriority as $listOfListeners) {
            foreach ($listOfListeners as $listeners) {
                foreach ($listeners as $listener) {
                    $response = $listener($event);
                    $responses->push($response);
 
                    // If the event was asked to stop propagating, do so
                    if ($event->propagationIsStopped()) {
                        $responses->setStopped(true);
                        return $responses;
                    }
 
                    // If the result causes our validation callback to return true,
                    // stop propagation
                    if ($callback && $callback($response)) {
                        $responses->setStopped(true);
                        return $responses;
                    }
                }
            }
        }
 
        return $responses;
    }
            $event->setParams($argv);
        }
 
        return $this->triggerListeners($event, $callback);
    }
 
    /**
     * @inheritDoc
     */
    public function triggerEvent(EventInterface $event)
    {
        return $this->triggerListeners($event);
    }
 
    /**
     * @inheritDoc
     */
    public function triggerEventUntil(callable $callback, EventInterface $event)
    {
        return $this->triggerListeners($event, $callback);
    }
 
    /**
     * @inheritDoc
     */
    public function attach($eventName, callable $listener, $priority = 1)
    {
        if (! is_string($eventName)) {
            throw new Exception\InvalidArgumentException(sprintf(
                '%s expects a string for the event; received %s',
                __METHOD__,
                (is_object($eventName) ? get_class($eventName) : gettype($eventName))
            ));
        }
 
        $this->events[$eventName][(int) $priority][0][] = $listener;
        return $listener;
    }
 
    /**
            $response = $result->last();
            if ($response instanceof ResponseInterface) {
                $event->setName(MvcEvent::EVENT_FINISH);
                $event->setTarget($this);
                $event->setResponse($response);
                $event->stopPropagation(false); // Clear before triggering
                $events->triggerEvent($event);
                $this->response = $response;
                return $this;
            }
        }
 
        if ($event->getError()) {
            return $this->completeRequest($event);
        }
 
        // Trigger dispatch event
        $event->setName(MvcEvent::EVENT_DISPATCH);
        $event->stopPropagation(false); // Clear before triggering
        $result = $events->triggerEventUntil($shortCircuit, $event);
 
        // Complete response
        $response = $result->last();
        if ($response instanceof ResponseInterface) {
            $event->setName(MvcEvent::EVENT_FINISH);
            $event->setTarget($this);
            $event->setResponse($response);
            $event->stopPropagation(false); // Clear before triggering
            $events->triggerEvent($event);
            $this->response = $response;
            return $this;
        }
 
        $response = $this->response;
        $event->setResponse($response);
        return $this->completeRequest($event);
    }
 
    /**
     * Complete the request
$pathParts[] = APPLICATION_PATH . '/vendor';
$pathParts[] = get_include_path();
set_include_path(implode(PATH_SEPARATOR, $pathParts));
 
// Composer autoloading
if (file_exists('vendor/autoload.php')) {
    $loader = include 'vendor/autoload.php';
}
 
if (!class_exists('Laminas\Loader\AutoloaderFactory')) {
    throw new RuntimeException('Unable to load Laminas autoloader.');
}
 
// Run the application!
$app = Laminas\Mvc\Application::init(require 'config/application.config.php');
if (PHP_SAPI === 'cli') {
    return $app->getServiceManager()
        ->get(\VuFindConsole\ConsoleRunner::class)->run();
} else {
    $app->run();
}
 

Environment & details:

Key Value
text http://vufind.umc.cl/Record/oai:doaj.org-article:4a60379b0b9f4aa193f18c6167c77480
level L
size 3
margin 4
empty
empty
empty
Key Value
__Laminas Array ( [_REQUEST_ACCESS_TIME] => 1711650511.615 [_VALID] => Array ( [Laminas\Session\Validator\Id] => h64v6o2g9obajselufmpeqckfo ) )
SessionState Laminas\Stdlib\ArrayObject Object ( [storage:protected] => Array ( [cookiePath] => / ) [flag:protected] => 2 [iteratorClass:protected] => ArrayIterator [protectedProperties:protected] => Array ( [0] => storage [1] => flag [2] => iteratorClass [3] => protectedProperties ) )
Key Value
REDIRECT_VUFIND_ENV development
REDIRECT_VUFIND_LOCAL_DIR /usr/local/vufind/local
REDIRECT_STATUS 200
VUFIND_ENV development
VUFIND_LOCAL_DIR /usr/local/vufind/local
HTTP_HOST vufind.umc.cl
HTTP_ACCEPT */*
HTTP_USER_AGENT claudebot
HTTP_X_FORWARDED_FOR 18.209.209.246
HTTP_X_FORWARDED_HOST busca.umc.cl
HTTP_X_FORWARDED_SERVER busca.umc.cl
HTTP_CONNECTION Keep-Alive
PATH /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
SERVER_SIGNATURE <address>Apache/2.4.51 (Debian) Server at vufind.umc.cl Port 80</address>
SERVER_SOFTWARE Apache/2.4.51 (Debian)
SERVER_NAME vufind.umc.cl
SERVER_ADDR 10.111.120.20
SERVER_PORT 80
REMOTE_ADDR 10.111.120.170
DOCUMENT_ROOT /usr/local/vufind/public
REQUEST_SCHEME http
CONTEXT_PREFIX
CONTEXT_DOCUMENT_ROOT /usr/local/vufind/public
SERVER_ADMIN [no address given]
SCRIPT_FILENAME /usr/local/vufind/public/index.php
REMOTE_PORT 41056
REDIRECT_URL /QRCode/Show
REDIRECT_QUERY_STRING text=http%3A%2F%2Fvufind.umc.cl%2FRecord%2Foai%3Adoaj.org-article%3A4a60379b0b9f4aa193f18c6167c77480&level=L&size=3&margin=4
GATEWAY_INTERFACE CGI/1.1
SERVER_PROTOCOL HTTP/1.1
REQUEST_METHOD GET
QUERY_STRING text=http%3A%2F%2Fvufind.umc.cl%2FRecord%2Foai%3Adoaj.org-article%3A4a60379b0b9f4aa193f18c6167c77480&level=L&size=3&margin=4
REQUEST_URI /QRCode/Show?text=http%3A%2F%2Fvufind.umc.cl%2FRecord%2Foai%3Adoaj.org-article%3A4a60379b0b9f4aa193f18c6167c77480&level=L&size=3&margin=4
SCRIPT_NAME /index.php
PHP_SELF /index.php
REQUEST_TIME_FLOAT 1711650511.5944
REQUEST_TIME 1711650511
empty
0. Whoops\Handler\PrettyPageHandler