Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Inconsistent build behavior on some tests (gips.multilayeredinheritence) #146

Open
maxkratz opened this issue Apr 29, 2024 · 1 comment
Open
Labels
bug Something isn't working

Comments

@maxkratz
Copy link
Member

Sometimes (and I cannot find out under which circumstances), the GIPS builder creates invalid gips-model.xmi files for some of the tests and they fail.

Today, I investigated the issue a bit further and I found:

  • When one of the tests mentioned above fails, some of the generated source files differ. (I attached a diff of one of the broken projects with a successful build below.)
  • As a consequence, the generated ILP problem also differs. (This can be seen when activating the output of the LP file in the configuration.)
  • As far as I can see, the respective test in a broken project build can be fixed if gips-model.xmi gets overwritten by the same file taken from a successful build.

=> Something within GIPS generates non-deterministic broken gips-model.xmi files.


Total diff:

diff --recursive gips.multilayeredinheritencersinit gips.multilayeredinheritencersinit_broken 
diff --color --recursive gips.multilayeredinheritencersinit/bin/gips/multilayeredinheritencersinit/api/gips/gips-model.xmi gips.multilayeredinheritencersinit_broken/bin/gips/multilayeredinheritencersinit/api/gips/gips-model.xmi
4,5c4,5
<   <variables xmi:type="GipsIntermediate:Type" name="C" upperBound="1.0">
<     <type xmi:type="ecore:EClass" href="platform:/resource/gips.multilayeredinheritencemodel/model/Multilayeredinheritencemodel.ecore#//C"/>
---
>   <variables xmi:type="GipsIntermediate:Type" name="A" upperBound="1.0">
>     <type xmi:type="ecore:EClass" href="platform:/resource/gips.multilayeredinheritencemodel/model/Multilayeredinheritencemodel.ecore#//A"/>
10,11c10,11
<   <variables xmi:type="GipsIntermediate:Type" name="A" upperBound="1.0">
<     <type xmi:type="ecore:EClass" href="platform:/resource/gips.multilayeredinheritencemodel/model/Multilayeredinheritencemodel.ecore#//A"/>
---
>   <variables xmi:type="GipsIntermediate:Type" name="C" upperBound="1.0">
>     <type xmi:type="ecore:EClass" href="platform:/resource/gips.multilayeredinheritencemodel/model/Multilayeredinheritencemodel.ecore#//C"/>
13c13
<   <constraints xmi:type="GipsIntermediate:TypeConstraint" name="TypeConstraint0OnA" modelType="//@variables.3">
---
>   <constraints xmi:type="GipsIntermediate:TypeConstraint" name="TypeConstraint0OnA" modelType="//@variables.1">
28c28
<                     <value xmi:type="GipsIntermediate:ContextTypeValue" typeContext="//@variables.3"/>
---
>                     <value xmi:type="GipsIntermediate:ContextTypeValue" typeContext="//@variables.1"/>
33c33
<                     <value xmi:type="GipsIntermediate:ContextTypeFeatureValue" typeContext="//@variables.3">
---
>                     <value xmi:type="GipsIntermediate:ContextTypeFeatureValue" typeContext="//@variables.1">
89c89
<   <constraints xmi:type="GipsIntermediate:TypeConstraint" name="TypeConstraint2OnC" modelType="//@variables.1">
---
>   <constraints xmi:type="GipsIntermediate:TypeConstraint" name="TypeConstraint2OnC" modelType="//@variables.3">
104c104
<                     <value xmi:type="GipsIntermediate:ContextTypeValue" typeContext="//@variables.1"/>
---
>                     <value xmi:type="GipsIntermediate:ContextTypeValue" typeContext="//@variables.3"/>
109c109
<                     <value xmi:type="GipsIntermediate:ContextTypeFeatureValue" typeContext="//@variables.1">
---
>                     <value xmi:type="GipsIntermediate:ContextTypeFeatureValue" typeContext="//@variables.3">
Binary files gips.multilayeredinheritencersinit/bin/gips/multilayeredinheritencersinit/hipe/engine/actor/DispatchActor.class and gips.multilayeredinheritencersinit_broken/bin/gips/multilayeredinheritencersinit/hipe/engine/actor/DispatchActor.class differ
Binary files gips.multilayeredinheritencersinit/bin/gips/multilayeredinheritencersinit/hipe/engine/actor/NotificationActor.class and gips.multilayeredinheritencersinit_broken/bin/gips/multilayeredinheritencersinit/hipe/engine/actor/NotificationActor.class differ
diff --color --recursive gips.multilayeredinheritencersinit/src-gen/gips/multilayeredinheritencersinit/api/gips/gips-model.xmi gips.multilayeredinheritencersinit_broken/src-gen/gips/multilayeredinheritencersinit/api/gips/gips-model.xmi
4,5c4,5
<   <variables xmi:type="GipsIntermediate:Type" name="C" upperBound="1.0">
<     <type xmi:type="ecore:EClass" href="platform:/resource/gips.multilayeredinheritencemodel/model/Multilayeredinheritencemodel.ecore#//C"/>
---
>   <variables xmi:type="GipsIntermediate:Type" name="A" upperBound="1.0">
>     <type xmi:type="ecore:EClass" href="platform:/resource/gips.multilayeredinheritencemodel/model/Multilayeredinheritencemodel.ecore#//A"/>
10,11c10,11
<   <variables xmi:type="GipsIntermediate:Type" name="A" upperBound="1.0">
<     <type xmi:type="ecore:EClass" href="platform:/resource/gips.multilayeredinheritencemodel/model/Multilayeredinheritencemodel.ecore#//A"/>
---
>   <variables xmi:type="GipsIntermediate:Type" name="C" upperBound="1.0">
>     <type xmi:type="ecore:EClass" href="platform:/resource/gips.multilayeredinheritencemodel/model/Multilayeredinheritencemodel.ecore#//C"/>
13c13
<   <constraints xmi:type="GipsIntermediate:TypeConstraint" name="TypeConstraint0OnA" modelType="//@variables.3">
---
>   <constraints xmi:type="GipsIntermediate:TypeConstraint" name="TypeConstraint0OnA" modelType="//@variables.1">
28c28
<                     <value xmi:type="GipsIntermediate:ContextTypeValue" typeContext="//@variables.3"/>
---
>                     <value xmi:type="GipsIntermediate:ContextTypeValue" typeContext="//@variables.1"/>
33c33
<                     <value xmi:type="GipsIntermediate:ContextTypeFeatureValue" typeContext="//@variables.3">
---
>                     <value xmi:type="GipsIntermediate:ContextTypeFeatureValue" typeContext="//@variables.1">
89c89
<   <constraints xmi:type="GipsIntermediate:TypeConstraint" name="TypeConstraint2OnC" modelType="//@variables.1">
---
>   <constraints xmi:type="GipsIntermediate:TypeConstraint" name="TypeConstraint2OnC" modelType="//@variables.3">
104c104
<                     <value xmi:type="GipsIntermediate:ContextTypeValue" typeContext="//@variables.1"/>
---
>                     <value xmi:type="GipsIntermediate:ContextTypeValue" typeContext="//@variables.3"/>
109c109
<                     <value xmi:type="GipsIntermediate:ContextTypeFeatureValue" typeContext="//@variables.1">
---
>                     <value xmi:type="GipsIntermediate:ContextTypeFeatureValue" typeContext="//@variables.3">
diff --color --recursive gips.multilayeredinheritencersinit/src-gen/gips/multilayeredinheritencersinit/hipe/engine/actor/DispatchActor.java gips.multilayeredinheritencersinit_broken/src-gen/gips/multilayeredinheritencersinit/hipe/engine/actor/DispatchActor.java
66,75d65
< 		type2addConsumer.put(multilayeredinheritencemodel.MultilayeredinheritencemodelPackage.eINSTANCE.getC(), obj -> {
< 			multilayeredinheritencemodel.C _c = (multilayeredinheritencemodel.C) obj;
< 			incUtil.newMessage();
< 			name2actor.get("A_object").tell(new ObjectAdded<multilayeredinheritencemodel.A>(incUtil, _c), getSelf());
< 		});
< 		type2addConsumer.put(multilayeredinheritencemodel.MultilayeredinheritencemodelPackage.eINSTANCE.getB(), obj -> {
< 			multilayeredinheritencemodel.B _b = (multilayeredinheritencemodel.B) obj;
< 			incUtil.newMessage();
< 			name2actor.get("A_object").tell(new ObjectAdded<multilayeredinheritencemodel.A>(incUtil, _b), getSelf());
< 		});
84a75,84
> 		});
> 		type2addConsumer.put(multilayeredinheritencemodel.MultilayeredinheritencemodelPackage.eINSTANCE.getB(), obj -> {
> 			multilayeredinheritencemodel.B _b = (multilayeredinheritencemodel.B) obj;
> 			incUtil.newMessage();
> 			name2actor.get("A_object").tell(new ObjectAdded<multilayeredinheritencemodel.A>(incUtil, _b), getSelf());
> 		});
> 		type2addConsumer.put(multilayeredinheritencemodel.MultilayeredinheritencemodelPackage.eINSTANCE.getC(), obj -> {
> 			multilayeredinheritencemodel.C _c = (multilayeredinheritencemodel.C) obj;
> 			incUtil.newMessage();
> 			name2actor.get("A_object").tell(new ObjectAdded<multilayeredinheritencemodel.A>(incUtil, _c), getSelf());
diff --color --recursive gips.multilayeredinheritencersinit/src-gen/gips/multilayeredinheritencersinit/hipe/engine/actor/NotificationActor.java gips.multilayeredinheritencersinit_broken/src-gen/gips/multilayeredinheritencersinit/hipe/engine/actor/NotificationActor.java
21c21
< 		explorationConsumer.put(multilayeredinheritencemodel.MultilayeredinheritencemodelPackage.eINSTANCE.getC(), obj -> {
---
> 		explorationConsumer.put(multilayeredinheritencemodel.MultilayeredinheritencemodelPackage.eINSTANCE.getA(), obj -> {
25c25
< 		explorationConsumer.put(multilayeredinheritencemodel.MultilayeredinheritencemodelPackage.eINSTANCE.getB(), obj -> {
---
> 		explorationConsumer.put(multilayeredinheritencemodel.MultilayeredinheritencemodelPackage.eINSTANCE.getRoot(), obj -> {
26a27,28
> 			multilayeredinheritencemodel.Root _root = (multilayeredinheritencemodel.Root) obj;
> 			children.addAll(_root.getObjects());
29c31
< 		explorationConsumer.put(multilayeredinheritencemodel.MultilayeredinheritencemodelPackage.eINSTANCE.getA(), obj -> {
---
> 		explorationConsumer.put(multilayeredinheritencemodel.MultilayeredinheritencemodelPackage.eINSTANCE.getB(), obj -> {
33c35
< 		explorationConsumer.put(multilayeredinheritencemodel.MultilayeredinheritencemodelPackage.eINSTANCE.getRoot(), obj -> {
---
> 		explorationConsumer.put(multilayeredinheritencemodel.MultilayeredinheritencemodelPackage.eINSTANCE.getC(), obj -> {
35,36d36
< 			multilayeredinheritencemodel.Root _root = (multilayeredinheritencemodel.Root) obj;
< 			children.addAll(_root.getObjects());
@maxkratz maxkratz added the bug Something isn't working label Apr 29, 2024
@maxkratz
Copy link
Member Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant