Opened 8 years ago
Last modified 8 years ago
#4244 new defect
Redeclared models "loose" their connectors
Reported by: | Owned by: | Adeel Asghar | |
---|---|---|---|
Priority: | high | Milestone: | Future |
Component: | OMEdit | Version: | |
Keywords: | Cc: | a.haumer@… |
Description
Please consider the model attached to this ticket. Each of the second connector of ComponentA
and ComponentB
is created through extends of a single connector class BaseConnectorA
and BaseConnectorB
, respectively, and adding an additional connector.
In the example model ExampleAB
a base class is used. componentA
and componentB}} are redeclared from the base class model by {{{ComponentA
and ComponentB
, respectively. In the example modelel ExampleAB
the two extended connectors do not appear. When checking the model OpenModelica complains:
Scripting Error Unable to find component componentA.port_b while parsing connection {componentA.port_b,componentB.port_a, ""}.
However, the model simulates without problems. Nevertheless this kind of configurations seems to be problematic, as a more complex variant of this applications refuses to compile in OpenModelica... However, the two "missing" connectors are shown in the result variable browser.
Attachments (1)
Change History (3)
by , 8 years ago
Attachment: | RedeclarationComponents.mo added |
---|
comment:1 by , 8 years ago
The described issue refers to
OMEdit 1.12.0~dev-154-g354a8d1 Connected to OpenModelica 1.12.0~dev-321-g9addb54 Linux Mint 18.1 64bit
comment:2 by , 8 years ago
This mostly happens because OMEdit considers classes without the component/extends/type modifiers that are given in the top model.
We are working on a new front-end to handle redeclares better and also provide OMEdit with a component instance that can be queried to get the correct information.
Example demonstrating the "lost" connetors