-
Bug Report
-
Resolution: Fixed
-
L3 - Default
-
7.13.0
-
None
-
None
Steps to reproduce
- Define no typeRef for input expression
- Specify a variable of type short
- Compare the value with number comparison
Expected behavior
Comparison works
Observed behavior
The following exception is thrown:
org.camunda.bpm.dmn.feel.impl.FeelException: failed to evaluate expression '>= 5.66': ValContext(CacheContext(ObjectContext(5))) is not comparable
Is this a bug according to the DMN FEEL 1.2 specification?
- No, the specification proposes to represent the FEEL value number with the help of the Java Type java.math.BigDecimal
- The Java type short is not explicitly supported
Estimation
Easy-pick since we only need to add short to the DefaultValueMapper [1]
[1] https://github.com/camunda/feel-scala/blob/master/feel-engine/src/main/scala/org/camunda/feel/impl/DefaultValueMapper.scala#L46
This is the controller panel for Smart Panels app
[CAM-11304] In Scala FEEL Engine, number comparison does not work for type short
Summary | Original: [BREAKING CHANGE] In Scala FEEL Engine, number comparison does not work for type short | New: [BUG] In Scala FEEL Engine, number comparison does not work for type short |
Fix Version/s | New: 7.13.0 [ 15532 ] |
Description |
Original:
*Steps to reproduce*
* Define no {{typeRef}} for input expression * Specify a variable of type short * Compare the value with number comparison *Expected behavior* Comparison works *Observed behavior* The following exception is thrown: {{org.camunda.bpm.dmn.feel.impl.FeelException: failed to evaluate expression '>= 5.66': ValContext(CacheContext(ObjectContext(5))) is not comparable}} |
New:
*Steps to reproduce*
* Define no {{typeRef}} for input expression * Specify a variable of type short * Compare the value with number comparison *Expected behavior* Comparison works *Observed behavior* The following exception is thrown: {{org.camunda.bpm.dmn.feel.impl.FeelException: failed to evaluate expression '>= 5.66': ValContext(CacheContext(ObjectContext(5))) is not comparable}} *Is this a bug according to the DMN FEEL specification?* * No, the specification proposes to represent the FEEL value {{number}} with the help of the Java Type {{java.math.BigDecimal}} * The Java type short is not explicitly supported |
Mentioned Roles |
Mentioned Groups |
Description |
Original:
*Steps to reproduce*
* Define no {{typeRef}} for input expression * Specify a variable of type short * Compare the value with number comparison *Expected behavior* Comparison works *Observed behavior* The following exception is thrown: {{org.camunda.bpm.dmn.feel.impl.FeelException: failed to evaluate expression '>= 5.66': ValContext(CacheContext(ObjectContext(5))) is not comparable}} *Is this a bug according to the DMN FEEL specification?* * No, the specification proposes to represent the FEEL value {{number}} with the help of the Java Type {{java.math.BigDecimal}} * The Java type short is not explicitly supported |
New:
*Steps to reproduce*
* Define no {{typeRef}} for input expression * Specify a variable of type short * Compare the value with number comparison *Expected behavior* Comparison works *Observed behavior* The following exception is thrown: {{org.camunda.bpm.dmn.feel.impl.FeelException: failed to evaluate expression '>= 5.66': ValContext(CacheContext(ObjectContext(5))) is not comparable}} *Is this a bug according to the DMN FEEL 1.2 specification?* * No, the specification proposes to represent the FEEL value {{number}} with the help of the Java Type {{java.math.BigDecimal}} * The Java type short is not explicitly supported |
Mentioned Roles |
Mentioned Groups |
Description |
Original:
*Steps to reproduce*
* Define no {{typeRef}} for input expression * Specify a variable of type short * Compare the value with number comparison *Expected behavior* Comparison works *Observed behavior* The following exception is thrown: {{org.camunda.bpm.dmn.feel.impl.FeelException: failed to evaluate expression '>= 5.66': ValContext(CacheContext(ObjectContext(5))) is not comparable}} *Is this a bug according to the DMN FEEL 1.2 specification?* * No, the specification proposes to represent the FEEL value {{number}} with the help of the Java Type {{java.math.BigDecimal}} * The Java type short is not explicitly supported |
New:
*Steps to reproduce*
* Define no {{typeRef}} for input expression * Specify a variable of type short * Compare the value with number comparison *Expected behavior* Comparison works *Observed behavior* The following exception is thrown: {{org.camunda.bpm.dmn.feel.impl.FeelException: failed to evaluate expression '>= 5.66': ValContext(CacheContext(ObjectContext(5))) is not comparable}} *Is this a bug according to the DMN FEEL 1.2 specification?* * No, the specification proposes to represent the FEEL value {{number}} with the help of the Java Type {{java.math.BigDecimal}} * The Java type short is not explicitly supported *Estimation* Easy-pick since we only need to add short to the {{DefaultValueMapper}} [1] [1] https://github.com/camunda/feel-scala/blob/master/feel-engine/src/main/scala/org/camunda/feel/impl/DefaultValueMapper.scala#L46 |
Mentioned Roles |
Mentioned Groups |