I just realized that one script has a double / in the url:
<script src="https://DOMAIN/wp-content/plugins/amplitude//scripts/amplitude-configure.js?ver=6.5.5" id="aampli_plg_scr_configure-js"></script>
In amplitude.php:148, plugin_dir_url(…) includes trailing slash ??
]]>