Bug 1009385
Summary: | Invalid Guided Rule reopens with a different definition | ||||||||
---|---|---|---|---|---|---|---|---|---|
Product: | [Retired] JBoss BRMS Platform 6 | Reporter: | Zuzana Krejčová <zkrejcov> | ||||||
Component: | Business Central | Assignee: | Toni Rikkola <trikkola> | ||||||
Status: | CLOSED EOL | QA Contact: | Lukáš Petrovický <lpetrovi> | ||||||
Severity: | medium | Docs Contact: | |||||||
Priority: | medium | ||||||||
Version: | 6.0.0 | CC: | etirelli, lpetrovi, mbaluch | ||||||
Target Milestone: | ER3 | ||||||||
Target Release: | 6.1.0 | ||||||||
Hardware: | Unspecified | ||||||||
OS: | Unspecified | ||||||||
Whiteboard: | |||||||||
Fixed In Version: | Doc Type: | Bug Fix | |||||||
Doc Text: |
If you close and save the Guided Rule Editor with an unfinished or invalid change, you will not be able to work on the incomplete rule when you reopen it because the Guided Rule Editor opens the rule with a different definition.
Cause:
Consequence:
Fix:
Result:
|
Story Points: | --- | ||||||
Clone Of: | Environment: | ||||||||
Last Closed: | 2020-03-27 19:48:17 UTC | Type: | Bug | ||||||
Regression: | --- | Mount Type: | --- | ||||||
Documentation: | --- | CRM: | |||||||
Verified Versions: | Category: | --- | |||||||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||||
Cloudforms Team: | --- | Target Upstream Version: | |||||||
Embargoed: | |||||||||
Attachments: |
|
Description
Zuzana Krejčová
2013-09-18 10:34:04 UTC
Unit tests for this. https://github.com/droolsjbpm/drools/commit/52a7b1730 Trying to unmarshall an invalid drl is more or less like trying to unmarshall a malformed xml. I could fix the provided test cases, but for sure it will be impossible to do the same for all the possible combination that an invalid drl could generate. For this reason Toni and myself agreed to save a drl, and then attempt its unmarshall when necessary, only if it compiles. The current fix prevents the user from saving incomplete rules on "exists", "or" or "not" sections, asking the user to complete the areas marked in red (The missing fact types are red in the editor). master: https://github.com/droolsjbpm/drools-wb/commit/79283ebab 6.0.x: https://github.com/droolsjbpm/drools-wb/commit/fc38da234 (In reply to Toni Rikkola from comment #8) > The current fix prevents the user from saving incomplete rules on "exists", > "or" or "not" sections, asking the user to complete the areas marked in red > (The missing fact types are red in the editor). > > master: https://github.com/droolsjbpm/drools-wb/commit/79283ebab > > 6.0.x: https://github.com/droolsjbpm/drools-wb/commit/fc38da234 Sorry for not getting back to you earlier. The above mentioned sections work as you say. Could the same be done for "From [... | Accumulate | Collect | Entry point]" sections? If you don't finish these, the incomplete parts are also marked in red, but the rule can be saved anyway and the same thing happens that happened with "exists" before you fixed it. It can and should be done. The commits for https://bugzilla.redhat.com/show_bug.cgi?id=1012553 improve model validation when saving and actually cover the from/accumulate/collect and entry point. (In reply to Toni Rikkola from comment #11) > The commits for https://bugzilla.redhat.com/show_bug.cgi?id=1012553 improve > model validation when saving and actually cover the from/accumulate/collect > and entry point. Wrong link. Should be https://bugzilla.redhat.com/show_bug.cgi?id=1052269 "From Collect ..." is still an issue. The rests is fixed in ER2. master: https://github.com/droolsjbpm/drools-wb/commit/13c5c52c6 6.1.x: https://github.com/droolsjbpm/drools-wb/commit/14936052e Adjusting the flags as the last commit from this ticket did not make 6.0.2.CR1 cut. "From Collect ..." now cannot even be added to the rule without totally corrupting it. Everything below that condition simply disappears - from the editor and also from the displayed source. The fix is at least partially working as trying to save the rule results in the expected warning. (working with DR3) Created attachment 942235 [details]
DR3 - broken editor
Created attachment 942236 [details]
DR3 - displayed source
(In reply to Zuzana Krejčová from comment #16) > "From Collect ..." now cannot even be added to the rule without totally > corrupting it. Everything below that condition simply disappears - from the > editor and also from the displayed source. > The fix is at least partially working as trying to save the rule results in > the expected warning. > (working with DR3) Fixes for this. Now it should prevent the save if any red is shown. master: https://github.com/droolsjbpm/drools-wb/commit/0e82448ef 6.2.x: https://github.com/droolsjbpm/drools-wb/commit/763d4f720 |