Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error in the right panel of tickets #18023

Open
2 tasks done
LucianaCabrera opened this issue Oct 7, 2024 · 6 comments
Open
2 tasks done

Error in the right panel of tickets #18023

LucianaCabrera opened this issue Oct 7, 2024 · 6 comments

Comments

@LucianaCabrera
Copy link

LucianaCabrera commented Oct 7, 2024

Code of Conduct

  • I agree to follow this project's Code of Conduct

Is there an existing issue for this?

  • I have searched the existing issues

Version

10.0.16

Bug description

Error in the right panel of tickets,
Whenever I move to another entity, the right ticket panel disappears and I get the following error:
Twig Error (Twig\Error\RuntimeError): "An exception was thrown during rendering of a template ('Empty inputs are not allowed')." in template "/var/www/glpi/templates/components/itilobject/fields_panel.html.twig" on line 216

Relevant log output

[``](url)

Screenshot_20241007_101344

I have cleared the rm-rf template cache inside the files/

I have run the command bin/console glpi:cache:clear but there were no changes

[2024-10-17 18:58:54] glpiphplog.CRITICAL: *** Twig Error (Twig\Error\RuntimeError): "An exception has been thrown during the rendering of a template ("Empty IN are not allowed")." in template "/var/www/html/glpi/templates/components/itilobject/fields_panel.html.twig" at line 209
Backtrace :
vendor/twig/twig/src/Template.php:367 Twig\Template->displayWithErrorHandling()
vendor/twig/twig/src/Template.php:379 Twig\Template->display()
vendor/twig/twig/src/TemplateWrapper.php:38 Twig\Template->render()
.../twig/twig/src/Extension/CoreExtension.php:1347 Twig\TemplateWrapper->render()
...tes/2e/2e1acab12523aa17a00f919c92637dc6.php:152 twig_include()
vendor/twig/twig/src/Template.php:394 __TwigTemplate_b00fc822dd5619998d19e5ea023413b4->doDisplay()
vendor/twig/twig/src/Template.php:367 Twig\Template->displayWithErrorHandling()
vendor/twig/twig/src/TemplateWrapper.php:45 Twig\Template->display()
src/Application/View/TemplateRenderer.php:184 Twig\TemplateWrapper->display()
src/Ticket.php:4433 Glpi\Application\View\TemplateRenderer->display()
src/CommonGLPI.php:680 Ticket->showForm()
ajax/common.tabs.php:120 CommonGLPI::displayStandardTab()
public/index.php:82 require()

root@PC-Luciana:/var/www/html/glpi/files/_log#

@LucianaCabrera
Copy link
Author

I have a database where this error that was mentioned some time ago is replicated in different versions, I cannot pass it through GitHub since it is a client database, could you contact me please?

@stonebuzz
Copy link
Contributor

Hi @LucianaCabrera

To address this, you can try resetting the entity caches by running the following SQL query:

UPDATE glpi_entities SET ancestors_cache = null, sons_cache = null;

This query clears potential cache issues that might be affecting entity-related data display.

Best regards

@LucianaCabrera
Copy link
Author

Perfect, it works, thanks ^^!

@stonebuzz
Copy link
Contributor

@cedric-anne

We need to add this SQL query when we run php bon/console cache:clear to be sure that MySQL "cache" is unset !

@trasher
Copy link
Contributor

trasher commented Oct 21, 2024

@cedric-anne

We need to add this SQL query when we run php bon/console cache:clear to be sure that MySQL "cache" is unset !

If we do that, we must handle all tables that uses a database cache, there are several other cases that would be affected.

trasher added a commit to trasher/glpi that referenced this issue Oct 22, 2024
@cedric-anne
Copy link
Member

@cedric-anne

We need to add this SQL query when we run php bon/console cache:clear to be sure that MySQL "cache" is unset !

Honestly, I think that cache in database should not exist. Also, I guess there is a bug behind this issue. If something is generating invalid data, or if something is not updating these fields correctly, then it should be fixed.

Clearing these values could indeed help, but, in a production environment, people should never have to clear the cache by themselves.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants