org.eclipse.swt.SWTException: Invalid thread access

SpringSource Issue Tracker | Gunnar Hillert | 4 years ago
  1. 0

    Hunted down a nasty one. Let say I have a replacement key defined in *wizard.json* such as the following: {code} { "name" : "blubba", "description" : "Please enter a short version e.g. '1.0' (For JavaDoc, and XSD Schema Naming)", "defaultValue": "1.0", "type" : "java.lang.String", "page" : 0, "required" : true, } {code} In my actual project template project I have a file like this: {code} spring-integration-blubba.xsd {code} When I create a new project using this template, and I provide a value for *blubba* of *2.0* then I would expect the filename to be replaced correctly. HOWEVER, I get the following "explanatory" exception instead: *Exception Stack Trace:* {code} org.eclipse.swt.SWTException: Invalid thread access at org.eclipse.swt.SWT.error(SWT.java:4361) at org.eclipse.swt.SWT.error(SWT.java:4276) at org.eclipse.swt.SWT.error(SWT.java:4247) at org.eclipse.swt.widgets.Display.error(Display.java:1068) at org.eclipse.swt.widgets.Display.checkDevice(Display.java:621) at org.eclipse.swt.widgets.Display.getActiveShell(Display.java:1221) at org.springsource.ide.eclipse.commons.ui.UiUtil.getShell(UiUtil.java:95) at org.springsource.ide.eclipse.commons.ui.UiStatusHandler.logAndDisplay(UiStatusHandler.java:28) at org.springframework.ide.eclipse.wizard.template.infrastructure.processor.TemplateProjectCreator.unzipProject(TemplateProjectCreator.java:269) at org.springframework.ide.eclipse.wizard.template.infrastructure.processor.TemplateProjectCreator.createProject(TemplateProjectCreator.java:78) at org.springframework.ide.eclipse.wizard.template.infrastructure.processor.DirectoryProcessor.process(DirectoryProcessor.java:56) at org.springframework.ide.eclipse.wizard.template.infrastructure.processor.Processor.process(Processor.java:44) at org.springframework.ide.eclipse.wizard.template.TemplateWizard$1.run(TemplateWizard.java:114) at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:121) {code} *Session Data:* {code} eclipse.buildId=3.0.0.201208091018-RELEASE-e42 java.version=1.6.0_33 java.vendor=Apple Inc. BootLoader constants: OS=macosx, ARCH=x86_64, WS=cocoa, NL=en_US Framework arguments: -product org.springsource.sts.ide -keyring /Users/ghillert/.eclipse_keyring -showlocation Command-line arguments: -os macosx -ws cocoa -arch x86_64 -product org.springsource.sts.ide -keyring /Users/ghillert/.eclipse_keyring -showlocation {code} Interestingly, if I provide this value: *20* everything works perfectly. This is a fairly major issue as I have versioned XSD schema files that need to be handled correctly.

    SpringSource Issue Tracker | 4 years ago | Gunnar Hillert
    org.eclipse.swt.SWTException: Invalid thread access
  2. 0

    I have been working all day with STS Templates and I seem to be running into a series of nondescript exceptions. It is possible that the exceptions are raised as a mis-configuration on my end BUT they certainly must be more helpful. 1) I seem to get this intermittent issue on the Template Wizard page. I fill out the form fields and submitting the form does not do anything. The Wizard does not go away. For some strange reasons - I have a "bin" folder in my zip (some left-over from the build). I deleted it and it works. It looks like certain files (the way they are named???) may cause STS to choke. {code} org.eclipse.swt.SWTException: Invalid thread access at org.eclipse.swt.SWT.error(SWT.java:4361) at org.eclipse.swt.SWT.error(SWT.java:4276) at org.eclipse.swt.SWT.error(SWT.java:4247) at org.eclipse.swt.widgets.Display.error(Display.java:1068) at org.eclipse.swt.widgets.Display.checkDevice(Display.java:621) at org.eclipse.swt.widgets.Display.getActiveShell(Display.java:1221) at org.springsource.ide.eclipse.commons.ui.UiUtil.getShell(UiUtil.java:95) at org.springsource.ide.eclipse.commons.ui.UiStatusHandler.logAndDisplay(UiStatusHandler.java:28) at org.springframework.ide.eclipse.wizard.template.infrastructure.processor.TemplateProjectCreator.unzipProject(TemplateProjectCreator.java:269) at org.springframework.ide.eclipse.wizard.template.infrastructure.processor.TemplateProjectCreator.createProject(TemplateProjectCreator.java:78) at org.springframework.ide.eclipse.wizard.template.infrastructure.processor.DirectoryProcessor.process(DirectoryProcessor.java:56) at org.springframework.ide.eclipse.wizard.template.infrastructure.processor.Processor.process(Processor.java:44) at org.springframework.ide.eclipse.wizard.template.TemplateWizard$1.run(TemplateWizard.java:114) at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:121) {code} 2) I have also seen this exception - I selected the template but it is not downloading - related to STS-2686??: {code} java.lang.reflect.InvocationTargetException at org.springframework.ide.eclipse.wizard.template.TemplateSelectionWizardPage$7.run(TemplateSelectionWizardPage.java:417) at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:121) Caused by: org.eclipse.core.runtime.CoreException: Download of template 'org.springframework.integration.sts.template.adapter' failed at org.springframework.ide.eclipse.wizard.template.TemplateUtils.importDirectory(TemplateUtils.java:95) at org.springframework.ide.eclipse.wizard.template.TemplateUtils.importTemplate(TemplateUtils.java:154) at org.springframework.ide.eclipse.wizard.template.TemplateSelectionWizardPage$7.run(TemplateSelectionWizardPage.java:411) ... 1 more {code} Similar to https://issuetracker.springsource.com/browse/STS-2686 ???? 3) Lastly, I have also encountered this exception: {code} Message: Exception during template project creation Exception Stack Trace java.lang.NullPointerException at org.springframework.ide.eclipse.wizard.template.infrastructure.Template.getZippedLocation(Template.java:82) at org.springframework.ide.eclipse.wizard.template.TemplateSelectionWizardPage.getProjectLocation(TemplateSelectionWizardPage.java:519) at org.springframework.ide.eclipse.wizard.template.TemplateWizard$1.run(TemplateWizard.java:110) at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:121) Session Data: eclipse.buildId=3.0.0.201208091018-RELEASE-e42 java.version=1.6.0_33 java.vendor=Apple Inc. BootLoader constants: OS=macosx, ARCH=x86_64, WS=cocoa, NL=en_US Framework arguments: -product org.springsource.sts.ide -keyring /Users/ghillert/.eclipse_keyring -showlocation Command-line arguments: -os macosx -ws cocoa -arch x86_64 -product org.springsource.sts.ide -keyring /Users/ghillert/.eclipse_keyring -showlocation {code}

    SpringSource Issue Tracker | 4 years ago | Gunnar Hillert
    org.eclipse.swt.SWTException: Invalid thread access
  3. 0

    Hunted down a nasty one. Let say I have a replacement key defined in *wizard.json* such as the following: {code} { "name" : "blubba", "description" : "Please enter a short version e.g. '1.0' (For JavaDoc, and XSD Schema Naming)", "defaultValue": "1.0", "type" : "java.lang.String", "page" : 0, "required" : true, } {code} In my actual project template project I have a file like this: {code} spring-integration-blubba.xsd {code} When I create a new project using this template, and I provide a value for *blubba* of *2.0* then I would expect the filename to be replaced correctly. HOWEVER, I get the following "explanatory" exception instead: *Exception Stack Trace:* {code} org.eclipse.swt.SWTException: Invalid thread access at org.eclipse.swt.SWT.error(SWT.java:4361) at org.eclipse.swt.SWT.error(SWT.java:4276) at org.eclipse.swt.SWT.error(SWT.java:4247) at org.eclipse.swt.widgets.Display.error(Display.java:1068) at org.eclipse.swt.widgets.Display.checkDevice(Display.java:621) at org.eclipse.swt.widgets.Display.getActiveShell(Display.java:1221) at org.springsource.ide.eclipse.commons.ui.UiUtil.getShell(UiUtil.java:95) at org.springsource.ide.eclipse.commons.ui.UiStatusHandler.logAndDisplay(UiStatusHandler.java:28) at org.springframework.ide.eclipse.wizard.template.infrastructure.processor.TemplateProjectCreator.unzipProject(TemplateProjectCreator.java:269) at org.springframework.ide.eclipse.wizard.template.infrastructure.processor.TemplateProjectCreator.createProject(TemplateProjectCreator.java:78) at org.springframework.ide.eclipse.wizard.template.infrastructure.processor.DirectoryProcessor.process(DirectoryProcessor.java:56) at org.springframework.ide.eclipse.wizard.template.infrastructure.processor.Processor.process(Processor.java:44) at org.springframework.ide.eclipse.wizard.template.TemplateWizard$1.run(TemplateWizard.java:114) at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:121) {code} *Session Data:* {code} eclipse.buildId=3.0.0.201208091018-RELEASE-e42 java.version=1.6.0_33 java.vendor=Apple Inc. BootLoader constants: OS=macosx, ARCH=x86_64, WS=cocoa, NL=en_US Framework arguments: -product org.springsource.sts.ide -keyring /Users/ghillert/.eclipse_keyring -showlocation Command-line arguments: -os macosx -ws cocoa -arch x86_64 -product org.springsource.sts.ide -keyring /Users/ghillert/.eclipse_keyring -showlocation {code} Interestingly, if I provide this value: *20* everything works perfectly. This is a fairly major issue as I have versioned XSD schema files that need to be handled correctly.

    SpringSource Issue Tracker | 4 years ago | Gunnar Hillert
    org.eclipse.swt.SWTException: Invalid thread access
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    I have been working all day with STS Templates and I seem to be running into a series of nondescript exceptions. It is possible that the exceptions are raised as a mis-configuration on my end BUT they certainly must be more helpful. 1) I seem to get this intermittent issue on the Template Wizard page. I fill out the form fields and submitting the form does not do anything. The Wizard does not go away. For some strange reasons - I have a "bin" folder in my zip (some left-over from the build). I deleted it and it works. It looks like certain files (the way they are named???) may cause STS to choke. {code} org.eclipse.swt.SWTException: Invalid thread access at org.eclipse.swt.SWT.error(SWT.java:4361) at org.eclipse.swt.SWT.error(SWT.java:4276) at org.eclipse.swt.SWT.error(SWT.java:4247) at org.eclipse.swt.widgets.Display.error(Display.java:1068) at org.eclipse.swt.widgets.Display.checkDevice(Display.java:621) at org.eclipse.swt.widgets.Display.getActiveShell(Display.java:1221) at org.springsource.ide.eclipse.commons.ui.UiUtil.getShell(UiUtil.java:95) at org.springsource.ide.eclipse.commons.ui.UiStatusHandler.logAndDisplay(UiStatusHandler.java:28) at org.springframework.ide.eclipse.wizard.template.infrastructure.processor.TemplateProjectCreator.unzipProject(TemplateProjectCreator.java:269) at org.springframework.ide.eclipse.wizard.template.infrastructure.processor.TemplateProjectCreator.createProject(TemplateProjectCreator.java:78) at org.springframework.ide.eclipse.wizard.template.infrastructure.processor.DirectoryProcessor.process(DirectoryProcessor.java:56) at org.springframework.ide.eclipse.wizard.template.infrastructure.processor.Processor.process(Processor.java:44) at org.springframework.ide.eclipse.wizard.template.TemplateWizard$1.run(TemplateWizard.java:114) at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:121) {code} 2) I have also seen this exception - I selected the template but it is not downloading - related to STS-2686??: {code} java.lang.reflect.InvocationTargetException at org.springframework.ide.eclipse.wizard.template.TemplateSelectionWizardPage$7.run(TemplateSelectionWizardPage.java:417) at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:121) Caused by: org.eclipse.core.runtime.CoreException: Download of template 'org.springframework.integration.sts.template.adapter' failed at org.springframework.ide.eclipse.wizard.template.TemplateUtils.importDirectory(TemplateUtils.java:95) at org.springframework.ide.eclipse.wizard.template.TemplateUtils.importTemplate(TemplateUtils.java:154) at org.springframework.ide.eclipse.wizard.template.TemplateSelectionWizardPage$7.run(TemplateSelectionWizardPage.java:411) ... 1 more {code} Similar to https://issuetracker.springsource.com/browse/STS-2686 ???? 3) Lastly, I have also encountered this exception: {code} Message: Exception during template project creation Exception Stack Trace java.lang.NullPointerException at org.springframework.ide.eclipse.wizard.template.infrastructure.Template.getZippedLocation(Template.java:82) at org.springframework.ide.eclipse.wizard.template.TemplateSelectionWizardPage.getProjectLocation(TemplateSelectionWizardPage.java:519) at org.springframework.ide.eclipse.wizard.template.TemplateWizard$1.run(TemplateWizard.java:110) at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:121) Session Data: eclipse.buildId=3.0.0.201208091018-RELEASE-e42 java.version=1.6.0_33 java.vendor=Apple Inc. BootLoader constants: OS=macosx, ARCH=x86_64, WS=cocoa, NL=en_US Framework arguments: -product org.springsource.sts.ide -keyring /Users/ghillert/.eclipse_keyring -showlocation Command-line arguments: -os macosx -ws cocoa -arch x86_64 -product org.springsource.sts.ide -keyring /Users/ghillert/.eclipse_keyring -showlocation {code}

    SpringSource Issue Tracker | 4 years ago | Gunnar Hillert
    org.eclipse.swt.SWTException: Invalid thread access
  6. 0

    Software update raises SWTException: Invalid thread access

    Eclipse Bugzilla | 9 years ago | saimen54
    org.osgi.framework.BundleException: Exception in org.eclipse.update.internal.ui.UpdateUI.start() of bundle org.eclipse.update.ui.

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. org.eclipse.swt.SWTException

      Invalid thread access

      at org.eclipse.swt.SWT.error()
    2. RWT
      Display.getActiveShell
      1. org.eclipse.swt.SWT.error(SWT.java:4361)
      2. org.eclipse.swt.SWT.error(SWT.java:4276)
      3. org.eclipse.swt.SWT.error(SWT.java:4247)
      4. org.eclipse.swt.widgets.Display.error(Display.java:1068)
      5. org.eclipse.swt.widgets.Display.checkDevice(Display.java:621)
      6. org.eclipse.swt.widgets.Display.getActiveShell(Display.java:1221)
      6 frames
    3. org.springsource.ide
      UiStatusHandler.logAndDisplay
      1. org.springsource.ide.eclipse.commons.ui.UiUtil.getShell(UiUtil.java:95)
      2. org.springsource.ide.eclipse.commons.ui.UiStatusHandler.logAndDisplay(UiStatusHandler.java:28)
      2 frames
    4. org.springframework.ide
      TemplateWizard$1.run
      1. org.springframework.ide.eclipse.wizard.template.infrastructure.processor.TemplateProjectCreator.unzipProject(TemplateProjectCreator.java:269)
      2. org.springframework.ide.eclipse.wizard.template.infrastructure.processor.TemplateProjectCreator.createProject(TemplateProjectCreator.java:78)
      3. org.springframework.ide.eclipse.wizard.template.infrastructure.processor.DirectoryProcessor.process(DirectoryProcessor.java:56)
      4. org.springframework.ide.eclipse.wizard.template.infrastructure.processor.Processor.process(Processor.java:44)
      5. org.springframework.ide.eclipse.wizard.template.TemplateWizard$1.run(TemplateWizard.java:114)
      5 frames
    5. JFace
      ModalContext$ModalContextThread.run
      1. org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:121)
      1 frame