Closed Bug 1528601 Opened 6 years ago Closed 6 years ago

Surface Python BytesWarnings and make them fail the tests

Categories

(Tree Management :: Treeherder, enhancement, P1)

enhancement

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: emorley, Assigned: emorley)

References

Details

Attachments

(1 file)

Python supports -b option that surfaces BytesWarnings, which are generated when comparisons are made between strings and bytes (typically indicating a bug). This can be upgraded to be an error by instead passing -bb.

We should enable these to catch invalid string<->bytes comparisons that would succeed under Python 2, but fail under Python 3.

See:
https://docs.python.org/3.6/using/cmdline.html#cmdoption-b
https://docs.python.org/3.6/library/exceptions.html#BytesWarning

Status: ASSIGNED → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
Component: Treeherder: Docs & Development → TreeHerder
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: