Page MenuHomePhabricator

[clang-format] ensure works with Python3 correctly

Authored by MyDeveloperDay on May 4 2020, 6:20 AM.



Python2 has been removed from cygwin, this means anyone running the in a cygwin shell could pick up python3 instead

In Python3 all strings are unicode as the file is opened in binary mode we need to encode the contents string or we'll face the following error

Traceback (most recent call last):
  File "./", line 228, in <module>
TypeError: a bytes-like object is required, not 'str'

Diff Detail

Event Timeline

MyDeveloperDay created this revision.May 4 2020, 6:20 AM
krasimir accepted this revision.May 7 2020, 7:21 AM
This revision is now accepted and ready to land.May 7 2020, 7:21 AM
This revision was automatically updated to reflect the committed changes.