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 22:24:50 UTC

[I] [new-parser] Unable to resolve method in a query [incubator-kie-drools]

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

   ## Parent issue
   - #5678 
   
   ## Failing tests
   - `org.drools.model.codegen.execmodel.QueryTest#testQueryWithDyanmicInsert`
   
   ## Notes
   - Both `STANDARD_FROM_DRL` and `PATTERN_DSL` but different error outputs.
   
   ## Rule code snippet
   ```
   query peeps( Person $p, String $name, int $age )
       $p := Person( ) from new Person( $name, $age )
   ```
   
   ## Error output
   ```
   ### parse : ANTLR4_PARSER_ENABLED = true
   line 1:0 mismatched input 'this' expecting {TIME_INTERVAL, DRL_STRING_LITERAL, '?/', DECIMAL_LITERAL, HEX_LITERAL, FLOAT_LITERAL, BOOL_LITERAL, STRING_LITERAL, 'null', '(', '[', '.', '<', '!', '~', '++', '--', '+', '-', '*', '/', IDENTIFIER}
   21:45:06.772 [main] ERROR o.d.c.k.b.impl.AbstractKieProject.buildKnowledgePackages:280 - Unable to build KieBaseModel:defaultKieBase
   Unable to Analyse Expression newPerson($name,$age):
   [Error: unable to resolve method using strict-mode: java.lang.Object.newPerson(java.lang.String, int)]
   [Near : {... newPerson($name,$age) ....}]
                ^ : [Query name='peeps']
   
   
   
   java.lang.AssertionError: [Message [id=1, kieBase=defaultKieBase, level=ERROR, path=r0.drl, line=-1, column=0
      text=Unable to Analyse Expression newPerson($name,$age):
   [Error: unable to resolve method using strict-mode: java.lang.Object.newPerson(java.lang.String, int)]
   [Near : {... newPerson($name,$age) ....}]
                ^]]
   
   	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.QueryTest.testQueryWithDyanmicInsert(QueryTest.java:823)
   ```


-- 
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] Unable to resolve method (`from new`) in a query [incubator-kie-drools]

Posted by "tkobayas (via GitHub)" <gi...@apache.org>.
tkobayas closed issue #5710: [new-parser] Unable to resolve method (`from new`) in a query
URL: https://github.com/apache/incubator-kie-drools/issues/5710


-- 
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] Unable to resolve method (`from new`) in a query [incubator-kie-drools]

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

   /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] Unable to resolve method (`from new`) in a query [incubator-kie-drools]

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

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


-- 
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