Description
When exporting to L5X, all <Program> elements are written with no Name attribute. Routines nested within them export their names correctly, but the parent program element does not.
Steps to Reproduce
from acd.api import ExportL5x
import xml.etree.ElementTree as ET
exporter = ExportL5x("project.ACD", "build/")
root = ET.fromstring(exporter.project.to_xml())
for prog in root.find("Controller").find("Programs"):
print(prog.get("Name")) # prints None for every program
Expected Behavior
Each <Program> element should carry a Name attribute matching the program name in the ACD project:
<Program Name="MainProgram" ...>
<Routines>
<Routine Name="Main" Type="RLL">
Observed Behavior
<Program>
<Routines>
<Routine Name="Main" Type="RLL">
The program name is available in the Python object model (it is used to populate routine names correctly), so this appears to be an omission in the XML serialization step.
Description
When exporting to L5X, all
<Program>elements are written with noNameattribute. Routines nested within them export their names correctly, but the parent program element does not.Steps to Reproduce
Expected Behavior
Each
<Program>element should carry aNameattribute matching the program name in the ACD project:Observed Behavior
The program name is available in the Python object model (it is used to populate routine names correctly), so this appears to be an omission in the XML serialization step.