Listing media in a subpage not updating when media changes


In a modular page, I am including a url list of the media of a subpage _replay containing mp3s. I want the mp3s to be updated with ftp without touching the md file in the folder.

The problem is adding a file, or modifying a filename doesn’t update the list of urls. And I need to edit the markdown file in order to update the list.

My replay folder has a markdown file with this content:

title: Replay
cache_enable: false
never_cache_twig: true

# test

I have tested to include the file listing in the modular page with two methods: using a specific twig template or a direct loop (my listing is going in a javascript var sonicReplay):

{% for module in page.collection() %}
  {% if module.slug == '_replay' %}
    {% set content_html = module.content|e('js') %}
      contentReplay += '{{content_html}}'
    {% endif %}
{% endfor %}

with this twig template:

{% for file in|sort %}
{% endfor %}

or the direct loop in the modular page

{% for file in pages.find('/2023/_replay').media.all|sort %}
  contentReplay += '{{file.url|e('js')}}';
{% endfor %}

I have tried different cache methods : normal, folder or file, and activated the option “add timestamp to media files”

Do you have an idea of what I can try?

For info:

Using the system configuration media->enable timestamp on media and caching -> cache method : all files timestamp seems to work on the hosting environment, even though it was not working in my development environment (osx 10.15).