You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kie.apache.org by "yurloc (via GitHub)" <gi...@apache.org> on 2024/02/20 21:55:01 UTC

[I] [new-parser] Grouped accessors for nested objects broken [incubator-kie-drools]

yurloc opened a new issue, #5706:
URL: https://github.com/apache/incubator-kie-drools/issues/5706

   Parent issue:
   - #5678 
   
   Failing test: `org.drools.model.codegen.execmodel.CompilerTest#testChainOfMethodCallInConstraintSub`
   
   Note: `PATTERN_DSL` only
   
   Rule code snippet:
   ```
     $p : Person( address.(city.startsWith("I") &&  city.length() == 5  ) )
   ```
   
   Error output:
   ```
   ### parse : ANTLR4_PARSER_ENABLED = true
   
   java.lang.AssertionError: [Message [id=1, level=ERROR, path=src/main/java/defaultpkg/PFA/LambdaPredicateFAECF003FA1F7B02276D174B3E3A28E2.java, line=22, column=809
      text=Type mismatch: cannot convert from Address to boolean], Message [id=2, level=ERROR, path=src/main/java/defaultpkg/PFA/LambdaPredicateFAECF003FA1F7B02276D174B3E3A28E2.java, line=0, column=0
      text=Java source of src/main/java/defaultpkg/PFA/LambdaPredicateFAECF003FA1F7B02276D174B3E3A28E2.java in error:
   package defaultpkg.PFA;
   
   
   import static defaultpkg.Rules029EE342789B9ECE6C6C0AEA5F2505EC.*;
   import org.drools.model.codegen.execmodel.domain.Person;
   import defaultpkg.*;
   import org.drools.modelcompiler.dsl.pattern.D;
   
   @org.drools.compiler.kie.builder.MaterializedLambda()
   public enum LambdaPredicateFAECF003FA1F7B02276D174B3E3A28E2 implements org.drools.model.functions.Predicate1<org.drools.model.codegen.execmodel.domain.Person>, org.drools.model.functions.HashedExpression {
   
       INSTANCE;
   
       public static final String EXPRESSION_HASH = "8D259D9F1DDB57E5CB829B926CC8A8B4";
   
       public java.lang.String getExpressionHash() {
           return EXPRESSION_HASH;
       }
   
       @Override()
       public boolean test(org.drools.model.codegen.execmodel.domain.Person _this) throws java.lang.Exception {
           return _this.getAddress();
       }
   
       @Override()
       public org.drools.model.functions.PredicateInformation predicateInformation() {
           org.drools.model.functions.PredicateInformation info = new org.drools.model.functions.PredicateInformation("address.(city.startsWith(\"I\") &&  city.length() == 5  )");
           info.addRuleNames("R", "r0.drl");
           return info;
       }
   }
   ]]
   
   	at org.drools.model.codegen.execmodel.BaseModelTest.createKieBuilder(BaseModelTest.java:157)
   	at org.drools.model.codegen.execmodel.BaseModelTest.createKieBuilder(BaseModelTest.java:132)
   	at org.drools.model.codegen.execmodel.BaseModelTest.getKieContainer(BaseModelTest.java:121)
   	at org.drools.model.codegen.execmodel.BaseModelTest.getKieContainer(BaseModelTest.java:114)
   	at org.drools.model.codegen.execmodel.BaseModelTest.getKieSession(BaseModelTest.java:110)
   	at org.drools.model.codegen.execmodel.BaseModelTest.getKieSession(BaseModelTest.java:106)
   	at org.drools.model.codegen.execmodel.CompilerTest.testChainOfMethodCallInConstraintSub(CompilerTest.java:990)
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@kie.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@kie.apache.org
For additional commands, e-mail: commits-help@kie.apache.org


Re: [I] [new-parser] Grouped accessors for nested objects broken [incubator-kie-drools]

Posted by "tkobayas (via GitHub)" <gi...@apache.org>.
tkobayas commented on issue #5706:
URL: https://github.com/apache/incubator-kie-drools/issues/5706#issuecomment-1998869212

   /take


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@kie.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@kie.apache.org
For additional commands, e-mail: commits-help@kie.apache.org


Re: [I] [new-parser] Grouped accessors for nested objects broken [incubator-kie-drools]

Posted by "tkobayas (via GitHub)" <gi...@apache.org>.
tkobayas closed issue #5706: [new-parser] Grouped accessors for nested objects broken
URL: https://github.com/apache/incubator-kie-drools/issues/5706


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@kie.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@kie.apache.org
For additional commands, e-mail: commits-help@kie.apache.org


Re: [I] [new-parser] Grouped accessors for nested objects broken [incubator-kie-drools]

Posted by "tkobayas (via GitHub)" <gi...@apache.org>.
tkobayas commented on issue #5706:
URL: https://github.com/apache/incubator-kie-drools/issues/5706#issuecomment-2005644612

   Fixed by https://github.com/apache/incubator-kie-drools/pull/5790


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@kie.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@kie.apache.org
For additional commands, e-mail: commits-help@kie.apache.org