The other fix for this was to leave the mode as bytes, and import
pycompat.open() like a bunch of other modules do. But I think it's confusing
to still use bytes at the python boundary, and obviously error prone. Grepping
for open\(.+, ['"][a-z]+['"]\) and open\(.+, b['"][a-z]+['"]\) outside of
tests, there are 51 and 87 uses respectively, so it's not like this is a rare
direct usage.
Details
Details
- Reviewers
pulkit durin42 - Group Reviewers
hg-reviewers - Commits
- rHG234001d22ba6: lfs: use str for the open() mode when opening a blob for py3
Diff Detail
Diff Detail
- Repository
- rHG Mercurial
- Branch
- default
- Lint
No Linters Available - Unit
No Unit Test Coverage
Event Timeline
Comment Actions
Forgot to say: I'd be a big fan of unwinding pycompat.open() now that we're done with the module transformer.