Page 1 of 1

[Rseding91] [16.24] Refineries don't empty their output, stay inactive indefinitely

Posted: Sat Feb 17, 2018 12:14 pm
by luc
In the attached save games, see the refineries doing coal liquefaction which are next to the player. There are 100 units of red/heavy oil stuck in the output, causing it to stop working. The output pipe is not full. I've tried reconnecting output pipes, but that does not work. Replacing the refinery works. If I remember correctly, the issue occurred again after placing some more refineries, but I don't have exact steps to reproduce. In the save, multiple refineries (but not all) are affected.

Re: [0.16.24] Refineries don't empty their output, causing them to stop working

Posted: Sat Feb 17, 2018 3:47 pm
by quyxkh
Coal liquefaction produces a surplus of heavy oil but you're not sending it anywhere so it backs up, the refineries stop requesting input and apparently the output valves wedge. The pipes are >90% full, it's only a matter of seconds before that happens anyway. Crack the excess down to something usable, one max-boosted cracking plant keeps up with the surplus in that map. Adding one coal will wake the plants up again.

Re: [0.16.24] Refineries don't empty their output, causing them to stop working

Posted: Sat Feb 17, 2018 4:42 pm
by Loewchen
This is weird, should have no problem outputting it, maybe it can not because it is inactive, putting coal in it manually instantly lets it output the fluid. Evacuating the output pipes has no effect.

Re: [0.16.24] Refineries don't empty their output, causing them to stop working

Posted: Sun Feb 18, 2018 8:33 pm
by luc
Loewchen wrote:This is weird, should have no problem outputting it, maybe it can not because it is inactive, putting coal in it manually instantly lets it output the fluid. Evacuating the output pipes has no effect.
Inserters don't input if the output is full right? I was assuming that's the issue. But while output is full, the pipes are not, so there's the bug I'd say.
quyxkh wrote:The pipes are >90% full
But not too full to accept anymore fluids. It should be able to output and then request more input to make more oil. And replacing the refineries works, so I'm quite sure it's not because output is full.

As for cracking it down, yes I've done that since posting the save. (I was already doing it, but a pump was set to activate at >21k liquid in a tank (iirc) and I've lowered that activation point.)

Re: [16.24] Refineries don't empty their output, stay inactive indefinitely

Posted: Sun Feb 18, 2018 9:56 pm
by quyxkh
I think the plants might be shutting down because they produce more in a cycle than will fit in the pipe+buffer that tick, one cycle produces 35 heavy oil, so if there's not room for all 35 in the output buffers or maybe output buffers + 1 tick's worth of drain capacity in the pipes, the plant just shuts down. Unexpected, but I'd just be guessing whether it was intended.
luc wrote:I was already doing it
Yup, sorry for not being more worried I'd missed something, like maybe that northern route out. If you want to keep your main reserve closer to full there's
snap@T45944299=496x448-260.75+97.25,z2.jpg
snap@T45944299=496x448-260.75+97.25,z2.jpg (14.51 KiB) Viewed 1686 times
at the liquefaction exit to keep just the local pipes down to wha needs to be kept locally, anything>2050 seems to work well and it was an easy shift.

edit: perhaps the refinery starts the cycle when there's enough room in the buffer+pipe to hold the result, but the pipe fills up more during the cycle and the cycle can't finish, so instead of having to check every tick it just goes inactive?

Re: [Rseding91] [16.24] Refineries don't empty their output, stay inactive indefinitely

Posted: Wed Feb 21, 2018 1:40 pm
by Rseding91
Something weird is going on here. Did you use any console commands or mods that might have changed the entity to be active/inactive?

There's logic in place that says the machine can never go to sleep while it has fluid in the output pipes.

However as of writing this I now see that you migrated the save from 0.14 - was this refinery created after migrating to 0.16 or before? If before, then this is already fixed and this is a left over from the bug.

Re: [Rseding91] [16.24] Refineries don't empty their output, stay inactive indefinitely

Posted: Wed Feb 21, 2018 3:48 pm
by luc
Thanks for looking into it!

The save was indeed created long ago, but the refineries with the bug are not. I built them a few days ago: I think on 0.16.24, but at least 0.16.10+. The other refineries closer to the main base (doing normal oil processing, not coal liquefaction) were created much longer ago, but those work fine.

> Did you use any console commands or mods that might have changed the entity to be active/inactive?

Can you not see the history? I'm not sure how to view it, and I can't be certain of what I did over the past few years... all I remember is using things like game.speed, printing evolution (before /evolution was possible), and recently I created some more water for nuclear (I think I enabled the "water only in starting area" option, which was fine at the time, but now that we have nuclear...). I'm quite certain I never did anything regarding (de)activating entities (I didn't know active entities were a thing). And even if I used such a command, it would have been long before these entities existed.