I am trying to build an XML file in which my main node has some attributes:
<cbnp-message:cbnp-message xmlns:cbnp-message="some_value" xmlns="some_value2">
I am trying to achieve that using Python3 and lxml library and so far I managed to set xmlns parameter for some_value2. What I can't do I to set cnbp-message:cnbp-message thing (sorry for my lack of proper naming: I am not working with XMLs on daily basis).
What is tricky here and prevents me from hard-coding such informations before creating XML file is that ending tag of aforementioned XML has to end with
</cbnp-message:cnbp-message>
I would appreciate all ideas and suggestion how to tackle such task.
I already tried creating a node with cnbp-message:cbnp-message name, it doesn't work though (raises ValueError: Invalid tag name exception)