cancel
Showing results for 
Search instead for 
Did you mean: 

Run money-tasks got ' Argument cannot be null'

newdon
Champ in-the-making
Champ in-the-making
when i run the examples money-tasks of activiti designers 5.14.1 ,i got this error :
java.lang.IllegalArgumentException: Argument cannot be null
   at org.eclipse.swt.SWT.error(SWT.java:4378)
   at org.eclipse.swt.SWT.error(SWT.java:4312)
   at org.eclipse.swt.SWT.error(SWT.java:4283)
   at org.eclipse.swt.graphics.ImageLoader.load(ImageLoader.java:145)
   at org.eclipse.swt.graphics.ImageDataLoader.load(ImageDataLoader.java:22)
   at org.eclipse.swt.graphics.ImageData.<init>(ImageData.java:331)
   at org.eclipse.swt.graphics.Image.<init>(Image.java:545)
   at org.activiti.designer.diagram.ActivitiToolBehaviorProvider.getPalette(ActivitiToolBehaviorProvider.java:758)
   at org.eclipse.graphiti.ui.internal.editor.GFPaletteRoot.updatePaletteEntries(GFPaletteRoot.java:105)
   at org.eclipse.graphiti.ui.internal.editor.GFPaletteRoot.<init>(GFPaletteRoot.java:81)
   at org.eclipse.graphiti.ui.editor.DefaultPaletteBehavior.createPaletteRoot(DefaultPaletteBehavior.java:107)
   at org.eclipse.graphiti.ui.editor.DefaultPaletteBehavior.getPaletteRoot(DefaultPaletteBehavior.java:119)
   at org.eclipse.graphiti.ui.editor.DiagramBehavior.getPaletteRoot(DiagramBehavior.java:763)
   at org.eclipse.graphiti.ui.editor.DiagramEditor.getPaletteRoot(DiagramEditor.java:430)
   at org.eclipse.gef.ui.parts.GraphicalEditorWithFlyoutPalette.setEditDomain(GraphicalEditorWithFlyoutPalette.java:145)
   at org.eclipse.graphiti.ui.editor.DiagramEditor.setEditDomain(DiagramEditor.java:835)
   at org.eclipse.graphiti.ui.editor.DiagramBehavior.setConfigurationProvider(DiagramBehavior.java:1380)
   at org.eclipse.graphiti.ui.editor.DiagramBehavior.setInput(DiagramBehavior.java:391)
   at org.eclipse.graphiti.ui.editor.DiagramEditor.setInput(DiagramEditor.java:300)
   at org.activiti.designer.eclipse.editor.ActivitiDiagramEditor.setInput(ActivitiDiagramEditor.java:295)
   at org.eclipse.graphiti.ui.editor.DiagramEditor.init(DiagramEditor.java:217)
   at org.activiti.designer.eclipse.editor.ActivitiDiagramEditor.init(ActivitiDiagramEditor.java:125)
   at org.eclipse.ui.internal.EditorReference.initialize(EditorReference.java:359)
   at org.eclipse.ui.internal.e4.compatibility.CompatibilityPart.create(CompatibilityPart.java:306)
   at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
   at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
   at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
   at java.lang.reflect.Method.invoke(Unknown Source)
   at org.eclipse.e4.core.internal.di.MethodRequestor.execute(MethodRequestor.java:56)
   at org.eclipse.e4.core.internal.di.InjectorImpl.processAnnotated(InjectorImpl.java:877)
   at org.eclipse.e4.core.internal.di.InjectorImpl.processAnnotated(InjectorImpl.java:857)
   at org.eclipse.e4.core.internal.di.InjectorImpl.inject(InjectorImpl.java:119)
   at org.eclipse.e4.core.internal.di.InjectorImpl.internalMake(InjectorImpl.java:333)
   at org.eclipse.e4.core.internal.di.InjectorImpl.make(InjectorImpl.java:254)
   at org.eclipse.e4.core.contexts.ContextInjectionFactory.make(ContextInjectionFactory.java:162)
   at org.eclipse.e4.ui.internal.workbench.ReflectionContributionFactory.createFromBundle(ReflectionContributionFactory.java:102)
   at org.eclipse.e4.ui.internal.workbench.ReflectionContributionFactory.doCreate(ReflectionContributionFactory.java:71)
   at org.eclipse.e4.ui.internal.workbench.ReflectionContributionFactory.create(ReflectionContributionFactory.java:53)
   at org.eclipse.e4.ui.workbench.renderers.swt.ContributedPartRenderer.createWidget(ContributedPartRenderer.java:129)
   at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.createWidget(PartRenderingEngine.java:949)
   at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.safeCreateGui(PartRenderingEngine.java:633)
   at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.safeCreateGui(PartRenderingEngine.java:735)
   at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.access$2(PartRenderingEngine.java:706)
   at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$7.run(PartRenderingEngine.java:700)
   at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
   at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.createGui(PartRenderingEngine.java:685)
   at org.eclipse.e4.ui.workbench.renderers.swt.StackRenderer.showTab(StackRenderer.java:1096)
   at org.eclipse.e4.ui.workbench.renderers.swt.LazyStackRenderer$1.handleEvent(LazyStackRenderer.java:66)
   at org.eclipse.e4.ui.services.internal.events.UIEventHandler$1.run(UIEventHandler.java:41)
   at org.eclipse.swt.widgets.Synchronizer.syncExec(Synchronizer.java:180)
   at org.eclipse.ui.internal.UISynchronizer.syncExec(UISynchronizer.java:150)
   at org.eclipse.swt.widgets.Display.syncExec(Display.java:4688)
   at org.eclipse.e4.ui.internal.workbench.swt.E4Application$1.syncExec(E4Application.java:205)
   at org.eclipse.e4.ui.services.internal.events.UIEventHandler.handleEvent(UIEventHandler.java:38)
   at org.eclipse.equinox.internal.event.EventHandlerWrapper.handleEvent(EventHandlerWrapper.java:197)
   at org.eclipse.equinox.internal.event.EventHandlerTracker.dispatchEvent(EventHandlerTracker.java:197)
   at org.eclipse.equinox.internal.event.EventHandlerTracker.dispatchEvent(EventHandlerTracker.java:1)
   at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230)
   at org.eclipse.osgi.framework.eventmgr.ListenerQueue.dispatchEventSynchronous(ListenerQueue.java:148)
   at org.eclipse.equinox.internal.event.EventAdminImpl.dispatchEvent(EventAdminImpl.java:135)
   at org.eclipse.equinox.internal.event.EventAdminImpl.sendEvent(EventAdminImpl.java:78)
   at org.eclipse.equinox.internal.event.EventComponent.sendEvent(EventComponent.java:39)
   at org.eclipse.e4.ui.services.internal.events.EventBroker.send(EventBroker.java:80)
   at org.eclipse.e4.ui.internal.workbench.UIEventPublisher.notifyChanged(UIEventPublisher.java:58)
   at org.eclipse.emf.common.notify.impl.BasicNotifierImpl.eNotify(BasicNotifierImpl.java:374)
   at org.eclipse.e4.ui.model.application.ui.impl.ElementContainerImpl.setSelectedElement(ElementContainerImpl.java:171)
   at org.eclipse.e4.ui.internal.workbench.ModelServiceImpl.showElementInWindow(ModelServiceImpl.java:576)
   at org.eclipse.e4.ui.internal.workbench.ModelServiceImpl.bringToTop(ModelServiceImpl.java:543)
   at org.eclipse.e4.ui.internal.workbench.PartServiceImpl.delegateBringToTop(PartServiceImpl.java:610)
   at org.eclipse.e4.ui.internal.workbench.PartServiceImpl.bringToTop(PartServiceImpl.java:322)
   at org.eclipse.e4.ui.internal.workbench.PartServiceImpl.showPart(PartServiceImpl.java:1034)
   at org.eclipse.ui.internal.WorkbenchPage.busyOpenEditor(WorkbenchPage.java:3112)
   at org.eclipse.ui.internal.WorkbenchPage.access$21(WorkbenchPage.java:3034)
   at org.eclipse.ui.internal.WorkbenchPage$8.run(WorkbenchPage.java:3016)
   at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:70)
   at org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPage.java:3012)
   at org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPage.java:2976)
   at org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPage.java:2967)
   at org.eclipse.ui.ide.IDE.openEditor(IDE.java:534)
   at org.eclipse.ui.ide.IDE.openEditor(IDE.java:493)
   at org.eclipse.jdt.internal.ui.javaeditor.EditorUtility.openInEditor(EditorUtility.java:360)
   at org.eclipse.jdt.internal.ui.javaeditor.EditorUtility.openInEditor(EditorUtility.java:167)
   at org.eclipse.jdt.ui.actions.OpenAction.run(OpenAction.java:268)
   at org.eclipse.jdt.ui.actions.OpenAction.run(OpenAction.java:233)
   at org.eclipse.jdt.ui.actions.SelectionDispatchAction.dispatchRun(SelectionDispatchAction.java:275)
   at org.eclipse.jdt.ui.actions.SelectionDispatchAction.run(SelectionDispatchAction.java:251)
   at org.eclipse.jdt.internal.ui.navigator.OpenAndExpand.run(OpenAndExpand.java:50)
   at org.eclipse.ui.actions.RetargetAction.run(RetargetAction.java:221)
   at org.eclipse.ui.navigator.CommonNavigatorManager$3.open(CommonNavigatorManager.java:185)
   at org.eclipse.ui.OpenAndLinkWithEditorHelper$InternalListener.open(OpenAndLinkWithEditorHelper.java:47)
   at org.eclipse.jface.viewers.StructuredViewer$2.run(StructuredViewer.java:866)
   at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
   at org.eclipse.ui.internal.JFaceUtil$1.run(JFaceUtil.java:49)
   at org.eclipse.jface.util.SafeRunnable.run(SafeRunnable.java:175)
   at org.eclipse.jface.viewers.StructuredViewer.fireOpen(StructuredViewer.java:864)
   at org.eclipse.jface.viewers.StructuredViewer.handleOpen(StructuredViewer.java:1152)
   at org.eclipse.ui.navigator.CommonViewer.handleOpen(CommonViewer.java:462)
   at org.eclipse.jface.viewers.StructuredViewer$6.handleOpen(StructuredViewer.java:1256)
   at org.eclipse.jface.util.OpenStrategy.fireOpenEvent(OpenStrategy.java:275)
   at org.eclipse.jface.util.OpenStrategy.access$2(OpenStrategy.java:269)
   at org.eclipse.jface.util.OpenStrategy$1.handleEvent(OpenStrategy.java:309)
   at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
   at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1057)
   at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:4170)
   at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3759)
   at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$9.run(PartRenderingEngine.java:1113)
   at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
   at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.run(PartRenderingEngine.java:997)
   at org.eclipse.e4.ui.internal.workbench.E4Workbench.createAndRunUI(E4Workbench.java:138)
   at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:610)
   at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
   at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:567)
   at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:150)
   at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:124)
   at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
   at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
   at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
   at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:354)
   at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:181)
   at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
   at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
   at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
   at java.lang.reflect.Method.invoke(Unknown Source)
   at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:636)
   at org.eclipse.equinox.launcher.Main.basicRun(Main.java:591)
   at org.eclipse.equinox.launcher.Main.run(Main.java:1450)
   at org.eclipse.equinox.launcher.Main.main(Main.java:1426)

this is my jar : https://www.dropbox.com/sm/create/money-tasks-1.2.0.jar
i used eclipse kepler ,  i have followed the user guider :
Windows -> Preferences -> Java -> User Libraries ->Activiti Designer Extensions.
Can any one help me ? Many thanks!
3 REPLIES 3

frederikherema1
Star Contributor
Star Contributor
Seems to be an issue with the location of the image-file (icon for the task).

jcoveron
Champ in-the-making
Champ in-the-making
Hi
I am getting the same error. Here are the steps that I have done.

[1] Created a general project in Eclipse.
[2] After creating it, I converted it to a Maven project.
[3] Modified pom.xml just as the user guide said. I even tried to modify the repository as shown in this thread (http://forums.activiti.org/content/adaption-designer). I am attaching my pom.xml.
[4] Created the folder structure as the user guide said and dowloaded the money-tasks from GitHub repository (https://github.com/Activiti/Activiti-Designer/tree/master/examples).
[5] Once everything was in place, I right clicked on the project and selected Maven > Update Project.
[6] Afterwards, I right clicked again in the project and selected Run As > maven clean. Just to be sure.
[7] Finally, I right clicked the project and selected Run As > maven build. This created the target folder structure and the jar file. The build displayed no errors.
[8] Moved the jar file to a different folder outside the workspace.
[9] Added the jar file in User Libraries in Eclipse in the Java section.
[10] Created a new and clean Activiti project, and added a new Activiti diagram.

Unfortunately, the diagram does not open, the error shown is "Argument cannot be null". Attached are all the errors reported by Eclipse.

For sure this is has little to do with the Designer, and more about Maven. But I have tried many things and I cannot seam to get this right.

I will deeply appreciate if you could give me a hint of what could it be that I am doing wrong.

Many thanks in advance and sorry for the trouble.

jcoveron
Champ in-the-making
Champ in-the-making
Hi
I just posted an issue I had with the money-tasks project.
I fixed by adding in the AcmeMoneyTask.java file in the org.acme.servicetasks package the below code:

<code>
/*
   * (non-Javadoc)
   *
   * @see org.activiti.designer.integration.servicetask.AbstractCustomServiceTask #getSmallIconPath()
   */
  @Override
  public String getSmallIconPath() {
    return "icons/coins.png";
  }
</code>

I am not sure if this is the right way to fix it or it is just missing in the sample code in the GitHub repository, or maybe I just downloaded the wrong version. But I though it was a good idea to post how I was able to correctly test the money-tasks example.

Many thanks for the great effort on the BPM. It is a great tool. Keep up the good work and sorry for the trouble.