Upgraded to 4.1.0 and can’t add items. Everything goes fine but when I get to the Item Set, I click on one and it disappears from the list. If I try to go ahead and, it errors. The logs say:
2024-05-10T13:09:22+00:00 ERR (3): Omeka\Api\Exception\BadRequestException: The API does not support the “v1” resource. in /var/www/vhosts/tplibrary.org/local-history/application/src/Api/Manager.php:200
Stack trace: #0 /var/www/vhosts/tplibrary.org/local-history/application/src/Api/Manager.php(115): Omeka\Api\Manager->execute() #1 /var/www/vhosts/tplibrary.org/local-history/application/src/Controller/ApiController.php(81): Omeka\Api\Manager->read() #2 /var/www/vhosts/tplibrary.org/local-history/vendor/laminas/laminas-mvc/src/Controller/AbstractRestfulController.php(373): Omeka\Controller\ApiController->get() #3 /var/www/vhosts/tplibrary.org/local-history/application/src/Controller/ApiController.php(169): Laminas\Mvc\Controller\AbstractRestfulController->onDispatch() #4 /var/www/vhosts/tplibrary.org/local-history/vendor/laminas/laminas-eventmanager/src/EventManager.php(319): Omeka\Controller\ApiController->onDispatch() #5 /var/www/vhosts/tplibrary.org/local-history/vendor/laminas/laminas-eventmanager/src/EventManager.php(179): Laminas\EventManager\EventManager->triggerListeners() #6 /var/www/vhosts/tplibrary.org/local-history/vendor/laminas/laminas-mvc/src/Controller/AbstractController.php(97): Laminas\EventManager\EventManager->triggerEventUntil() #7 /var/www/vhosts/tplibrary.org/local-history/vendor/laminas/laminas-mvc/src/Controller/AbstractRestfulController.php(307): Laminas\Mvc\Controller\AbstractController->dispatch() #8 /var/www/vhosts/tplibrary.org/local-history/vendor/laminas/laminas-mvc/src/DispatchListener.php(132): Laminas\Mvc\Controller\AbstractRestfulController->dispatch() #9 /var/www/vhosts/tplibrary.org/local-history/vendor/laminas/laminas-eventmanager/src/EventManager.php(319): Laminas\Mvc\DispatchListener->onDispatch() #10 /var/www/vhosts/tplibrary.org/local-history/vendor/laminas/laminas-eventmanager/src/EventManager.php(179): Laminas\EventManager\EventManager->triggerListeners() #11 /var/www/vhosts/tplibrary.org/local-history/vendor/laminas/laminas-mvc/src/Application.php(325): Laminas\EventManager\EventManager->triggerEventUntil() #12 /var/www/vhosts/tplibrary.org/local-history/index.php(21): Laminas\Mvc\Application->run()
If I try adding one without adding an Item Set, it errors still and logs this:
I can confirm the problem where the item sets “disappear” when you try to add them (they’re actually being added but we’re not correctly showing the list of current sets there), but that shouldn’t cause an error when saving.
So whatever you have going on that’s causing an error is probably unrelated to that.
The trick with those other errors, like the “Omeka\Api\Exception\NotFoundException” one, is that they can be triggered by simply people or bots visiting the site. So they aren’t necessarily (or likely) associated with what you’re doing yourself.
It would be the more recent one, I hadn’t even logged in earlier then that on the day.
Yes, when I go to add the item, it gives me that error but ONLY when I have a media attached. And I tried it with different ones too (pdf, jpg, png) and it’s the same. I had also turned off all the modeuls too and it didn’t make a difference.
I’m also attaching the error log as well. Ah, actually when I look at the error log there is no entry for what I did today (still got the message above tho).
Can you follow the instructions under “Display error details” on this manual page? That should have the error display directly on this screen you’re seeing.
Yes! And doing so caused all these errors to come up on the page:
Deprecated : Use of “self” in callables is deprecated in /var/www/vhosts/tplibrary.org/local-history/modules/AmazonS3/vendor/aws/aws-sdk-php/src/S3/RegionalEndpoint/ConfigurationProvider.php on line 83
Deprecated : Use of “self” in callables is deprecated in /var/www/vhosts/tplibrary.org/local-history/modules/AmazonS3/vendor/aws/aws-sdk-php/src/DefaultsMode/ConfigurationProvider.php on line 85
Deprecated : Use of “self” in callables is deprecated in /var/www/vhosts/tplibrary.org/local-history/modules/AmazonS3/vendor/aws/aws-sdk-php/src/Endpoint/UseFipsEndpoint/ConfigurationProvider.php on line 82
Deprecated : Use of “self” in callables is deprecated in /var/www/vhosts/tplibrary.org/local-history/modules/AmazonS3/vendor/aws/aws-sdk-php/src/Endpoint/UseDualstackEndpoint/ConfigurationProvider.php on line 83
Deprecated : Use of “self” in callables is deprecated in /var/www/vhosts/tplibrary.org/local-history/modules/AmazonS3/vendor/aws/aws-sdk-php/src/EndpointDiscovery/ConfigurationProvider.php on line 86
Deprecated : Use of “self” in callables is deprecated in /var/www/vhosts/tplibrary.org/local-history/modules/AmazonS3/vendor/aws/aws-sdk-php/src/Retry/ConfigurationProvider.php on line 88
Deprecated : Use of “self” in callables is deprecated in /var/www/vhosts/tplibrary.org/local-history/modules/AmazonS3/vendor/aws/aws-sdk-php/src/ClientSideMonitoring/ConfigurationProvider.php on line 90
Deprecated : Use of “self” in callables is deprecated in /var/www/vhosts/tplibrary.org/local-history/modules/AmazonS3/vendor/aws/aws-sdk-php/src/S3/UseArnRegion/ConfigurationProvider.php on line 83
This is what I get now after uploading:
Omeka\Mvc\Exception\RuntimeException
POST request exceeded maximum size
Details:
Omeka\Mvc\Exception\RuntimeException: POST request exceeded maximum size in /var/www/vhosts/tplibrary.org/local-history/application/src/Mvc/MvcListeners.php:373 Stack trace: #0 /var/www/vhosts/tplibrary.org/local-history/vendor/laminas/laminas-eventmanager/src/EventManager.php(319): Omeka\Mvc\MvcListeners->checkExcessivePost() #1 /var/www/vhosts/tplibrary.org/local-history/vendor/laminas/laminas-eventmanager/src/EventManager.php(179): Laminas\EventManager\EventManager->triggerListeners() #2 /var/www/vhosts/tplibrary.org/local-history/vendor/laminas/laminas-mvc/src/Application.php(304): Laminas\EventManager\EventManager->triggerEventUntil() #3 /var/www/vhosts/tplibrary.org/local-history/index.php(21): Laminas\Mvc\Application->run() #4 {main}
OK, great: POST request exceeded maximum size is the actual error we’re working with here. You could undo that change you made to show the error now, if you like.
That error happens when you’re trying to upload something that exceeds the size limit set by your server. This is a php.ini setting, called post_max_size. If you click the “System information” link in the footer of any admin page, the page that takes you too will list, among other things, this maximum size, as “POST Size Limit”.
If it’s happening with any kind of file you try, I’d guess that the limit is set uncommonly low. Usually it’s in the tens of megabytes even on the low side.