godot icon indicating copy to clipboard operation
godot copied to clipboard

[Buildsystem] Fix encoding when reading files

Open AThousandShips opened this issue 1 year ago • 3 comments

I added it to all cases with "r" I could find, didn't add it to "rb" as I assume those are read as binary and won't care about encoding, also there were some cases where there wasn't an explicit mode, left those, but if needed I'll add those too

See:

  • https://github.com/godotengine/godot/issues/88901#issuecomment-2016773120

AThousandShips avatar Mar 24 '24 17:03 AThousandShips

Would be good to find what caused the regression.

I assume maybe https://github.com/godotengine/godot/pull/89361 (cc @Repiteo).

akien-mga avatar Mar 24 '24 20:03 akien-mga

I'd sooner assume #89333 as a possible culprit, which added explicit utf8 encoding to unspecified writes.

Repiteo avatar Mar 24 '24 20:03 Repiteo

Agreed it seems to be the misalignment between reads and writes, unsure if we should instead remove enforcing it on either, but this solves at least the specific issue in the comment

AThousandShips avatar Mar 24 '24 21:03 AThousandShips

Thanks!

akien-mga avatar Mar 25 '24 10:03 akien-mga

Thank you!

AThousandShips avatar Mar 25 '24 10:03 AThousandShips