Another issue with pylupdate6

Barry barry at barrys-emacs.org
Tue Jun 1 17:37:54 BST 2021



> On 29 May 2021, at 13:25, Detlev Offenbach <detlev at die-offenbachs.de> wrote:
> 
> Hello Phil,
> 
> I observed another issue with pylupdate6. It uses the system eol character(s) when writing the .ts file. This causes issues if you develop on different platforms (e.g. Linux and Windows) and use a version control system. When you re-generate a .ts file on a different platform, the VCS will see the whole file as changed because of different eols (e.g. \n versus \r\n) even if the contents remained the same. This is not good. Therefore I suggest that either no eol conversion is done (i.e. a \n is passed to the open() function) or a command line option is introduced to explicitly specify the eol sequence (e.g. --eol=\n or a more command line friendly form --eol=LF, --eol=CRLF, --eol=CR).

Typically I fix this with the native EOL feature of the source control system, git svn etc.

Barry

> 
> I don't know how pylupdate5 did it but I didn't observe the issue there (maybe I didn't generate .ts files of multiple platforms at all).
> 
> Detlev
> 
> -- 
> Detlev Offenbach
> detlev at die-offenbachs.de



More information about the PyQt mailing list