UnsupportedOperationException in FULL_ASSERT mode

22 megtekintés
Ugrás az első olvasatlan üzenetre

raicu...@gmail.com

olvasatlan,
2020. jan. 17. 5:17:022020. 01. 17.
– OptaPlanner development
Hi,

I have been trying out 7.31.0 final and ran into an exception in FULL_ASSERT mode.

From ConstraintMatch.java:

    public ConstraintMatch(String constraintPackage, String constraintName, List<Object> justificationList,
            Score score) {
        this.constraintPackage = constraintPackage;
        this.constraintName = constraintName;
        this.justificationList = Collections.unmodifiableList(justificationList);
        this.score = score;
    }

From AbstractScoreDirector in buildScoreCorruptionAnalysis method
        for (ConstraintMatchTotal constraintMatchTotal : corruptedConstraintMatchTotals) {
            for (ConstraintMatch constraintMatch : constraintMatchTotal.getConstraintMatchSet()) {
                constraintMatch.getJustificationList().sort(comparator);
            }
        }
        for (ConstraintMatchTotal constraintMatchTotal : uncorruptedConstraintMatchTotals) {
            for (ConstraintMatch constraintMatch : constraintMatchTotal.getConstraintMatchSet()) {
                constraintMatch.getJustificationList().sort(comparator);
            }
        }
It generates an UnsupportedOperationException. I am using java 1.8.

Hope this helps.

Lukas Petrovicky

olvasatlan,
2020. jan. 20. 2:47:302020. 01. 20.
– optapla...@googlegroups.com
Hi there,

On Fri, Jan 17, 2020 at 11:17 AM <raicu...@gmail.com> wrote:
I have been trying out 7.31.0 final and ran into an exception in FULL_ASSERT mode.

that could be a bug, we'll look into it.
In the meantime, disabling constraint matches should hopefully work around the exception.

Thanks for reporting and have a nice day!
 
--

Lukáš Petrovický

He/Him/His

Principal Software Engineer, Business Automation

Red Hat Czech, s. r. o.

Purkyňova 111, Brno

lukas.pe...@redhat.com    IM: triceo/lpetrovi

petrovic...@gmail.com

olvasatlan,
2020. jan. 20. 3:01:452020. 01. 20.
– OptaPlanner development


On Monday, January 20, 2020 at 8:47:30 AM UTC+1, Lukas Petrovicky wrote:
In the meantime, disabling constraint matches should hopefully work around the exception.

On second thought, no it shouldn't. There appears to be no workaround, other than to not use FULL_ASSERT.

-- Lukas 

Geoffrey De Smet

olvasatlan,
2020. jan. 22. 4:53:532020. 01. 22.
– optapla...@googlegroups.com

Is there a jira for this bug?

FULL_ASSERT is used a lot, I don't understand why this hasn't popped up before.
Are we sure it's not a regression?

With kind regards,
Geoffrey De Smet

--
You received this message because you are subscribed to the Google Groups "OptaPlanner development" group.
To unsubscribe from this group and stop receiving emails from it, send an email to optaplanner-d...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/optaplanner-dev/519fb584-4228-41ec-b1f6-ac8cb46e8222%40googlegroups.com.

Lukas Petrovicky

olvasatlan,
2020. jan. 22. 5:52:552020. 01. 22.
– optapla...@googlegroups.com
On Wed, Jan 22, 2020 at 10:54 AM Geoffrey De Smet <gds.geoffr...@gmail.com> wrote:

Is there a jira for this bug?

FULL_ASSERT is used a lot, I don't understand why this hasn't popped up before.
Are we sure it's not a regression?

Pretty sure it's a regression, most likely caused by me.
I have a fix ready for review: https://github.com/kiegroup/optaplanner/pull/659
 
Válasz mindenkinek
Válasz a szerzőnek
Továbbítás
0 új üzenet