KatjaGlassConsulting / ApprovalBundle

A Kimai Plugin to manage weekly approval workflow
MIT License
11 stars 14 forks source link

Updates #29

Closed KatjaGlassConsulting closed 9 months ago

KatjaGlassConsulting commented 9 months ago

The latest PR #28 caused issues that kimai no longer starts as the routes are no longer found. For this the update is gone into feature/v2_updates branch. @kevinpapst, could you please check? In my windows installation when I do the refresh I get:

[2024-01-06 08:27:40] [request] CRITICAL: Uncaught PHP Exception Twig\Error\RuntimeError: "An exception has been thrown during the rendering of a template ("Unable to generate a URL for the named route "approval_bundle_report" as such route does not exist.")." at C:\temp\git\kimai_2_5\vendor\kevinpapst\tabler-bundle\templates\includes\menu.html.twig line 17 {"exception":"[object] (Twig\Error\RuntimeError(code: 0): An exception has been thrown during the rendering of a template (\"Unable to generate a URL for the named route \"approval_bundle_report\" as such route does not exist.\"). at C:\temp\git\kimai_2_5\vendor\kevinpapst\tabler-bundle\templates\includes\menu.html.twig:17)\n[previous exception] [object] (Symfony\Component\Routing\Exception\RouteNotFoundException(code: 0): Unable to generate a URL for the named route \"approval_bundle_report\" as such route does not exist. at C:\temp\git\kimai_2_5\vendor\symfony\routing\Generator\CompiledUrlGenerator.php:50)"} []

I guess changing the includes caused this issue.

kevinpapst commented 9 months ago

The bundle and this route in special work entirely normal for me, I rarely push untested šŸ˜

Did you try to rm -rf var/cache/* (sorry, don't know what the Windows equivalent is)? The routes cache need to be regenerated and sometimes Symfony fails doing that.

KatjaGlassConsulting commented 9 months ago

I run the reload, cache clear, removed the cache folder content completely and still got this error. I am using kimai 2.5.

KatjaGlassConsulting commented 9 months ago

oh, I installed 2.8 - is seems something changed between 2.5 and 2.8 causing this issue no longer to appear. So I will set the approval compatibility to 2.8 and merge this to the main branch (wait till monday ;) ).

kevinpapst commented 9 months ago

Ah, yeah maybe. Symfony is currently pushing all their deprecations for the next major release 7 and I had to do some adjustments in core for that as well. As my dev system is always on the latest version I didn't see this error. Thanks for proper testing šŸ˜