Single-line serialisation of arrays causes many git conflicts #12249
Closed
wjt
started this conversation in
Engine Core
Replies: 2 comments 2 replies
-
Related: |
Beta Was this translation helpful? Give feedback.
2 replies
-
Thanks for the proposal! Consolidating in #9774. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Currently, arrays are serialised to .tres files on a single line. In particular, in
project.godot
(which I'm pretty sure is parsed as a resource file),locale/translations_pot_files
is aPackedStringArray
, all on one line.This is basically guaranteed to cause conflicts when two developers each add a new translatable file in parallel branches, and the resulting diff is hard to read. In our project, we are using Godot Dialogue Manager, which automatically appends dialogue files to this array – this is causing frequent conflicts even with just a few developers.
If arrays were serialised with one element per line, rather than all on one line, it would make diffs more readable, and conflicts less likely (and easier to resolve), at the cost of one byte (the newline) per array element. IMO this trade-off would be worth it.
Beta Was this translation helpful? Give feedback.
All reactions