nasa / europa

217 stars 72 forks source link

Equality constraint between a temporal variable and a non-temporal variable causes segfault #74

Closed miatauro-NASA closed 9 years ago

miatauro-NASA commented 9 years ago

From None on May 04, 2010 08:30:56

Original issue: http://code.google.com/p/europa-pso/issues/detail?id=74

miatauro-NASA commented 9 years ago

I added a test case for this in 39bd6b9, but it doesn't seem to reproduce the problem. Closing this for the moment.

phmorris commented 9 years ago

We have seen this problem before. There was a discussion about it on the Google feedback from users. The issue was that the non-temporal variable increment needs to be made into a temporal variable by using the temporalDistance constraint rather than the Equal or eqSum constraints. (Not all constraint network variables are temporal variables.) Maybe it was fixed.

Paul

On 02/22/15 03:48 PM, miatauro-NASA wrote:

I added a test case for this in 39bd6b9 https://github.com/nasa/europa/commit/39bd6b97ec9b19c715b562c6cc20e2ab089812a7, but it doesn't seem to reproduce the problem. Closing this for the moment.

� Reply to this email directly or view it on GitHub https://github.com/nasa/europa/issues/74#issuecomment-75472718.

phmorris commented 9 years ago

https://groups.google.com/forum/?hl=en#!topic/europa-users/_v7kLMXB3-c

You need to use the algebraic syntax for the constraint in order to reproduce the segfault. If you use the relational syntax, it coerces the non-temporal variable into a temporal variable and works correctly.

The newer algebraic syntax apparently overlooked the need to coerce non-temporal variables when combined with temporal variables.

Paul

On 02/22/15 03:48 PM, miatauro-NASA wrote:

I added a test case for this in 39bd6b9 https://github.com/nasa/europa/commit/39bd6b97ec9b19c715b562c6cc20e2ab089812a7, but it doesn't seem to reproduce the problem. Closing this for the moment.

� Reply to this email directly or view it on GitHub https://github.com/nasa/europa/issues/74#issuecomment-75472718.

miatauro-NASA commented 9 years ago

Aha! I'll reopen.

miatauro-NASA commented 9 years ago

I haven't checked in the tests yet, but I've tried a few additional ways of reproducing this and I believe it's fixed. Looking at Axel's original post that you linked, I think the Windows libraries were being used, which may be well out of date at this point.