Throughout Factorio versions. *ZIP Archives cause ERRORS!*

Bugs that are actually features.
Post Reply
User avatar
darkshadow1809
Filter Inserter
Filter Inserter
Posts: 306
Joined: Thu Jan 15, 2015 10:13 pm
Contact:

Throughout Factorio versions. *ZIP Archives cause ERRORS!*

Post by darkshadow1809 »

Found the issue! <----------- With solution!

After making my own mod. And loading everything up (In a folder) Everything works just fine!

BUT NOW! I zipped it up into an archive dragged it into my game and BAM

*Name*.png could not be found/loaded!

Wait what? How.. it loaded up fine. Just one mod in my mods folder? ... What gone wrong zipping it?


Nope all files there! checked if PNG was there yes it was... WHY wasnt it reading it!? what the hell!?

OH wait... Worm-glaides.png... Oh its named worm-glaides.png ... ? without capital? WHY didnt it pick it up as an error unzipped!?

Well thats where i had no idea. Just renaming the PNG file WITH the capital made it work and the mod loaded up fine. But some of my PNG's dont have capitals either and they load aswell.. WHAT!?



:P So now i am definitely sure its something to do with factorio's way of loading zip archives.




====================================================================================================


First post: Throughout whole factorio. It does not seem to be fixed yet. Loading a huge amounts of mods causes a sprite error for some machines, Or so called entity/prototype errors which it couldnt seem to find or load.

This is caused by the ZIP archive format presumably. Now the weird thing is turning down your graphics settings to low in factorio solves it. Then ofcourse put the modpack back to let it load. Then it will load fine.

Even funnier solution is simple unzipping the zip archive and putting the mod in its original folder. This also allows everything to load up normally. For anyone who doesnt really understand it yet. In my F.A.Q

https://forums.factorio.com/forum/vie ... =60&t=9398

Is a whole discussion about this issue. Which led to hours of figuring out why. Such a simple fix though.

https://forums.factorio.com/forum/vie ... 8&start=70
Here is the latest complaint for OSX and this has NOTHING to do with the mod owners code! Trust me i checked :) !

https://forums.factorio.com/forum/vie ... 8&start=30
Also sprite errors occuring here! With dytech even. It always seems to work on my version! However the others who download my pack get this issue. Same exact pack! same way installed. Its weird. It just does this on some setups and for some people theres no problem at all.

Hope this gets fixed in the newer factorio version as i am almost sure its the game or something to do with the way mods get archived.

Thanks in advance!
Last edited by darkshadow1809 on Mon May 04, 2015 5:28 am, edited 3 times in total.
ShadowsModpackDevelopment

orzelek
Smart Inserter
Smart Inserter
Posts: 3911
Joined: Fri Apr 03, 2015 10:20 am
Contact:

Re: Throughout Factorio versions.

Post by orzelek »

I think that this one might be simply a problem with error reporting in most cases.
There is only as much V-RAM on hand and Factorio likes to eat it up. Your environment might also affect this so it will not show up at every time potentially if you are close to full V-RAM with game loaded.

I have no idea why unzipping the mod would help in some cases tho :D

(Haven't had any of those - but game does eat up about 1.5-1.7 GB video memory with Shadow's mod pack on normal for me).

User avatar
darkshadow1809
Filter Inserter
Filter Inserter
Posts: 306
Joined: Thu Jan 15, 2015 10:13 pm
Contact:

Re: Throughout Factorio versions.

Post by darkshadow1809 »

orzelek wrote:I think that this one might be simply a problem with error reporting in most cases.
There is only as much V-RAM on hand and Factorio likes to eat it up. Your environment might also affect this so it will not show up at every time potentially if you are close to full V-RAM with game loaded.

I have no idea why unzipping the mod would help in some cases tho :D

(Haven't had any of those - but game does eat up about 1.5-1.7 GB video memory with Shadow's mod pack on normal for me).
Seems weird. As in my case i tested this with a 1gb Vram card. (even 512MB) game ran on 16-30 FPS but no crashes or anything.. Only on one hand my processor is going 30% or so. just for game requirements on a CPU @ 4,6 GH'z

As my main computer runs the game way above 60.
My mac runs it at way above 60 aswell (1gb vcard)
and laptop OLD laptop 512MB vcard just for testing runs at 16 fps - 30 fps or so but still no errors in any case whatsoever and if anyone has this issue simply unzipping the mod works for them. So its really not a Vram issue in this case. No clue why this game would even take 1.7 GB of V-ram anyway? Might be due to alot of mods but still 1.7 GB is QUITE high. :D
ShadowsModpackDevelopment

orzelek
Smart Inserter
Smart Inserter
Posts: 3911
Joined: Fri Apr 03, 2015 10:20 am
Contact:

Re: Throughout Factorio versions.

Post by orzelek »

It might depend on game settings - if it loads all textures or not.

Atlas for base game is: 16384x6555 (about 409MB plus overhead).
Atlas with modpack is: 16384x16377 plus 16384x2839 (nets about 1201MB plus overhead).
(assumption: texture is full RGBA 32bpp)

Thats when you use textures on normal and video memory usage on all. You can check that easily in game logs.

User avatar
darkshadow1809
Filter Inserter
Filter Inserter
Posts: 306
Joined: Thu Jan 15, 2015 10:13 pm
Contact:

Re: Throughout Factorio versions.

Post by darkshadow1809 »

Found the issue!

After making my own mod. And loading everything up (In a folder) Everything works just fine!

BUT NOW! I zipped it up into an archive dragged it into my game and BAM

*Name*.png could not be found/loaded!

Wait what? How.. it loaded up fine. Just one mod in my mods folder? ... What gone wrong zipping it?


Nope all files there! checked if PNG was there yes it was... WHY wasnt it reading it!? what the hell!?

OH wait... Worm-glaides.png... Oh its named worm-glaides.png ... ? without capital? WHY didnt it pick it up as an error unzipped!?

Well thats where i had no idea. Just renaming the PNG file WITH the capital made it work and the mod loaded up fine. But some of my PNG's dont have capitals either and they load aswell.. WHAT!?



:P So now i am definitely sure its something to do with factorio's way of loading zip archives.
ShadowsModpackDevelopment

sillyfly
Smart Inserter
Smart Inserter
Posts: 1099
Joined: Sun May 04, 2014 11:29 am
Contact:

Re: Throughout Factorio versions. *ZIP Archives cause ERRORS!*

Post by sillyfly »

I believe the problem comes from the fact that old Windows filesystems (FAT16, FAT32 etc.) were case insensitive. Modern Windows filesystems (NTFS) are indeed case sensitive, but many Windows functionalies are still case insensitive. That means that on Windows systems, Boost (the library used in Factorio for file system io) will be case insensitive when searching for files. I can only assume that the library used for ZIP reading is fully case-sensitive.

So the problem is actually that some mods are careless of the capitalization of some files, but the problem is only apparent on Linux or Mac, and in Windows it only appears when using ZIP files.

User avatar
darkshadow1809
Filter Inserter
Filter Inserter
Posts: 306
Joined: Thu Jan 15, 2015 10:13 pm
Contact:

Re: Throughout Factorio versions. *ZIP Archives cause ERRORS!*

Post by darkshadow1809 »

sillyfly wrote:I believe the problem comes from the fact that old Windows filesystems (FAT16, FAT32 etc.) were case insensitive. Modern Windows filesystems (NTFS) are indeed case sensitive, but many Windows functionalies are still case insensitive. That means that on Windows systems, Boost (the library used in Factorio for file system io) will be case insensitive when searching for files. I can only assume that the library used for ZIP reading is fully case-sensitive.

So the problem is actually that some mods are careless of the capitalization of some files, but the problem is only apparent on Linux or Mac, and in Windows it only appears when using ZIP files.

Maybe the factorio devs will fix this? If at all possible? Maybe make a different way of loading the mods? Who knows:P Kovarex always seems to fix quite the impossible bugs :D
ShadowsModpackDevelopment

sillyfly
Smart Inserter
Smart Inserter
Posts: 1099
Joined: Sun May 04, 2014 11:29 am
Contact:

Re: Throughout Factorio versions. *ZIP Archives cause ERRORS!*

Post by sillyfly »

I don't know if it will be possible, if I am even right - I am only guessing :)
Better wait for one of the dev's for a conclusive answer.

dee-
Filter Inserter
Filter Inserter
Posts: 416
Joined: Mon Jan 19, 2015 9:21 am
Contact:

Re: Throughout Factorio versions. *ZIP Archives cause ERRORS!*

Post by dee- »

Better do it the right way and fix the cause: the casing of the file, not the symptom: the loader.
Your mod WILL break on *nix systems because the mod is broken.

User avatar
ssilk
Global Moderator
Global Moderator
Posts: 12888
Joined: Tue Apr 16, 2013 10:35 pm
Contact:

Re: Throughout Factorio versions. *ZIP Archives cause ERRORS!*

Post by ssilk »

There are several solutions. The same kind of problems are, when you use upper-lower case in some database-engines (mysql is very famous for that and they added some modes to handle it), anyone, who created web-pages on windows and moved it to a linux-server knows it. :) The trend goes definitely to a discrete handling of upper/lower case filenames.

a) There should be something, that checks the filenames. Factorio could have a mode, where it checks explicitely for that.
b) A "mod-checker", that checks for this case. Could be paired with a mod-platform, where you can download mods.
Cool suggestion: Eatable MOUSE-pointers.
Have you used the Advanced Search today?
Need help, question? FAQ - Wiki - Forum help
I still like small signatures...

User avatar
darkshadow1809
Filter Inserter
Filter Inserter
Posts: 306
Joined: Thu Jan 15, 2015 10:13 pm
Contact:

Re: Throughout Factorio versions. *ZIP Archives cause ERRORS!*

Post by darkshadow1809 »

ssilk wrote:There are several solutions. The same kind of problems are, when you use upper-lower case in some database-engines (mysql is very famous for that and they added some modes to handle it), anyone, who created web-pages on windows and moved it to a linux-server knows it. :) The trend goes definitely to a discrete handling of upper/lower case filenames.

a) There should be something, that checks the filenames. Factorio could have a mode, where it checks explicitely for that.
b) A "mod-checker", that checks for this case. Could be paired with a mod-platform, where you can download mods.
Yeh i would very much like the A) system.

As i am new to lua I do run in to some problems. Errors that are way to unclear to read. Atleast for me I don't know for others but people that might already have this issue ofcourse know a fix :) But sometimes like an assignID error. It doesnt tell you where it is located. Or in multiple locations. It's a big hassle to detect where exactly you put your typo. Maybe factorio can have a somewhat more intelligent error finder? To prevent these kind of mistakes? Or typos. So to say :) ? Would be amazing!
ShadowsModpackDevelopment

orzelek
Smart Inserter
Smart Inserter
Posts: 3911
Joined: Fri Apr 03, 2015 10:20 am
Contact:

Re: Throughout Factorio versions. *ZIP Archives cause ERRORS!*

Post by orzelek »

I haven't had problems with lua errors... it's a typical compiler error reporting. I'm not sure how viable it would be to improve upon those - most of them are reported by lua compiler and thats an external module probably.
Thats not to say that compiler errors are always sensible - you get used to it after some time.

User avatar
bobingabout
Smart Inserter
Smart Inserter
Posts: 7352
Joined: Fri May 09, 2014 1:01 pm
Contact:

Re: Throughout Factorio versions. *ZIP Archives cause ERRORS!*

Post by bobingabout »

Looking at the original issue...

The game is case sensative, Windows is not.

The fact that it worked with Worm instead of worm is the bug, a windows specific bug.

if you tried the same thing on Linux, you'd get the same error even unzipped as you did when it was zipped on windows.


The solution is NOT to fix the game to work with the lazy, spoiled windows user, but to kick the windows user in the butt and tell him to learn the meaning of case sensativity, and name the file properly.
Creator of Bob's mods. Expanding your gameplay since version 0.9.8.
I also have a Patreon.

User avatar
ssilk
Global Moderator
Global Moderator
Posts: 12888
Joined: Tue Apr 16, 2013 10:35 pm
Contact:

Re: Throughout Factorio versions. *ZIP Archives cause ERRORS!*

Post by ssilk »

bobingabout wrote:The game is case sensative, Windows is not.
To exact: As I understand it, it is not Windows, it's the used filesystem.
If you use a case-insensitive filesystem under linux you will have the same issue, that you don't see a difference between upper/lower-case.

And the bug is not that. The bug is, that it can't be seen by those, which create that issue. Or that Factorio doesn't try to look for files case-insensitive. Depends on standpoint. :)
Cool suggestion: Eatable MOUSE-pointers.
Have you used the Advanced Search today?
Need help, question? FAQ - Wiki - Forum help
I still like small signatures...

dee-
Filter Inserter
Filter Inserter
Posts: 416
Joined: Mon Jan 19, 2015 9:21 am
Contact:

Re: Throughout Factorio versions. *ZIP Archives cause ERRORS!*

Post by dee- »

ssilk wrote:
bobingabout wrote:The game is case sensative, Windows is not.
To exact: As I understand it, it is not Windows, it's the used filesystem.
If you use a case-insensitive filesystem under linux you will have the same issue, that you don't see a difference between upper/lower-case.

And the bug is not that. The bug is, that it can't be seen by those, which create that issue. Or that Factorio doesn't try to look for files case-insensitive. Depends on standpoint. :)
The filesystem NTFS is case sensitive. It's the programs/OS API that is not on Windows.
The bug is relying on the case-insensitiveness, which is not in the responsiblity of factorio, and therefore a bug in any mod or program that relies on insensitiveness.
Making programs check for files insensitive when the filesystem and the OS all are is not only the wrong place for the sympthom fix but also dangerous and misleasing.
Standpoint ;)

Post Reply

Return to “Not a bug”