So - what "screen" are they talking about?
My exception looks like this:
File "/lib/python2.7/site-packages/selenium/webdriver/remote/errorhandler.py", line 192, in check_response
raise exception_class(message, screen, stacktrace)
WebDriverException: Message: {"errorMessage":"Refused to evaluate a string as JavaScript because 'unsafe-eval' is not an allowed source of script in the following Content Security Policy directive: \"script-src 'self' connect.facebook.net cdn.ravenjs.com www.google-analytics.com banhang.shopee.vn chat.shopee.vn cdn.shopee.vn\".\n","request":{"objectName":"","statusCode":200,"headers":{"Cache":"no-cache","Content-Type":"application/json;charset=UTF-8"}}}
Screenshot: available via screen
Take a look at the line: raise exception_class(message, screen, stacktrace)
, so the screen
here means the variable screen
:
>>> screen
u'iVBORw0KGgoAAAANSUhEUgAABVYAAAMACAYAAADPPjzCAAAACXBIWXMAAAsTAAALEwEAmpwYAAAgAElE ...'
I don't know a quick way to show the screenshot, but screen
looks like the image data that you can save to a file then view it.