| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
… tests To test the `errors` argument, we read a UTF-16 file as UTF-8 with "backslashreplace" error handling. However, the utf-16 codec adds an endian-specific byte-order mark, so on big-endian machines the expectation doesn't match the test file (which was saved on a little-endian machine). Use endswith to ignore the BOM.
|
!buildbot s390x |
Sorry, something went wrong.
|
🤖 New build scheduled with the buildbot fleet by @encukou for commit 26ae210 🤖 The command will test the builders whose names match following regular expression: s390x The builders matched are:
|
Sorry, something went wrong.
|
@encukou Out of interest, was the endswith necessary? I thought using utf-16-le would strip the BOM automatically, and the issue you were hitting is that utf-16-be (implied by utf-16 on BE machines) was rejecting it. Explicitly specifying -le should have worked, I'd thought. |
Sorry, something went wrong.
… tests (pythonGH-117569) pythongh-116609: Ignore UTF-16 BOM in importlib.resources._functional tests To test the `errors` argument, we read a UTF-16 file as UTF-8 with "backslashreplace" error handling. However, the utf-16 codec adds an endian-specific byte-order mark, so on big-endian machines the expectation doesn't match the test file (which was saved on a little-endian machine). Use endswith to ignore the BOM.
|
This change needs to be applied to importlib_resources. It looks like a related issue was reported in python/importlib_resources#312. |
Sorry, something went wrong.
Closes #312. Closes #313. Ref python/cpython#117569
| Back | FazBrowse Home | New Git URL |
To test the errors argument, we read a UTF-16 file as UTF-8 with "backslashreplace" error handling. However, the utf-16 codec adds an endian-specific byte-order mark, so on big-endian machines the expectation doesn't match the test file (which was saved on a little-endian machine).
Use endswith to ignore the BOM.