ROCKFlows / FromMLWFConfigurationToBPMN

This project aims (i) to record workflows (meta and instance) defined in BPMN (XML parking) extended by a small constraint language, (ii) to merge and verify the knowledge contained and (iii) to transform them into a system of constraints (Feature model) in order to facilitate the selection of a workflow adapted to a new problem.
GNU General Public License v3.0
1 stars 1 forks source link

[BUG]2020-07-15 11:19:58 FATAL Generate:80 - java.lang.RuntimeException: Namespace for prefix 'ext' has not been declared. #127

Open MireilleBF opened 4 years ago

MireilleBF commented 4 years ago

Describe the bug try to generate an instance of BasicMetaWorkflow

I don't understand the problem. The resulting file is empty

2020-07-15 11:19:58 WARN XMLManager:488 - Global annotation node not found. 2020-07-15 11:19:58 FATAL Generate:79 - Can't instantiate the WorkFlow. 2020-07-15 11:19:58 FATAL Generate:80 - java.lang.RuntimeException: Namespace for prefix 'ext' has not been declared.

To Reproduce String metaWFPATH = "../BPMN-Models/BasicMetaWF.bpmn2"; String outputWFPATH = "../BPMN-Models/instance.bpmn2"; File fin = new File(metaWFPATH); File fout = new File(outputWFPATH); assertTrue(fin.exists()); //FIX assertTrue(fout.exists()); com.ml2wf.App.main(new String[] {"generate", "-i ", metaWFPATH, "-o ",outputWFPATH, "-v","7"});

Expected behavior A clear and concise description of my mistake :-)

NicolasLacroix commented 4 years ago

Can you join the implied XML file ? I think that this is due to a bad XML definition. Does your XML file has a header like this one :

<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- origin at X=0.0 Y=0.0 -->
<bpmn2:definitions exporter="org.eclipse.bpmn2.modeler.core" exporterVersion="1.5.1.Final-v20190425-2005-B1" id="Definitions_1" targetNamespace="http://org.eclipse.bpmn2/default/process" xmlns:bpmn2="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:ext="http://org.eclipse.bpmn2/ext" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
MireilleBF commented 4 years ago

BasicMetaWF.bpmn2.zip

here it is

NicolasLacroix commented 4 years ago

Adding : xmlns:ext="http://org.eclipse.bpmn2/ext" in the header seems to fix the problem.

updated file : BasicMetaWF.zip