| Index: third_party/WebKit/Tools/Scripts/webkitpy/layout_tests/port/factory.py
|
| diff --git a/third_party/WebKit/Tools/Scripts/webkitpy/layout_tests/port/factory.py b/third_party/WebKit/Tools/Scripts/webkitpy/layout_tests/port/factory.py
|
| index 95d2454f0563cfe69dc3b63507292284845ea823..05d7bc33febb580903b5f266e3de6d65f470dbcd 100644
|
| --- a/third_party/WebKit/Tools/Scripts/webkitpy/layout_tests/port/factory.py
|
| +++ b/third_party/WebKit/Tools/Scripts/webkitpy/layout_tests/port/factory.py
|
| @@ -31,6 +31,7 @@
|
| import fnmatch
|
| import optparse
|
| import re
|
| +import warnings
|
|
|
| from webkitpy.common.webkit_finder import WebKitFinder
|
|
|
| @@ -162,7 +163,12 @@ class PortFactory(object):
|
| else:
|
| for port_class in self.PORT_CLASSES:
|
| module_name, class_name = port_class.rsplit('.', 1)
|
| - module = __import__(module_name, globals(), locals(), [], -1)
|
| + try:
|
| + module = __import__(module_name, globals(), locals(), [], -1)
|
| + except ImportError as exp:
|
| + warnings.warn(
|
| + 'Unable to import %s (%s)' % (module_name, exp), stacklevel=2)
|
| + continue
|
| cls = module.__dict__[class_name]
|
| if port_name.startswith(cls.port_name):
|
| port_name = cls.determine_full_port_name(self._host, options, port_name)
|
|
|