You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kie.apache.org by "dschulten (via GitHub)" <gi...@apache.org> on 2026/07/07 16:00:30 UTC
[I] Sandbox execute form fails to send null for empty field [incubator-kie-tools]
dschulten opened a new issue, #3648:
URL: https://github.com/apache/incubator-kie-tools/issues/3648
In the KIE Sandbox I am executing a DMN Model that passes an input `Foo` of type `number` to a Context Boxed Expression named `Baz`. In the Context I refer to the input `Foo`, and I try to handle null:
```
Bar: if Foo
= null then 0 else Foo
result: Bar
```
When I click **Execute** in the KIE Sandbox, and do not enter a value for `Foo` angebe, then my context is not evaluated, and I see the error message **Required dependency 'Foo' not found on Node 'Baz'**.
It appears this happens because the execution form in the sandbox does not send `null` for empty inputs of type number:
```
{
"Foo": null
}
```
Rather, it sends an empty object to /jitdmn/dmnresult:
```
{}
```
Is there a way to send null as input value for an input of type number in the Sandbox execute form? Changing the Language of my Bar expression to B-FEEL does not help.
Note: If I switch the type of `Foo` to `Any`, the Sandbox form sends an empty string to the extended services, which also does not seem quite right - I would have expected the form to send `null` for an empty string field as well.
Version info:
Build Version:
10.2.0
Kogito Runtimes Version:
10.2.0
Quarkus Version:
3.27.2
Dev Deployments Base image URL:
docker.io/apache/incubator-kie-sandbox-dev-deployment-base:10.2.0
Dev Deployments Quarkus Blank App image URL:
docker.io/apache/incubator-kie-sandbox-dev-deployment-quarkus-blank-app:10.2.0
Dev Deployments DMN Form webapp image URL:
http://localhost:8086
Extended Services version:
10.2.0
Commit SHA:
116e8d86d
Edge, Windows 11
(rename file extension from .dmn.xml to .dmn before opening with tools)
[Fails to send null for empty field.dmn.xml](https://github.com/user-attachments/files/29753065/Fails.to.send.null.for.empty.field.dmn.xml)
--
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] DMN Editor: Sandbox execute form does not support null for empty field [incubator-kie-tools]
Posted by "dschulten (via GitHub)" <gi...@apache.org>.
dschulten commented on issue #3648:
URL: https://github.com/apache/incubator-kie-tools/issues/3648#issuecomment-5096031096
> ### Fix
>
> Sandbox allow to send via form values of given type or `null` value. It does not allow to omit given field from json payload never.
>
> How does it sound to you ? [@dschulten](https://github.com/dschulten)
Excellent. Exactly what I was hoping for!
--
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] DMN Editor: Sandbox execute form does not support null for empty field [incubator-kie-tools]
Posted by "jomarko (via GitHub)" <gi...@apache.org>.
jomarko commented on issue #3648:
URL: https://github.com/apache/incubator-kie-tools/issues/3648#issuecomment-4978814744
Thank you for this ticket. I think it is a good topic, however may be tricky to solve it in these scenarios:
### Strings
How should we distinguish in the existing UI
- User wants to send `null` value
- User wants to send `"null"` string
- User wants to send `""` empty string
- User does not want do send any value
### Numbers and other scalar types
- User wants to send `null` value
- User does not want do send any value
--
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] DMN Editor: Sandbox execute form does not support null for empty field [incubator-kie-tools]
Posted by "dschulten (via GitHub)" <gi...@apache.org>.
dschulten commented on issue #3648:
URL: https://github.com/apache/incubator-kie-tools/issues/3648#issuecomment-4983153596
In DMN, it seems an input that is not present should always exist, but it should have a value of null. Only then you can handle it as null. The DMN Engine does it that way.
DMN has no concept of `undefined` like Javascript, where you could omit an input altogether. Also, DMN has no concept of empty strings for a value that has not been entered. To me it seems that omitting an attribute of unknown value or setting it to the empty string is a natural thing in Javascript, but totally unexpected in DMN. I would say, almost every html form on the interwebs does not allow you to enter an empty string. You can only enter nothing, and applications treat that as a missing field, if it's mandatory.
### Strings:
* User wants to send null: enter no value in the Sandbox form
* User wants to send "null": enter "null"
* User wants to send "" - why would they want to do that in the Sandbox?
* User does not want to send any value - enter no value. Omitting the attribute is the current behaviour and it breaks the DMN engine in extended-services
### Numbers
* User wants to send null: enter no value
* User does not want to send any value: enter no value. Not sending the attribute breaks the DMN engine in extended-services.
It boils down to this: The DMN model can und must handle `null` as missing input. Giving the user the choice that sending nothing can mean three thrings (not there, empty string, null) complicates the life of modelers enormously, and if you ask me, it gains nothing.
--
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] DMN Editor: Sandbox execute form does not support null for empty field [incubator-kie-tools]
Posted by "dschulten (via GitHub)" <gi...@apache.org>.
dschulten commented on issue #3648:
URL: https://github.com/apache/incubator-kie-tools/issues/3648#issuecomment-4922054483
I may have found a workaround: it appears that scalar top level inputs are automatically required, but attributes of a complex input are never required. The workaround would be to wrap all scalar inputs into a wrapper type to make the sandbox happy. So one would need a tNumber, tString, tBoolean, tDate etc, and all calculations would need to unwrap them.
That is not exactly satisfying, I have to say. I hope there is a better solution (or we can get a proper fix for this issue).
--
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] DMN Editor: Sandbox execute form does not support null for empty field [incubator-kie-tools]
Posted by "jomarko (via GitHub)" <gi...@apache.org>.
jomarko commented on issue #3648:
URL: https://github.com/apache/incubator-kie-tools/issues/3648#issuecomment-4989171986
Interesting paper, however it is a research, if I understand correctly, that may and may be not reflected in specification in future.
Thank you for your clarification for **Strings** and **Numbers**. While I agree empty string usage should be discouraged, at the same time it is a valid value and we do not have control if some user use it or not.
Here is my understanding of our discussion.
### Currently
Sandbox allow to send via form values of given type or it omit the field from the json payload completely. It does not allow to send `null` value.
### Fix
Sandbox allow to send via form values of given type or `null` value. It does not allow to omit given field from json payload never.
How does it sound to you ? @dschulten
--
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