I’ve made a PR to Ansible regarding the rather new Foreman inventory plugin. This plugin gave us some serious headache with chopped parameters and much more.
Because of my limited in-depth knowledge of Ansible the code currently is more a workaround than a clean solution. So please feel free to commit:
@ekohl: Thank again for your hints in this case, some of them are included in this work.