[1.0.0] Mod doesn't sync with save properly if the mod acquired new dependencies

We are aware of them, but they have low priority. We have more important things to do. They go here in order not to take space in the main bug thread list.
Post Reply
curiosity
Filter Inserter
Filter Inserter
Posts: 322
Joined: Wed Sep 11, 2019 4:13 pm
Contact:

[1.0.0] Mod doesn't sync with save properly if the mod acquired new dependencies

Post by curiosity »

Steps to reproduce:
1. Make an installation of the game with attached mods (truncated for size) and save.
2. Start the game, ensure that all mods are disabled. Sync mods with save.
3. Observe that Factory Planner isn't loaded.
4. Sync mods with save again. Note that it offers to download Factory Planner.
5. Observe that Factory Planner still isn't loaded.

I believe, this happens because Factory Planner started requiring flib, which I already have in my mods disabled. The game enables Factory Planner, but doesn't check any dependencies. You can see that the mod is red in the mod manager.

I would have expected the game to enable any required dependencies when enabling mods, same as it happens when you enable a mod manually.
Attachments
mods.zip
(601.27 KiB) Downloaded 119 times
seablock.zip
(5.24 MiB) Downloaded 108 times

User avatar
Impatient
Filter Inserter
Filter Inserter
Posts: 883
Joined: Sun Mar 20, 2016 2:51 am
Contact:

Re: [1.0.0] Mod doesn't sync with save properly if the mod acquired new dependencies

Post by Impatient »

I just ran into the same issue and can confirm it.

I may have easier steps to reproduce:

1. Make a new savegame with mod "Picker Dollies" and mod "Factorio Standard Library" enabled.
2. Disable mod "Factorio Standard Library" -> Restart
3. Click sync mods with save on the created savegame.

Notice that mod "Picker Dollies" is listed as "Ready to download", although what it needs is it's dependency, mod "Factorio Standard Library", to be met by activating it.

Rseding91
Factorio Staff
Factorio Staff
Posts: 13201
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: [1.0.0] Mod doesn't sync with save properly if the mod acquired new dependencies

Post by Rseding91 »

I know why this happens but "solving" it is one of the biggest annoyances in the downloading mods logic. It basically has to recursively download info about each mod and its dependencies until it stops having more or it recourses back onto an already downloaded mod. If the 2nd happens then the whole thing just blows up and fails.

There's no nice solution to it. Maybe making sync-mods-with-save download the specific version that was in the save to prevent it...
If you want to get ahold of me I'm almost always on Discord.

vicarion
Burner Inserter
Burner Inserter
Posts: 13
Joined: Thu Aug 11, 2016 1:46 am
Contact:

Re: [1.0.0] Mod doesn't sync with save properly if the mod acquired new dependencies

Post by vicarion »

Could this be mitigated by setting a (very low) maximum recursion depth? Like 2 or 3.

User avatar
ptx0
Smart Inserter
Smart Inserter
Posts: 1507
Joined: Wed Jan 01, 2020 7:16 pm
Contact:

Re: [1.0.0] Mod doesn't sync with save properly if the mod acquired new dependencies

Post by ptx0 »

Rseding91 wrote:
Wed Oct 21, 2020 8:16 pm
It basically has to recursively download info about each mod and its dependencies until it stops having more or it recourses back onto an already downloaded mod. If the 2nd happens then the whole thing just blows up and fails.
i don't see how there's no nice solution to this. surely you're aware that things like Portage for Gentoo Linux have dependency tracking, and that it's considered a solved problem?

User avatar
eradicator
Smart Inserter
Smart Inserter
Posts: 5206
Joined: Tue Jul 12, 2016 9:03 am
Contact:

Re: [1.0.0] Mod doesn't sync with save properly if the mod acquired new dependencies

Post by eradicator »

Rseding91 wrote:
Wed Oct 21, 2020 8:16 pm
Maybe making sync-mods-with-save download the specific version that was in the save
That would generally be a benefitial feature.
Author of: Belt Planner, Hand Crank Generator, Screenshot Maker, /sudo and more.
Mod support languages: 日本語, Deutsch, English
My code in the post above is dedicated to the public domain under CC0.

curiosity
Filter Inserter
Filter Inserter
Posts: 322
Joined: Wed Sep 11, 2019 4:13 pm
Contact:

Re: [1.0.0] Mod doesn't sync with save properly if the mod acquired new dependencies

Post by curiosity »

Rseding91 wrote:
Wed Oct 21, 2020 8:16 pm
Maybe making sync-mods-with-save download the specific version that was in the save to prevent it...
I just thought of an issue with this. Some authors absolutely love to delete old versions, so the version may not exist and then you are back to square one.

User avatar
KiwiHawk
Filter Inserter
Filter Inserter
Posts: 254
Joined: Thu Jul 05, 2018 9:48 am
Contact:

Re: [1.0.0] Mod doesn't sync with save properly if the mod acquired new dependencies

Post by KiwiHawk »

Rseding91 wrote:
Wed Oct 21, 2020 8:16 pm
Maybe making sync-mods-with-save download the specific version that was in the save to prevent it...
This would be ideal for Sea Block! Would make it much easier to switch back to it after playing with other mods
Dev for Bob's mods, Angel's mods, Helmod, Sea Block, Circuit Processing, Science Cost Tweaker.

Buy me a coffee

Post Reply

Return to “Minor issues”