Closed pmjobin closed 5 years ago
Please delete the file and recreate the run configuration. I think it would help.
Thanks for your help. I tried deleting the embedded .clion folder which contains the workspace.xml file and reopen the cmake file in order to reset every settings but to no avail. As soon as I add the OpenCD Run/Debug configuration (which is stored in workspace.xml), CLion complains it can no longer open the workspace anymore. It seems related to the xml attributes starting with elmot-ocd:*
because after erasing those manually from the xml file, I can open the workspace without the error message box popping up.
Thanks, PM
After some experiments I realized I hardly can fix that in my code. This issue is just a side effect of some my refactorings.
How to fix:
Hi,
I did try CLion 2018.3 and this issue seems to be back. I did drop the workspace file and the issue was still there. Each time I fix the project, it is broken at next CLion startup.
It seems that the "elmot" namespace definition is missing in workspace.xml file.
Something like following definition should appear in the configuration element:
xmlns:elmot-ocd="https://github.com/elmot/clion-embedded-arm"
Modifiying configuration node like this fix the project, but it is rewritten by CLion in the corrupted form.
<configuration xmlns:elmot-ocd="https://github.com/elmot/clion-embedded-arm" name="MyName.out" type="elmot.embedded.openocd.conf.type" factoryName="elmot.embedded.openocd.conf.factory" nameIsGenerated="true" ...
I think that something like following code in the writeExternal method from OpenOcdConfiguration should fix this.
element.addNamespaceDeclaration(NAMESPACE);
Let me know if you do something about this.
Thanks, Pierre
Expected Behavior
Actual Behavior
After having setup OpenOCD in the "Run/Debug Configurations" dialog and closing the project, opening the project again in CLion gives the following error message:
Steps to Reproduce the Problem
Here is the faulty line in the workspace.xml file as pointed out by the error message:
<configuration name="NucleoH7.elf" type="elmot.embedded.openocd.conf.type" factoryName="elmot.embedded.openocd.conf.factory" PASS_PARENT_ENVS_2="true" PROJECT_NAME="NucleoH7" TARGET_NAME="NucleoH7.elf" CONFIG_NAME="Debug" RUN_TARGET_PROJECT_NAME="NucleoH7" RUN_TARGET_NAME="NucleoH7.elf" elmot-ocd:gdb-port="3333" elmot-ocd:telnet-port="4444" elmot-ocd:board-config="board/st_nucleo_h743zi.cfg" elmot-ocd:reset-type="INIT" elmot-ocd:download-type="ALWAYS">
Specifications