Space Engineers

Space Engineers

Automated Inventory Sorting
Corodius 12 Oct, 2014 @ 12:02pm
Mod stops working after indeterminate time
G'day mate, just posting this as you asked. The Log is actually really short, it did it after I was sat talking to the wife for a while after loading in, although it didn't happen for quite a while the time before.

http://pastebin.com/rTpXqei3

and from there is just stops working, until I exit and reload the world, obviously reloading the script.

I hope this helps. I don't know if the save is that useful, being as I cannot pin it down exactly, but if you still want it let me know.
< >
Showing 1-15 of 24 comments
tyrsis  [developer] 12 Oct, 2014 @ 9:03pm 
It is useful, thank you. It is actually very odd that it stops working for you when you get this error, as it should actually just sort of ignore the error. I will have an update out soon that will address this.
Corodius 13 Oct, 2014 @ 2:14am 
Ok, I have just had it happen again, and this time there is nothing in the log, only "moved this item there" lines.

http://pastebin.com/4r7aHHNE

So, I have no idea why it is stopping. :S
Coreinsanity 13 Oct, 2014 @ 6:24pm 
I just started getting this error as well. I'm going to see if I can reproduce it, though.
Coreinsanity 13 Oct, 2014 @ 6:36pm 
Ok, I'm actually able to reproduce that error in the log, but my sorting doesn't stop working when it happens:

[21:32:42] QueueTransferCargo: System.InvalidOperationException: Collection was modified; enumeration operation may not execute. at System.Collections.Generic.List`1.Enumerator.MoveNextRare() at System.Collections.Generic.List`1.Enumerator.MoveNext() at System.Linq.Enumerable.<OfTypeIterator>d__aa`1.MoveNext() at System.Collections.Generic.List`1..ctor(IEnumerable`1 collection) at System.Linq.Enumerable.ToList[TSource](IEnumerable`1 source) at SimpleInventorySort.Inventory.FindItemInInventory(IMyInventory inventory, MyDefinitionBase def, Int32& index, Int64& count) at SimpleInventorySort.Inventory.QueueTransferCargo(IMyInventory inventory, IMyInventory inventorySource, SortDefinitionItem item, List`1 compList)

I can't be 100% sure, but based on the error (plus I've done some C#) I decided to try stuff with moving the ore around. So, I had refineries chewing away at at some silicon ore, and started moving the stack it was getting the ore from between different containers labeled for ore. This error started showing up more a lot while doing that, then when I stop it stops showing up.

But again, it's not stopping when I get this, so not sure if this is going to help you all that much.

Edit: Also I have your debugging mode on this time, will post the log if it stops working again.
Last edited by Coreinsanity; 13 Oct, 2014 @ 6:38pm
tyrsis  [developer] 13 Oct, 2014 @ 8:33pm 
This error will occur sometimes. The problem is, it's supposed to gracefully continue. I will be putting out an update tonight that hopefully fixes it. The problem is I'm sort of in between versions, and don't want to release another feature I've been working on without testing it more. But I may just disable it to fix this current bug.
Last edited by tyrsis; 13 Oct, 2014 @ 8:34pm
Coreinsanity 14 Oct, 2014 @ 5:08am 
It's not really a huge inconvenience to me, honestly. I can just keep periodically watching it and restart. Can't speak for the OP, but I'd be fine waiting.
tyrsis  [developer] 14 Oct, 2014 @ 7:11am 
This should be updated in the new version. Tell me if it still stops working.
Coreinsanity 14 Oct, 2014 @ 7:24am 
Will do, I'll have to test it in a bit, but I will have a look.

Thanks for these updates btw!
Corodius 14 Oct, 2014 @ 9:52am 
Ok, I started up the game, left it sitting for a while as I just welded some stuff already in place (slightly moving my welder ship etc, but the script didn't need to do anything at that point). I then decided i'd try the sorting, and it had stopped.

The only line in the log this time is:

[02:02:50] Script Initialized: v0.1.0.7


I will reload the world and continue trying.
tyrsis  [developer] 14 Oct, 2014 @ 9:59am 
Can you type /sort debug and then let it run please
Coreinsanity 14 Oct, 2014 @ 4:43pm 
Well crap, it looks like it stopped working again, here's the log from it http://pastie.org/9648400

Would the world help you with this, or is it pretty much just a random bug?

Edit: One thing that comes to mind is the fact that I had a lot going on this time around, I had just gotten done mining a lot of ore, and it was doing a whole bunch of movement transactions. The actual log was pretty long for the last few hours, but that last bit is pretty much what was in it. It's been stopped for about 40 minutes at the time of posting, which is when I noticed it had stopped.
Last edited by Coreinsanity; 14 Oct, 2014 @ 4:48pm
tyrsis  [developer] 14 Oct, 2014 @ 5:37pm 
The top appears to be missing from the log? The first line should be script initialized
tyrsis  [developer] 14 Oct, 2014 @ 5:41pm 
Also, if you run into the issue again, can you please type /sort debug and let it run a bit to confirm it actually isn't running the sort at all.

I have one more thing I can try to do, which may be the issue. It will be in the next update.
Coreinsanity 14 Oct, 2014 @ 6:05pm 
Sorry, yeah I cut the top off - the whole log was about 5MB, and it's running the 0.1.0.7 (so you know it's updated)

It just happened again, and I have a theory. I'm going to try and reproduce it with the debug thing on (I forgot to turn it on this time -_-) - Edit: To clarify, it seems to happen after I mine, which lags the game pretty bad. So I'm going to restart, turn on debugging, and mine again)
Last edited by Coreinsanity; 14 Oct, 2014 @ 6:05pm
tyrsis  [developer] 14 Oct, 2014 @ 7:21pm 
There is actually a small area where something can occur that may actually stop the thread that's running the sort. I implemented a fix for it, but haven't fully tested a new feature I'm adding. Once the testing is completely, I will have a new version, that will hopefully ensure that the thread won't stop. It's quite odd that you're running into the issue though. I've run very long tests in maps with grids that have over 1000+ containers in them all trying to sort, and could never get it to stop.
< >
Showing 1-15 of 24 comments
Per page: 1530 50