Skip to content

Commit

Permalink
Python3: Replace usage of 'unicode' with 'six.text_type'
Browse files Browse the repository at this point in the history
  • Loading branch information
ziransun authored and jgraham committed Jan 22, 2020
1 parent 3e7db31 commit d86eb17
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions tools/wptrunner/wptrunner/executors/base.py
Original file line number Diff line number Diff line change
@@ -1,15 +1,16 @@
import base64
import hashlib
from six.moves.http_client import HTTPConnection
import io
import json
import os
import threading
import traceback
import socket
import sys
from six.moves.urllib.parse import urljoin, urlsplit, urlunsplit
from abc import ABCMeta, abstractmethod
from six import text_type
from six.moves.http_client import HTTPConnection
from six.moves.urllib.parse import urljoin, urlsplit, urlunsplit

from ..testrunner import Stop
from .protocol import Protocol, BaseProtocolPart
Expand Down Expand Up @@ -293,7 +294,7 @@ def result_from_exception(self, test, e):
status = e.status
else:
status = "INTERNAL-ERROR"
message = unicode(getattr(e, "message", ""))
message = text_type(getattr(e, "message", ""))
if message:
message += "\n"
message += traceback.format_exc(e)
Expand Down

0 comments on commit d86eb17

Please sign in to comment.