[
https://issues.jboss.org/browse/JBRULES-3361?page=com.atlassian.jira.plug...
]
James Walker updated JBRULES-3361:
----------------------------------
Summary: Salience format error not directly noticed by Eclipse plugin or at
compile time (was: Salience format error (Salience - 150) so)
Affects Version/s: 5.4.0.Beta1
Description:
{noformat}
rule "If no existing wrapper make one"
no-loop
salience - 50 //Error in formatting - space between - and 50 not compile time or Eclipse
editor error
when
$tp : TextPosition($textStart : indexstart, $textEnd : indexend, $text : text,
$metrics : Metrics, !discard)
FormatWrapper($formatStart: format.startPos, $formatEnd: format.endPos)
eval($textStart >= $formatStart || $textEnd >= $formatStart) //Check for
overlap
eval($formatStart >= $textStart || $formatEnd >= $textStart)
not TextWrapper(texpos == $tp)
then
TextWrapper tw = new TextWrapper($text,$metrics,$tp);
insert(tw);
end
{noformat}
Run-time error
{noformat}
Exception executing consequence for rule "Wrap FormatData" in guessing:
java.lang.NullPointerException
at
org.drools.runtime.rule.impl.DefaultConsequenceExceptionHandler.handleException(DefaultConsequenceExceptionHandler.java:39)
at org.drools.common.DefaultAgenda.fireActivation(DefaultAgenda.java:1101)
at org.drools.common.DefaultAgenda.fireNextItem(DefaultAgenda.java:1029)
at org.drools.common.DefaultAgenda.fireAllRules(DefaultAgenda.java:1251)
at org.drools.common.AbstractWorkingMemory.fireAllRules(AbstractWorkingMemory.java:709)
at org.drools.common.AbstractWorkingMemory.fireAllRules(AbstractWorkingMemory.java:673)
at
org.drools.impl.StatefulKnowledgeSessionImpl.fireAllRules(StatefulKnowledgeSessionImpl.java:219)
at drools.PhraseAnalyse.analyseTitle(PhraseAnalyse.java:39)
at pdfbox.maintest.main(maintest.java:43)
Caused by: java.lang.NullPointerException
at org.drools.base.mvel.MVELSalienceExpression.getValue(MVELSalienceExpression.java:86)
at org.drools.reteoo.RuleTerminalNode.createActivations(RuleTerminalNode.java:279)
at org.drools.reteoo.RuleTerminalNode.assertLeftTuple(RuleTerminalNode.java:184)
at
org.drools.reteoo.SingleLeftTupleSinkAdapter.doPropagateAssertLeftTuple(SingleLeftTupleSinkAdapter.java:197)
at
org.drools.reteoo.SingleLeftTupleSinkAdapter.propagateAssertLeftTuple(SingleLeftTupleSinkAdapter.java:86)
at org.drools.reteoo.NotNode.assertLeftTuple(NotNode.java:100)
at
org.drools.reteoo.SingleLeftTupleSinkAdapter.doPropagateAssertLeftTuple(SingleLeftTupleSinkAdapter.java:197)
at
org.drools.reteoo.SingleLeftTupleSinkAdapter.propagateAssertLeftTuple(SingleLeftTupleSinkAdapter.java:86)
at org.drools.reteoo.EvalConditionNode.assertLeftTuple(EvalConditionNode.java:183)
at
org.drools.reteoo.SingleLeftTupleSinkAdapter.doPropagateAssertLeftTuple(SingleLeftTupleSinkAdapter.java:197)
at
org.drools.reteoo.SingleLeftTupleSinkAdapter.propagateAssertLeftTuple(SingleLeftTupleSinkAdapter.java:86)
at org.drools.reteoo.EvalConditionNode.assertLeftTuple(EvalConditionNode.java:183)
at
org.drools.reteoo.SingleLeftTupleSinkAdapter.doPropagateAssertLeftTuple(SingleLeftTupleSinkAdapter.java:197)
at
org.drools.reteoo.SingleLeftTupleSinkAdapter.propagateAssertLeftTuple(SingleLeftTupleSinkAdapter.java:72)
at org.drools.reteoo.JoinNode.assertObject(JoinNode.java:161)
at
org.drools.reteoo.CompositeObjectSinkAdapter.doPropagateAssertObject(CompositeObjectSinkAdapter.java:458)
at
org.drools.reteoo.CompositeObjectSinkAdapter.propagateAssertObject(CompositeObjectSinkAdapter.java:386)
at org.drools.reteoo.ObjectTypeNode.assertObject(ObjectTypeNode.java:211)
at org.drools.reteoo.EntryPointNode.assertObject(EntryPointNode.java:244)
at org.drools.common.NamedEntryPoint.insert(NamedEntryPoint.java:336)
at org.drools.common.NamedEntryPoint.insert(NamedEntryPoint.java:297)
at org.drools.common.AbstractWorkingMemory.insert(AbstractWorkingMemory.java:887)
at org.drools.base.DefaultKnowledgeHelper.insert(DefaultKnowledgeHelper.java:180)
at org.drools.base.DefaultKnowledgeHelper.insert(DefaultKnowledgeHelper.java:174)
at
guessing.Rule_Wrap_FormatData_55c760725b024ac8b9db87cf6c1aaa5c.defaultConsequence(Rule_Wrap_FormatData_55c760725b024ac8b9db87cf6c1aaa5c.java:9)
at
guessing.Rule_Wrap_FormatData_55c760725b024ac8b9db87cf6c1aaa5cDefaultConsequenceInvokerGenerated.evaluate(Unknown
Source)
at
guessing.Rule_Wrap_FormatData_55c760725b024ac8b9db87cf6c1aaa5cDefaultConsequenceInvoker.evaluate(Unknown
Source)
at org.drools.common.DefaultAgenda.fireActivation(DefaultAgenda.java:1091)
... 7 more
{noformat}
Component/s: drools-core
drools-eclipse
Salience format error not directly noticed by Eclipse plugin or at
compile time
--------------------------------------------------------------------------------
Key: JBRULES-3361
URL:
https://issues.jboss.org/browse/JBRULES-3361
Project: Drools
Issue Type: Bug
Security Level: Public(Everyone can see)
Components: drools-core, drools-eclipse
Affects Versions: 5.4.0.Beta1
Reporter: James Walker
Assignee: Mark Proctor
{noformat}
rule "If no existing wrapper make one"
no-loop
salience - 50 //Error in formatting - space between - and 50 not compile time or Eclipse
editor error
when
$tp : TextPosition($textStart : indexstart, $textEnd : indexend, $text : text,
$metrics : Metrics, !discard)
FormatWrapper($formatStart: format.startPos, $formatEnd: format.endPos)
eval($textStart >= $formatStart || $textEnd >= $formatStart) //Check for
overlap
eval($formatStart >= $textStart || $formatEnd >= $textStart)
not TextWrapper(texpos == $tp)
then
TextWrapper tw = new TextWrapper($text,$metrics,$tp);
insert(tw);
end
{noformat}
Run-time error
{noformat}
Exception executing consequence for rule "Wrap FormatData" in guessing:
java.lang.NullPointerException
at
org.drools.runtime.rule.impl.DefaultConsequenceExceptionHandler.handleException(DefaultConsequenceExceptionHandler.java:39)
at org.drools.common.DefaultAgenda.fireActivation(DefaultAgenda.java:1101)
at org.drools.common.DefaultAgenda.fireNextItem(DefaultAgenda.java:1029)
at org.drools.common.DefaultAgenda.fireAllRules(DefaultAgenda.java:1251)
at org.drools.common.AbstractWorkingMemory.fireAllRules(AbstractWorkingMemory.java:709)
at org.drools.common.AbstractWorkingMemory.fireAllRules(AbstractWorkingMemory.java:673)
at
org.drools.impl.StatefulKnowledgeSessionImpl.fireAllRules(StatefulKnowledgeSessionImpl.java:219)
at drools.PhraseAnalyse.analyseTitle(PhraseAnalyse.java:39)
at pdfbox.maintest.main(maintest.java:43)
Caused by: java.lang.NullPointerException
at org.drools.base.mvel.MVELSalienceExpression.getValue(MVELSalienceExpression.java:86)
at org.drools.reteoo.RuleTerminalNode.createActivations(RuleTerminalNode.java:279)
at org.drools.reteoo.RuleTerminalNode.assertLeftTuple(RuleTerminalNode.java:184)
at
org.drools.reteoo.SingleLeftTupleSinkAdapter.doPropagateAssertLeftTuple(SingleLeftTupleSinkAdapter.java:197)
at
org.drools.reteoo.SingleLeftTupleSinkAdapter.propagateAssertLeftTuple(SingleLeftTupleSinkAdapter.java:86)
at org.drools.reteoo.NotNode.assertLeftTuple(NotNode.java:100)
at
org.drools.reteoo.SingleLeftTupleSinkAdapter.doPropagateAssertLeftTuple(SingleLeftTupleSinkAdapter.java:197)
at
org.drools.reteoo.SingleLeftTupleSinkAdapter.propagateAssertLeftTuple(SingleLeftTupleSinkAdapter.java:86)
at org.drools.reteoo.EvalConditionNode.assertLeftTuple(EvalConditionNode.java:183)
at
org.drools.reteoo.SingleLeftTupleSinkAdapter.doPropagateAssertLeftTuple(SingleLeftTupleSinkAdapter.java:197)
at
org.drools.reteoo.SingleLeftTupleSinkAdapter.propagateAssertLeftTuple(SingleLeftTupleSinkAdapter.java:86)
at org.drools.reteoo.EvalConditionNode.assertLeftTuple(EvalConditionNode.java:183)
at
org.drools.reteoo.SingleLeftTupleSinkAdapter.doPropagateAssertLeftTuple(SingleLeftTupleSinkAdapter.java:197)
at
org.drools.reteoo.SingleLeftTupleSinkAdapter.propagateAssertLeftTuple(SingleLeftTupleSinkAdapter.java:72)
at org.drools.reteoo.JoinNode.assertObject(JoinNode.java:161)
at
org.drools.reteoo.CompositeObjectSinkAdapter.doPropagateAssertObject(CompositeObjectSinkAdapter.java:458)
at
org.drools.reteoo.CompositeObjectSinkAdapter.propagateAssertObject(CompositeObjectSinkAdapter.java:386)
at org.drools.reteoo.ObjectTypeNode.assertObject(ObjectTypeNode.java:211)
at org.drools.reteoo.EntryPointNode.assertObject(EntryPointNode.java:244)
at org.drools.common.NamedEntryPoint.insert(NamedEntryPoint.java:336)
at org.drools.common.NamedEntryPoint.insert(NamedEntryPoint.java:297)
at org.drools.common.AbstractWorkingMemory.insert(AbstractWorkingMemory.java:887)
at org.drools.base.DefaultKnowledgeHelper.insert(DefaultKnowledgeHelper.java:180)
at org.drools.base.DefaultKnowledgeHelper.insert(DefaultKnowledgeHelper.java:174)
at
guessing.Rule_Wrap_FormatData_55c760725b024ac8b9db87cf6c1aaa5c.defaultConsequence(Rule_Wrap_FormatData_55c760725b024ac8b9db87cf6c1aaa5c.java:9)
at
guessing.Rule_Wrap_FormatData_55c760725b024ac8b9db87cf6c1aaa5cDefaultConsequenceInvokerGenerated.evaluate(Unknown
Source)
at
guessing.Rule_Wrap_FormatData_55c760725b024ac8b9db87cf6c1aaa5cDefaultConsequenceInvoker.evaluate(Unknown
Source)
at org.drools.common.DefaultAgenda.fireActivation(DefaultAgenda.java:1091)
... 7 more
{noformat}
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.jboss.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see:
http://www.atlassian.com/software/jira