From d16005077fd88d00def3e3f1e0238923a5a67faf Mon Sep 17 00:00:00 2001 From: ReenigneArcher <42013603+ReenigneArcher@users.noreply.github.com> Date: Sun, 26 Jul 2026 22:33:49 -0400 Subject: [PATCH] fix: gh-pages asset path Update the gh-pages template to use the correct jQuery SRI hash and make the dashboard script path relative to the site base URL instead of hardcoding `/dashboard`. Add a unit test to prevent the hardcoded path from returning. --- gh-pages-template/index.html | 4 ++-- tests/unit/test_templates.py | 13 +++++++++++++ 2 files changed, 15 insertions(+), 2 deletions(-) create mode 100644 tests/unit/test_templates.py diff --git a/gh-pages-template/index.html b/gh-pages-template/index.html index 69fccbf49..d048bf86e 100644 --- a/gh-pages-template/index.html +++ b/gh-pages-template/index.html @@ -16,7 +16,7 @@ - href: "https://cdnjs.cloudflare.com/ajax/libs/plotly.js/3.1.1/plotly.min.js" sri: "sha512-QaIUFweb9pyRnQZEYIujSDTHndibSwqsTSb69aedsfAAUpJRUE5yyYfaNAJIbTDuNECyHR/Cc0N7lQJrp0IEpA==" - href: "https://cdnjs.cloudflare.com/ajax/libs/jquery/4.0.0/jquery.min.js" - sri: "sha512-YuCuk5nNmVIUfKROKeV3fpZZ5Vt9vsnq8nExr5JwEJc2r1YDVmDfujcq373eHIzjqdxwCzoKpxngIaAdRUyg3A==" + sri: "sha512-8LENNbXmzI/Gbj+OwXmqR6V4QaUAw0/porPzy1+dQoJqC0JPHedWoe0DDOTL2uHA5XXJyIsPtiMHH86pVlay6A==" - href: https://cdn.datatables.net/2.3.7/js/dataTables.min.js - href: https://cdn.datatables.net/2.3.7/js/dataTables.bootstrap5.min.js - href: https://cdn.datatables.net/autofill/2.7.1/js/dataTables.autoFill.min.js @@ -29,7 +29,7 @@ - href: https://cdn.datatables.net/buttons/3.2.6/js/buttons.html5.min.js js: - - /dashboard/assets/js/dashboard.js + - /assets/js/dashboard.js ---