Scatter Plot View (Javascript) node produces error

Tried to create a scatter plot, however encountered error.

Have scanned thru’ the forum with the following common resolution suggestion, however didn’t work for me. Would really appreciate any advice.

"Solution: for Mac, select KNIME -> Preferences ->; KNIME -> JavaScript Views and set “Internal SWT Browser (not recommended)”

Error Message
ERROR Scatter Plot (JavaScript) 3:9 Initializing view failed: unexpected alert open
(Session info: headless chrome=67.0.3396.62)
(Driver info: chromedriver=2.40.565386 (45a059dc425e08165f9a10324bd1380cc13ca363),platform=Mac OS X 10.14.0 x86_64) (WARNING: The server did not provide any stacktrace information)
Command duration or timeout: 0 milliseconds: null
Build info: version: ‘unknown’, revision: ‘unknown’, time: ‘unknown’
System info: host: ‘iMac.local’, ip: ‘fe80:0:0:0:1814:fae7:e0a8:7319%en0’, os.name: ‘Mac OS X’, os.arch: ‘x86_64’, os.version: ‘10.14’, java.version: ‘1.8.0_152’
Driver info: org.openqa.selenium.chrome.ChromeDriver
Capabilities {acceptInsecureCerts: false, acceptSslCerts: false, applicationCacheEnabled: false, browserConnectionEnabled: false, browserName: chrome, chrome: {chromedriverVersion: 2.40.565386 (45a059dc425e08…, userDataDir: /private/var/folders/k8/t97…}, cssSelectorsEnabled: true, databaseEnabled: false, handlesAlerts: true, hasTouchScreen: false, javascriptEnabled: true, locationContextEnabled: true, mobileEmulationEnabled: false, nativeEvents: true, networkConnectionEnabled: false, pageLoadStrategy: normal, platform: MAC, platformName: MAC, rotatable: false, setWindowRect: true, takesHeapSnapshot: true, takesScreenshot: true, unexpectedAlertBehaviour: , unhandledPromptBehavior: , version: 67.0.3396.62, webStorageEnabled: true}
Session ID: fb924d6e797322b06d8c44eded1dba3b
*** Element info: {Using=css selector, value=body > *:not(#knime-service-header)}
ERROR Scatter Plot (JavaScript) 3:9 Retrieving image from view failed: Error retrieving image: Chrome driver was not initialized. Could not retrieve image.

Hi,

can you provide the KNIME version you are working with and your Operating System? This would help us analyse what the problem is.
In the meantime can you go to the configure dialog of the scatter plot and disable the image generation? After that the node should execute ok and hopefully when you open the view you can see the ‘unexpected alert’ with a better error message.

Hi,

Appreciate your prompt response.

KNIME version: 3.6.1
MacOS version 10.14 Mojave

I tired disabling image generation and has the following console output instead. The view image only show the Flow Variables.

WARN KNIMEApplication$4 Potential deadlock in AWT Event Queue detected. Full thread dump will follow as debug output.
WARN KNIMEApplication$3 Potential deadlock in SWT Display thread detected. Full thread dump will follow as debug output.
WARN KNIMEApplication$4 Potential deadlock in AWT Event Queue detected. Full thread dump will follow as debug output.
WARN KNIMEApplication$3 Potential deadlock in SWT Display thread detected. Full thread dump will follow as debug output.
WARN KNIMEApplication$4 Potential deadlock in AWT Event Queue detected. Full thread dump will follow as debug output.
WARN KNIMEApplication$3 Potential deadlock in SWT Display thread detected. Full thread dump will follow as debug output

If i turn back on image creation at output port, i will get attached:

When you disable the image generation, can you right click the node and select ‘Execute & Open View’? This should bring up the actual view window, hopefully with the erroneous alert popping up. For this the browser should be set to ‘Bundled Chromium’ again.

If this doesn’t work you can try something else. Navigate to your KNIME application (probably /Applications/KNIME 3.6.1.app) then right click and select ‘Show Package Contents’ then navigate to Contents/Eclipse/plugins/org.knime.ext.chromium.bin.macosx.x86_64_67.0.3396.v201806150845/macosx/x86_64. In this folder there should be a Chromium.app. Can you launch this app without error?

This actually worked! The Image and Chromium app executed, showing the scatter plot as expected.

Do I need to be concern with the fact that I can’t launch chromium with image generation enabled?

Yes, there is still something unexpected going on. If you don’t need the image from the outport you can of course keep that option turned off. But you might need it for something else in the future.
If you go to your Preferences->KNIME->JavaScript Views page. On the second block for the headless browser can you add ‘–disable-gpu’ in the additional command line arguments and try to re-execute the node with the image generation turned on?

Yes this works.

Appreciate the prompt help.

I have this problem and the proposed solutions didn’t help. This is what I set for javascript view

When I change to bundle chromium browser, I got this error.

**** Element info: {Using=css selector, value=body > :not(#knime-service-header)}
ERROR Scatter Plot (JavaScript) 4:3 Retrieving image from view failed: Error retrieving image: Chrome driver was not initialized. Could not retrieve image.
ERROR Scatter Plot (JavaScript) 4:3 NodeView.modelChanged() causes an error during notification of a changed model, reason: no such window: target window already closed
from unknown error: web view not found

  • (Session info: chrome=70.0.3538.77)*
  • (Driver info: chromedriver=2.43.600229 (3fae4d0cda5334b4f533bede5a4787f7b832d052),platform=Mac OS X 10.12.6 x86_64) (WARNING: The server did not provide any stacktrace information)*
    Command duration or timeout: 0 milliseconds
    Build info: version: ‘unknown’, revision: ‘unknown’, time: ‘unknown’
    System info: host: ‘Amizas-MacBook-Pro.local’, ip: ‘fe80:0:0:0:10f6:95e6:dc4:57ed%en0’, os.name: ‘Mac OS X’, os.arch: ‘x86_64’, os.version: ‘10.12.6’, java.version: ‘1.8.0_152’
    Driver info: org.openqa.selenium.chrome.ChromeDriver
    Capabilities {acceptInsecureCerts: false, acceptSslCerts: false, applicationCacheEnabled: false, browserConnectionEnabled: false, browserName: chrome, chrome: {chromedriverVersion: 2.43.600229 (3fae4d0cda5334…, userDataDir: /private/var/folders/47/rgg…}, cssSelectorsEnabled: true, databaseEnabled: false, goog:chromeOptions: {debuggerAddress: localhost:58187}, handlesAlerts: true, hasTouchScreen: false, javascriptEnabled: true, locationContextEnabled: true, mobileEmulationEnabled: false, nativeEvents: true, networkConnectionEnabled: false, pageLoadStrategy: normal, platform: MAC, platformName: MAC, rotatable: false, setWindowRect: true, takesHeapSnapshot: true, takesScreenshot: true, unexpectedAlertBehaviour: , unhandledPromptBehavior: , version: 70.0.3538.77, webStorageEnabled: true}
    Session ID: 74d15ab0e9abec72dbfc976c30253c6e