Why are spaces in the file path rendered with %2520 instead of %20? I have a custom content entity (service) with a 'file' field defined by:
$fields['file'] = BaseFieldDefinition::create('file')
  -&gt;setLabel(t('File'))
  -&gt;setSettings([
    'file_extensions' =&gt; 'pdf',
    'file_directory' =&gt; 'sel',
    'description_field' =&gt; TRUE,
  ])
  -&gt;setDisplayOptions('view', [
    'type' =&gt; 'file',
  ])
  -&gt;setDisplayOptions('form', [
    'type' =&gt; 'file',
  ])
  -&gt;setDisplayConfigurable('form', TRUE)
  -&gt;setDisplayConfigurable('view', TRUE);

A classic CRUD form allows me to create a service:

Lets say I upload a file with spaces in its name. As you can see if I hover the file name in the form, the link appears to be http://jdp8:8888/sites/default/files/sel/name%20with%20spaces.pdfwith space replaced by %20 and the link works:

So far, so good...
I have a View to display this content entity:

The 'file' field is rendered as a '•' with a link to the file that allows to open the content of the file (a .pdf file) in another window.
When the file name contains spaces, it is rendered as http://jdp8:8888/sites/default/files/sel/name%2520with%2520spaces.pdf with %2520instead of %20.
And of course the links leads to a The requested page was not found error.
I have recently updated Drupal to 8.9.13.
Before I was running Drupal 8.9.1 and I am pretty sure that it was working.
Any idea on what is going wrong? Is it Drupal? Is it Views?
As I suspect Views (everywhere else, it works), here is the way the file field is handled in the view:
I found a kind of workaround: I wrote {{ file__target_id|replace({'%20': &quot; &quot;}) }} in the definition of 'file' field in the view.