HilkopterBob / TA

Textadventure
GNU General Public License v3.0
2 stars 1 forks source link

File hashing on different platforms creates errors #125

Open HilkopterBob opened 7 months ago

HilkopterBob commented 7 months ago

Creating hashes for meta.conf on windows differes from hashes created on linux. See: https://stackoverflow.com/questions/23829553/different-hash-value-created-on-windows-linux-and-mac-for-same-image image

i dont think that there is a great solution for this, see stackoverflow issue.

Kartoffel096 commented 7 months ago

As suggest in stackoverflow issue we should ignore or change line endings so that the hashes are the same on different plattforms. Shouldn't be hard i guess. looking into this

Kartoffel096 commented 7 months ago

Issue reviewed: -> File Hashing differences shouldn't even arise because files are opened in binary mode Any Idea what else is causing this problem?

HilkopterBob commented 7 months ago

Try uploading Text file with no new line or a Binary file. Also check difference in bytes read. It should be equal to number of new lines in next file.

HilkopterBob commented 7 months ago

Maybe we could implement different sections inside the meta.conf to use different hashes for different platforms. This wouldn't need for deeper python-implementation specific debugging rather we would only need to make an if sys.os == platform: and duplicate the already existing data-hierarchy inside the meta.conf

Kartoffel096 commented 7 months ago

Affirmed -> Will work on this

HilkopterBob commented 4 months ago

partially mitigated with: #140