Problem:
The state import routine queries a proxy for all available environments, which when read from git-branches could contain non-ascii-characters (which are perfectly valid in git, and also salt understands these).
These environment names are then used to craft internal URLs and fail the ASCII checks, which in turn aborts the whole process. (Which is understandable, but very inconvenient)
The presence of a single non-conformant git-branch thus prevents any state imports or env updates until the incriminating branch is renamed/deleted.
Expected outcome:
States for valid environments can still be imported, invalid env names will be ignored (but maybe reported on the import page.)
Foreman and Proxy versions:
3.10
Foreman and Proxy plugin versions:
3.10
Distribution and version:
AlmaLinux 9.4
Other relevant data:
production.log
2024-06-18T08:50:39 [I|app|1d1d4223] Backtrace for 'ProxyAPI operation FAILED' error (ProxyAPI::ProxyException): ERF12-4701 [ProxyAPI::ProxyException]: Unable to fetch Salt states list ([URI::InvalidURIError]: URI must be ascii only "https://myforeman:9090/salt/environments/branch-f\u00FCr-support") for proxy https://myforeman:9090/salt/
1d1d4223 | /usr/share/gems/gems/foreman_salt-16.0.2/app/lib/proxy_api/salt.rb:57:in `rescue in states_list'
1d1d4223 | /usr/share/gems/gems/foreman_salt-16.0.2/app/lib/proxy_api/salt.rb:48:in `states_list'
1d1d4223 | /usr/share/gems/gems/foreman_salt-16.0.2/app/controllers/foreman_salt/state_importer.rb:16:in `fetch_states_from_proxy'
1d1d4223 | /usr/share/gems/gems/foreman_salt-16.0.2/app/controllers/foreman_salt/salt_modules_controller.rb:61:in `import'
1d1d4223 | /usr/share/gems/gems/actionpack-6.1.7.7/lib/action_controller/metal/basic_implicit_render.rb:6:in `send_action'