-
Notifications
You must be signed in to change notification settings - Fork 2.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[DROOLS-6627] Verify Scorecard reasoncode when result is null #3875
Conversation
# Conflicts: # kie-pmml-trusty/kie-pmml-compiler/kie-pmml-compiler-core/src/main/java/org/kie/pmml/compiler/executor/PMMLCompilerImpl.java
# Conflicts: # kie-pmml-trusty/kie-pmml-compiler/kie-pmml-compiler-commons/src/test/java/org/kie/pmml/compiler/commons/builders/KiePMMLModelCodegenUtilsTest.java # kie-pmml-trusty/kie-pmml-compiler/kie-pmml-compiler-commons/src/test/java/org/kie/pmml/compiler/commons/codegenfactories/KiePMMLModelFactoryUtilsTest.java
# Conflicts: # kie-pmml-trusty/kie-pmml-compiler/kie-pmml-compiler-commons/src/test/java/org/kie/pmml/compiler/commons/builders/KiePMMLModelCodegenUtilsTest.java # kie-pmml-trusty/kie-pmml-compiler/kie-pmml-compiler-commons/src/test/java/org/kie/pmml/compiler/commons/codegenfactories/KiePMMLModelFactoryUtilsTest.java # kie-pmml-trusty/kie-pmml-models/kie-pmml-models-drools/kie-pmml-models-drools-common/src/main/java/org/kie/pmml/models/drools/commons/model/KiePMMLDroolsModel.java
# Conflicts: # kie-pmml-trusty/kie-pmml-compiler/kie-pmml-compiler-commons/src/test/java/org/kie/pmml/compiler/commons/builders/KiePMMLModelCodegenUtilsTest.java
# Conflicts: # kie-pmml-trusty/kie-pmml-compiler/kie-pmml-compiler-commons/src/test/java/org/kie/pmml/compiler/commons/builders/KiePMMLModelCodegenUtilsTest.java
KiePMMLSessionUtils.Builder builder = KiePMMLSessionUtils.builder((KieBase) knowledgeBase, name, packageName, | ||
toReturn) | ||
.withObjectsInSession(requestData, fieldTypeMap) | ||
.withOutputFieldsMap(outputFieldsMap); | ||
.withOutputFieldsMap(holder); | ||
outputFieldsMap = holder; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this necessary? I don't usually like a method that changes the instance of a field. Isn't possible to do
outpitFieldsMap.putAll(output)
?
Or do a clear()
if necessary
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@danielezonca
done
reasonCodeAlgorithm, | ||
useReasonCodes, | ||
baselineScore).orElse(null); | ||
outputFieldsMap = holder; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@danielezonca
done
Kudos, SonarCloud Quality Gate passed! |
…#3875) * [DROOLS-6625] Managing missing "required" input data * [DROOLS-6625] Managing best-effort conversion of input data * [DROOLS-6625] Managing invalid values - TODO: integration tests * [DROOLS-6625] Managing invalid values * [DROOLS-6625] Managing missing values * [DROOLS-6625] Validate input data * [DROOLS-6635] Move testing sources in specific files * [DROOLS-6625] Fix merge with base branch * [DROOLS-6625] Fix as per PR suggestion * [DROOLS-6635] Fix merge * [DROOLS-6627] Verify Scorecard reasoncode when result is null * [DROOLS-6635] Fix merge with 7.x * [DROOLS-6627] Fix merge * [DROOLS-6627] Fixed as per PR request
…#3883) * [DROOLS-6625] Managing missing "required" input data * [DROOLS-6625] Managing best-effort conversion of input data * [DROOLS-6625] Managing invalid values - TODO: integration tests * [DROOLS-6625] Managing invalid values * [DROOLS-6625] Managing missing values * [DROOLS-6625] Validate input data * [DROOLS-6635] Move testing sources in specific files * [DROOLS-6625] Fix merge with base branch * [DROOLS-6625] Fix as per PR suggestion * [DROOLS-6635] Fix merge * [DROOLS-6627] Verify Scorecard reasoncode when result is null * [DROOLS-6635] Fix merge with 7.x * [DROOLS-6627] Fix merge * [DROOLS-6627] Fixed as per PR request
@danielezonca @kostola @jiripetrlik
See https://issues.redhat.com/browse/DROOLS-6627
Please note there is an underlying issue not completely fixed, i.e. the "status" of "KiePMMLModel" that it is preserved between multiple invocation.
The overall fix will require a global refactor, and will be addressed by https://issues.redhat.com/browse/DROOLS-6641
This PR must be merged after https://github.com/kiegroup/drools/pull/3868