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/04/02 06:52:45 UTC
[I] [new-parser] Parser error when type declaration field name is a DRL keyword [incubator-kie-drools]
yurloc opened a new issue, #5813:
URL: https://github.com/apache/incubator-kie-drools/issues/5813
## Parent issue
- #5678
## Failing tests
- `org.drools.model.codegen.execmodel.CepTest#testDeclareAndExpires`
## Notes
- Both `STANDARD_FROM_DRL` and `PATTERN_DSL`.
## Rule code snippet
```
package org.drools.compiler;
declare StockFact
@role( value = event )
@expires( value = 2s, policy = TIME_SOFT )
company : String
duration : long
end
rule "expiration"
when
StockFact( company == "DROO" )
then
end
```
## Error output
```
### parse : ANTLR4_PARSER_ENABLED = true
line 12:0 mismatched input 'then' expecting {'end', '@', IDENTIFIER}
08:48:36.145 [main] ERROR o.d.c.k.b.impl.AbstractKieProject.buildKnowledgePackages:280 - Unable to build KieBaseModel:kb
[12,0]: mismatched input 'then' expecting {'end', '@', IDENTIFIER}
[0,0]: Parser returned a null Package
java.lang.AssertionError: [Message [id=1, kieBase=kb, level=ERROR, path=r0.drl, line=12, column=0
text=mismatched input 'then' expecting {'end', '@', IDENTIFIER}], Message [id=2, kieBase=kb, level=ERROR, path=r0.drl, line=0, column=0
text=Parser returned a null Package]]
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.CepTest.testDeclareAndExpires(CepTest.java:484)
```
--
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] Parser error when type declaration field name is a DRL keyword [incubator-kie-drools]
Posted by "yurloc (via GitHub)" <gi...@apache.org>.
yurloc closed issue #5813: [new-parser] Parser error when type declaration field name is a DRL keyword
URL: https://github.com/apache/incubator-kie-drools/issues/5813
--
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] Parser error when type declaration field name is a DRL keyword [incubator-kie-drools]
Posted by "yurloc (via GitHub)" <gi...@apache.org>.
yurloc commented on issue #5813:
URL: https://github.com/apache/incubator-kie-drools/issues/5813#issuecomment-2031341155
`/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