BookStackApp / BookStack

A platform to create documentation/wiki content built with PHP & Laravel
https://www.bookstackapp.com/
MIT License
15.43k stars 1.94k forks source link

Bookstack Rendering Issues: Unresolved Variables and Broken Links #5246

Closed dettmer-nh closed 1 month ago

dettmer-nh commented 1 month ago

Describe the Bug

As you can see on the screenshot, various Bookstack sections are no longer rendered correctly. You can only see various unresolved variables.

On the test instance, I was initially unable to open shelves. I ran all update commands again (even though the system was already up to date), but now I can't even render the login page.

On the production instance, I'm able to navigate, create and view pages but i get the same bug when trying to delete pages. Also all buttons and links on the unrendered page lead to invalid URLs with unresolved variables inside.

Unfortunately, this problem was not noticed during the first tests on 20 September (time of the update). Therefore, the productive environment has been running like this since then. I hope I can save all the new posts that have been created since then, somehow.

Steps to Reproduce

I am not aware of the exact steps, but this problem has occurred in two instances after updating from version 24.02.3 to the latest version. The required steps such as updating the PHP and Composer version were also executed.

Host system: Virtual machine with Ubuntu 20.04.6 LTS

Expected Behaviour

The site should render correctly.

Screenshots or Additional Context

prod_instance_delete prod_instance_invalidlink test_instance-login

Browser Details

Microsoft Edge Version 129.0.2792.79 (64-Bit) and also Firefox 128.3.0esr (64-Bit) both for Windows

Exact BookStack Version

v24.05.4

ssddanbrown commented 1 month ago

Hi @dettmer-nh, This could possible be related to permission and caches set/existing on your instance.

Before anything, ensure you have a backup of your instance (ideally a whole system snapshot/backup)

Can you have a go at resetting file permissions for your instance as per out guidance here: https://www.bookstackapp.com/docs/admin/filesystem-permissions/#example-permissions-approach

Then, try running the following from your BookStack install directory, reporting back any errors that may show:

php artisan optimize:clear
php artisan view:clear
php artisan route:clear

Then also restart apache to ensure there's no web-server/php caching at that level:

sudo systemctl restart apache2
dettmer-nh commented 1 month ago

Hi @ssddanbrown,

Thank you so much for your help! I followed the steps you outlined, including resetting the file permissions and running the suggested commands. Fortunately, no errors occurred, and everything seems to be functioning properly again.

I really appreciate your guidance and quick response. Thanks again for the support!