EinEinfach / CaSSAndRA

Cascaded sunray server and rover application
MIT License
29 stars 17 forks source link

finish and save after "move points" edit sometimes resets to old map #83

Closed disaster123 closed 1 year ago

disaster123 commented 1 year ago

Hi,

i was extensively using the move points function today. And pretty often (2 out of 10 times) finish and save resets to the old map and i've to redone the work.

EinEinfach commented 1 year ago

If you leaving "move points" mode? Or if you save changed map?

disaster123 commented 1 year ago

If I try to save changed map - it sometimes resets to original map just before pressing save button

EinEinfach commented 1 year ago

But you left move points mode before save?

disaster123 commented 1 year ago

Yes I did

EinEinfach commented 1 year ago

I don't know why but I will check that

disaster123 commented 1 year ago

It looks like a race condition like it reloads the original map just before clicking save

EinEinfach commented 1 year ago

I activate interval update after leaving moving mode, maybe it comes faster then reshaping made changes

EinEinfach commented 1 year ago

I tried to locate the problem, but I didn't find any issues in logic behavior. Do you have a log file from your session?

EinEinfach commented 1 year ago

I have another idea why this could happen. If an invalid polygon is created during the point movement (e.g., lines crossing over each other), then the change is discarded and reverted to the original polygon. But this is not a bug.

disaster123 commented 1 year ago

OK - i'm going to try to reproduce it and i'm going to close this issue right now. Thanks a lot!

ShadedSelf commented 1 year ago

Same here, the moment save and finish is clicked the perimeter goes back to the way it was. It only works if there is no perimeter selected on the select map popup.

EinEinfach commented 1 year ago

With last commit it shouldn't be happen anymore

ShadedSelf commented 1 year ago

Im on master, log doesnt say anything either

EinEinfach commented 1 year ago

What do you exactly do?

ShadedSelf commented 1 year ago

Then while the popup to set a name is active you can see the perimeter reverting itself to how it was before the changes, if you dont do step 2 it works as expected.

EinEinfach commented 1 year ago

try now

ShadedSelf commented 1 year ago

Yup, seems fixed now.

EinEinfach commented 1 year ago

Some callbacks I'll never understand