Can you explain specifically what âYou are using a different field format than bettercomments.yaml doesâ means?
I havenât changed any fields. I made one simple edit to bettercomments.yaml which crashed the site. I then re-uploaded the previous version that was working before it got edited, but the site has remained crashed. I deleted everything inside the /cache/ directory which didnât fix anything.
What continues to make no sense is that the first line of bettercomments.yaml is currently
How will Grav detect if a plugin is disabled/enabled if it canât read its config file to begin with?
so I donât understand why it continues to give that error at line 11.
Site https://www.wittmantailwind.com/ is still showing the same error, which seems to indicate that the site has not been completely reversed to a previous working state.
I donât have a backup of a previous version. The only edit I made today was to the bettercomments.yaml file and it was the addition of literally only three lines near the top of it. That instantly caused the error so I restored the file to the previous version. Thatâs it and now Iâve spent the next six hours paying the price for that one measly edit that evidently rewrote some other config files. Unbelievable.
I just noticed that the pages inside the site are still working. Itâs the homepage thatâs broken. And the same thing goes for the admin. All the admin pages work except for the adminâs homepage.
Hereâs the most recent error in /logs/grav.log. In fact, this was the error that started it all and no other error has been logged since this.
[2024-01-14 16:20:15] grav.CRITICAL: Template âforms/fields//.html.twigâ is not defined in âpartials/bettercomments.html.twigâ at line 74. - Trace: #0 /home/customer/www/wittmantailwind.com/public_html/system/src/Grav/Common/Service/OutputServiceProvider.php(36): Grav\Common\Twig\Twig->processSite(âhtmlâ)
[2024-01-14 16:20:15] grav.CRITICAL: Template âforms/fields//.html.twigâ is not defined in âpartials/bettercomments.html.twigâ at line 74. - Trace: #0 /home/customer/www/wittmantailwind.com/public_html/system/src/Grav/Common/Service/OutputServiceProvider.php(36): Grav\Common\Twig\Twig->processSite(âhtmlâ)
The only reason I can think of is that this error occurs when your field definition has an empty type. If youâre editing a live site, someone might have accessed the site at the moment you havenât yet been able to add the field type.
The solution: I changed the version of PHP running on the server.
It was running 7.4.33. As soon as I downgraded it to 7.3.33 everything worked. Thatâs all it took. Iâve since restored it back to 7.4.33 and itâs still working.
Unfortunately I donât know how to do that. The only way I know how to backup the site is to download the /user/ directory, but itâs over 100mb which isnât very feasible. Thatâs why I always save a copy of the file Iâm editing so I can reupload it in case the edits crash the site. Still learning here.
Itâs been 24 hours and the honeypot code for bettercomments has not let a single spam message get through. 200+ spams a day down to zero so Iâd say itâs working.