Forum OpenACS Q&A: Issue with OpenACS Bootstrap 5 Theme Administration page

I've reproduced an issue with the 'OpenACS Bootstrap 5 Theme' Administration page that causes the site styles to break upon server restart. This is happening with package version 5.10.1d2

Here are the steps to reproduce
1. Assuming your site is currently loading bootstrap via the CDN
2. Check you do not have a bootstrap folder in the directory packages/openacs-bootstrap5-theme/www/resources/
3. Visit the 'OpenACS Bootstrap 5 Theme' Administration page from the Site Wide Administration main page.
4. The page should report that you are loading bootstrap via the cdn.
5. Check your directory again packages/openacs-bootstrap5-theme/www/resources/
Notice now there is a bootstrap folder with an empty folder tree of bootstrap/bootstrap@5.2.0/dist/
6. Restart your OpenACS server instance

Due to the existence of that directory it now will attempt to load the styles and js for bootstrap locally when you have the following in your ThemeCSS

{-href urn:ad:css:bootstrap5 -media all -order 1}

The Administration page shouldn't be creating an empty folder tree and/or the check on startup to detect whether to use CDN or local should check for a non-empty directory path.

What is the reason of using this version? The version you have picked is d2 (development version 2, Aug last year), which was followed by d3 (Oct last year), d4 ... b1 (4 months ago) ... and now we are at b3 (using Bootstrap 5.3.2 which is still the most recent released version of Bootstrap). This is the version of the package is the one to be released in the forthcoming release of OpenACS.

On my machine, the current version works with the installation from CDN and also with the downloaded variant.

Some of the download sources are moving targets, they do not provide a stable structure along versions.

The site we encountered this on had done an early upgrade to 5.10 so it was behind in some package versions.

I upgraded to 5.10.1b3 and it does still create the folder bootstrap/bootstrap@5.3.2 by visiting the acs-admin/package/openacs-bootstrap5-theme/ page.

However since it no longer is creating the dist folder underneath that location the problem no longer occurs.

Thanks for the response.