Just tested this on v4 and {% import 'site/macros' as macros %} with a partials/site/macros.htm works fine, so the feature itself hasn’t been removed or changed.
A few things to check on your end:
Clear the Twig cache. A PHP version change (which Herd will have done) can leave stale compiled templates that fail silently. Run php artisan cache:clear and delete the contents of storage/cms/twig/.
Check storage/logs/laravel.log for the actual error. “Not working” could be the import failing to find the partial, or the macro itself throwing on a stricter PHP version. The log will tell you which.
Confirm the active theme. If you’re using site definitions, make sure the site is pointing at the theme that actually contains partials/site/macros.htm.
My guess is #1, Herd jumped you to a newer PHP and the old compiled cache is poisoned. Let us know what the log says if clearing doesn’t fix it.
yes already tried, cleared cache. config and view but it does not fix the exception
in the /logs/system.log i see the exception
[2026-05-24 11:34:07] local.ERROR: InvalidArgumentException: View [site/macros] not found. in /Users/christophevidal/Sites/oc-christophevidal/vendor/laravel/framework/src/Illuminate/View/FileViewFinder.php:137
Stack trace:
#0 /Users/christophevidal/Sites/oc-christophevidal/vendor/laravel/framework/src/Illuminate/View/FileViewFinder.php(79): Illuminate\View\FileViewFinder->findInPaths('site/macros', Array)
yes, the correct theme is applied to the site browsed.
but it could be the problem, maybe twig is thinking to be in the main default site when i’m in a sub site.