{"action":"created","issue":{"url":"https://api.github.com/repos/camunda/camunda-modeler/issues/130","repository_url":"https://api.github.com/repos/camunda/camunda-modeler","labels_url":"https://api.github.com/repos/camunda/camunda-modeler/issues/130/labels{/name}","comments_url":"https://api.github.com/repos/camunda/camunda-modeler/issues/130/comments","events_url":"https://api.github.com/repos/camunda/camunda-modeler/issues/130/events","html_url":"https://github.com/camunda/camunda-modeler/issues/130","id":130946793,"number":130,"title":"Export BPMN diagrams with nested namespaces","user":{"login":"nikku","id":58601,"avatar_url":"https://avatars.githubusercontent.com/u/58601?v=3","gravatar_id":"","url":"https://api.github.com/users/nikku","html_url":"https://github.com/nikku","followers_url":"https://api.github.com/users/nikku/followers","following_url":"https://api.github.com/users/nikku/following{/other_user}","gists_url":"https://api.github.com/users/nikku/gists{/gist_id}","starred_url":"https://api.github.com/users/nikku/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nikku/subscriptions","organizations_url":"https://api.github.com/users/nikku/orgs","repos_url":"https://api.github.com/users/nikku/repos","events_url":"https://api.github.com/users/nikku/events{/privacy}","received_events_url":"https://api.github.com/users/nikku/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/camunda/camunda-modeler/labels/bug","name":"bug","color":"fc2929"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2016-02-03T08:07:09Z","updated_at":"2016-02-03T08:14:31Z","closed_at":null,"body":"The following diagram can be imported but will not be correctly exported:\r\n\r\n```xml\r\n<?xml version=\"1.0\" encoding=\"UTF-8\"?>\r\n<bpmn:definitions xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xmlns:bpmn=\"http://www.omg.org/spec/BPMN/20100524/MODEL\" xmlns:bpmndi=\"http://www.omg.org/spec/BPMN/20100524/DI\" xmlns:dc=\"http://www.omg.org/spec/DD/20100524/DC\" xmlns:di=\"http://www.omg.org/spec/DD/20100524/DI\" xmlns:foo=\"http://foo\" id=\"Definitions_1\" targetNamespace=\"http://bpmn.io/schema/bpmn\">\r\n  <bpmn:process id=\"Process\" isExecutable=\"false\">\r\n    <bpmn:task id=\"Task\">\r\n      <bpmn:extensionElements>\r\n        <foo:config>\r\n          <Entry key=\"A\" value=\"B\" />\r\n          <Nested>\r\n            <Entry key=\"A\" value=\"B\" />\r\n          </Nested>\r\n        </foo:config>\r\n      </bpmn:extensionElements>\r\n    </bpmn:task>\r\n  </bpmn:process>\r\n  <bpmndi:BPMNDiagram id=\"BPMNDiagram_1\">\r\n    <bpmndi:BPMNPlane id=\"BPMNPlane_1\" bpmnElement=\"Process\">\r\n      <bpmndi:BPMNShape id=\"Task_di\" bpmnElement=\"Task\">\r\n        <dc:Bounds x=\"276\" y=\"80\" width=\"100\" height=\"80\" />\r\n      </bpmndi:BPMNShape>\r\n    </bpmndi:BPMNPlane>\r\n  </bpmndi:BPMNDiagram>\r\n</bpmn:definitions>\r\n```\r\n\r\nThe problem is that the BPMN export does not support non-namespace nested elements yet:\r\n\r\n```xml\r\n<foo:config>\r\n  <Entry key=\"A\" value=\"B\" />\r\n  <Nested>\r\n     <Entry key=\"A\" value=\"B\" />\r\n  </Nested>\r\n</foo:config>\r\n```\r\n\r\nWhen exporting it will explode with\r\n\r\n```plain\r\n Error: no namespace uri given for prefix <undefined>\r\n      at ElementSerializer.logNamespaceUsed (.../bpmn-moddle/node_modules/moddle-xml/lib/writer.js:460:11)\r\n      at ElementSerializer.nsTagName (.../bpmn-moddle/node_modules/moddle-xml/lib/writer.js:212:26)\r\n      at ElementSerializer.build (.../bpmn-moddle/node_modules/moddle-xml/lib/writer.js:194:20)\r\n      at .../bpmn-moddle/node_modules/moddle-xml/lib/writer.js:272:47\r\n```"},"comment":{"url":"https://api.github.com/repos/camunda/camunda-modeler/issues/comments/179081555","html_url":"https://github.com/camunda/camunda-modeler/issues/130#issuecomment-179081555","issue_url":"https://api.github.com/repos/camunda/camunda-modeler/issues/130","id":179081555,"user":{"login":"nikku","id":58601,"avatar_url":"https://avatars.githubusercontent.com/u/58601?v=3","gravatar_id":"","url":"https://api.github.com/users/nikku","html_url":"https://github.com/nikku","followers_url":"https://api.github.com/users/nikku/followers","following_url":"https://api.github.com/users/nikku/following{/other_user}","gists_url":"https://api.github.com/users/nikku/gists{/gist_id}","starred_url":"https://api.github.com/users/nikku/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nikku/subscriptions","organizations_url":"https://api.github.com/users/nikku/orgs","repos_url":"https://api.github.com/users/nikku/repos","events_url":"https://api.github.com/users/nikku/events{/privacy}","received_events_url":"https://api.github.com/users/nikku/received_events","type":"User","site_admin":false},"created_at":"2016-02-03T08:14:31Z","updated_at":"2016-02-03T08:14:31Z","body":"Fixed by bpmn-io/bpmn-moddle#38."}}