Closed MeesterDev closed 2 months ago
Good catch. It took me a hot minute to figure out what was going wrong - turns out it was a python-ism that I had forgotten about. I was "copying" a dictionary when specializing well recipes for each configuration, but I wasn't actually copying it, just aliasing it. Every time I specialized with a new well configuration, I was adding the satellite outputs to this single dictionary that was getting shared with every specialization of the recipe.
Adding . copy ()
to the end of that line fixes the problem. Fixed in commit d1e8eb46f01adbddb583a2cd7bfb261201c68833.
Nice job, thanks for the quick fix!
Hi, great job at implementing the changes for 1.0 so quickly!
I ran the 'the big cheese' example and noticed all well pressurizers get the same output, which is the total of all of them (for each of them).
Excerpt from the output:
I believe the output should be (assuming full extraction):
I'm executing
python .\satisfactory-optimizer.py .\examples\the_big_cheese.json --precision=8 > output.json
with Python 3.12.5 on Windows 10.If I were more skilled at Python I might have had a PR for you, but alas, I'm no good :')