[BUG] Chore Userfield breaks editing/adding Chores
nowjon opened this issue · 3 comments
nowjon commented
Is there an existing issue for this?
- I have searched the existing issues
Current Behavior
If you add any userfield with the Entity=chores, it will break the ability to edit/add chores
The below error is what is produced:
Error source:
/config/data/viewcache/310b22a807da34b33289c5d843ec258f.php:37
Error message:
Undefined constant Grocy\Services\UserfieldsService::USERFIELD_TYPE_INTEGRAL_NUMBER (View: /app/www/views/components/userfieldsform.blade.php) (View: /app/www/views/components/userfieldsform.blade.php)
Stack trace:
#0 /app/www/packages/illuminate/view/Engines/PhpEngine.php(60): Illuminate\View\Engines\CompilerEngine->handleViewException()
#1 /app/www/packages/illuminate/view/Engines/CompilerEngine.php(72): Illuminate\View\Engines\PhpEngine->evaluatePath()
#2 /app/www/packages/illuminate/view/View.php(195): Illuminate\View\Engines\CompilerEngine->get()
#3 /app/www/packages/illuminate/view/View.php(178): Illuminate\View\View->getContents()
#4 /app/www/packages/illuminate/view/View.php(147): Illuminate\View\View->renderContents()
#5 /app/www/packages/berrnd/slim-blade-view/src/Blade.php(173): Illuminate\View\View->render()
#6 /app/www/packages/berrnd/slim-blade-view/src/Blade.php(65): Slim\Views\Blade->fetch()
#7 /app/www/controllers/BaseController.php(186): Slim\Views\Blade->render()
#8 /app/www/controllers/BaseController.php(209): Grocy\Controllers\BaseController->render()
#9 /app/www/controllers/ChoresController.php(31): Grocy\Controllers\BaseController->renderPage()
#10 /app/www/packages/slim/slim/Slim/Handlers/Strategies/RequestResponse.php(38): Grocy\Controllers\ChoresController->ChoreEditForm()
#11 /app/www/packages/slim/slim/Slim/Routing/Route.php(358): Slim\Handlers\Strategies\RequestResponse->__invoke()
#12 /app/www/packages/slim/slim/Slim/MiddlewareDispatcher.php(65): Slim\Routing\Route->handle()
#13 /app/www/packages/slim/slim/Slim/MiddlewareDispatcher.php(65): Slim\MiddlewareDispatcher->handle()
#14 /app/www/packages/slim/slim/Slim/Routing/Route.php(315): Slim\MiddlewareDispatcher->handle()
#15 /app/www/packages/slim/slim/Slim/Routing/RouteRunner.php(68): Slim\Routing\Route->run()
#16 /app/www/middleware/LocaleMiddleware.php(16): Slim\Routing\RouteRunner->handle()
#17 /app/www/packages/slim/slim/Slim/MiddlewareDispatcher.php(269): Grocy\Middleware\LocaleMiddleware->__invoke()
#18 /app/www/middleware/AuthMiddleware.php(77): Psr\Http\Server\RequestHandlerInterface@anonymous->handle()
#19 /app/www/packages/slim/slim/Slim/MiddlewareDispatcher.php(269): Grocy\Middleware\AuthMiddleware->__invoke()
#20 /app/www/packages/slim/slim/Slim/Middleware/RoutingMiddleware.php(45): Psr\Http\Server\RequestHandlerInterface@anonymous->handle()
#21 /app/www/packages/slim/slim/Slim/MiddlewareDispatcher.php(121): Slim\Middleware\RoutingMiddleware->process()
#22 /app/www/packages/slim/slim/Slim/Middleware/ErrorMiddleware.php(76): Psr\Http\Server\RequestHandlerInterface@anonymous->handle()
#23 /app/www/packages/slim/slim/Slim/MiddlewareDispatcher.php(121): Slim\Middleware\ErrorMiddleware->process()
#24 /app/www/middleware/CorsMiddleware.php(27): Psr\Http\Server\RequestHandlerInterface@anonymous->handle()
#25 /app/www/packages/slim/slim/Slim/MiddlewareDispatcher.php(269): Grocy\Middleware\CorsMiddleware->__invoke()
#26 /app/www/packages/slim/slim/Slim/MiddlewareDispatcher.php(65): Psr\Http\Server\RequestHandlerInterface@anonymous->handle()
#27 /app/www/packages/slim/slim/Slim/App.php(199): Slim\MiddlewareDispatcher->handle()
#28 /app/www/packages/slim/slim/Slim/App.php(183): Slim\App->handle()
#29 /app/www/app.php(112): Slim\App->run()
#30 /app/www/public/index.php(45): require_once('...')
#31 {main}
System info:
{
"grocy_version": {
"Version": "4.0.3",
"ReleaseDate": "2023-09-02"
},
"php_version": "8.2.10",
"sqlite_version": "3.41.2",
"os": "Linux 6.1.49-Unraid #1 SMP PREEMPT_DYNAMIC Wed Aug 30 09:42:35 PDT 2023 x86_64",
"client": "Mozilla\/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit\/537.36 (KHTML, like Gecko) Chrome\/117.0.0.0 Safari\/537.36"
}
Expected Behavior
The userfield would show up in the chores edit screens
Steps To Reproduce
- Navigate to Manage Master Data > Userfields or Manage Master Data > Chores and hit "Configure userfields"
- Add any type of userfield for the Entity of Chores
- Attempt to add or edit any chore to see the error
Environment
- OS: Unraid 6.12.4
- How docker service was installed: Built-in, Docker was installed from the Community Applications catalog.
CPU architecture
x86-64
Docker creation
docker run
-d
--name='grocy'
--net='bestitpros'
-e TZ="America/Los_Angeles"
-e HOST_OS="Unraid"
-e HOST_HOSTNAME="Docile"
-e HOST_CONTAINERNAME="grocy"
-e 'PUID'='99'
-e 'PGID'='100'
-e 'UMASK'='022'
-l net.unraid.docker.managed=dockerman
-l net.unraid.docker.webui='http://[IP]:[PORT:80]'
-l net.unraid.docker.icon='https://raw.githubusercontent.com/linuxserver/docker-templates/master/linuxserver.io/img/grocy-logo.png'
-p '9283:80/tcp'
-v '/mnt/user/appdata/grocy':'/config':'rw' 'lscr.io/linuxserver/grocy'
7f7a5efba8e2fcc332e8760f05b1dc21b1b107723cd37b76c2ddcfbaec2eb82f
Container logs
root@Docile:~# docker logs grocy
[migrations] started
[migrations] 01-nginx-site-confs-default: skipped
[migrations] 02-default-location: skipped
[migrations] done
───────────────────────────────────────
██╗ ███████╗██╗ ██████╗
██║ ██╔════╝██║██╔═══██╗
██║ ███████╗██║██║ ██║
██║ ╚════██║██║██║ ██║
███████╗███████║██║╚██████╔╝
╚══════╝╚══════╝╚═╝ ╚═════╝
Brought to you by linuxserver.io
───────────────────────────────────────
To support LSIO projects visit:
https://www.linuxserver.io/donate/
───────────────────────────────────────
GID/UID
───────────────────────────────────────
User UID: 99
User GID: 100
───────────────────────────────────────
using keys found in /config/keys
**** The following active confs have different version dates than the samples that are shipped. ****
**** This may be due to user customization or an update to the samples. ****
**** You should compare the following files to the samples in the same folder and update them. ****
**** Use the link at the top of the file to view the changelog. ****
┌────────────┬────────────┬────────────────────────────────────────────────────────────────────────┐
│ old date │ new date │ path │
├────────────┼────────────┼────────────────────────────────────────────────────────────────────────┤
│ │ 2023-04-13 │ /config/nginx/nginx.conf │
│ 2022-08-20 │ 2023-08-13 │ /config/nginx/ssl.conf │
│ │ 2023-04-13 │ /config/nginx/site-confs/default.conf │
└────────────┴────────────┴────────────────────────────────────────────────────────────────────────┘
[custom-init] No custom files found, skipping...
[ls.io-init] done.
github-actions commented
Thanks for opening your first issue here! Be sure to follow the relevant issue templates, or risk having this issue marked as invalid.
thespad commented
This should be reported to the upstream project
berrnd commented
This should be reported to the upstream project
No need for that, since it's simply and once again about a not emptied data/viewcache
directory during the update - see also grocy/grocy#2350 and README.