How to fix "unable to save parts" error?

Hey, I’m running Katalon Studio on Kubuntu 24.04,

Whenever I make changes to a Testcase and want to press save all this message occurs:

I can reproduce this issue using version 9.1.0 and 10.2.1.

What can I try to fix this issue?

java --version output:

openjdk 17.0.15 2025-04-15
OpenJDK Runtime Environment (build 17.0.15+6-Ubuntu-0ubuntu124.04)
OpenJDK 64-Bit Server VM (build 17.0.15+6-Ubuntu-0ubuntu124.04, mixed mode, sharing)

Error Log Output:

!ENTRY org.eclipse.e4.ui.workbench 4 0 2025-06-10 10:13:47.324
!MESSAGE Cannot invoke "com.kms.katalon.composer.testcase.parts.TestCaseVariableEditorPart.getMPart()" because "this.childTestCaseVariableEditorPart" is null
!STACK 0
java.lang.NullPointerException: Cannot invoke "com.kms.katalon.composer.testcase.parts.TestCaseVariableEditorPart.getMPart()" because "this.childTestCaseVariableEditorPart" is null
	at com.kms.katalon.composer.testcase.parts.TestCaseCompositePart.isAnyChildDirty(TestCaseCompositePart.java:872)
	at com.kms.katalon.composer.testcase.parts.TestCaseCompositePart.updateDirty(TestCaseCompositePart.java:837)
	at com.kms.katalon.composer.testcase.parts.TestCaseCompositePart.save(TestCaseCompositePart.java:708)
	at com.kms.katalon.composer.handlers.SaveAllHandler.execute(SaveAllHandler.java:56)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:569)
	at org.eclipse.e4.core.internal.di.MethodRequestor.execute(MethodRequestor.java:58)
	at org.eclipse.e4.core.internal.di.InjectorImpl.invokeUsingClass(InjectorImpl.java:299)
	at org.eclipse.e4.core.internal.di.InjectorImpl.invoke(InjectorImpl.java:233)
	at org.eclipse.e4.core.contexts.ContextInjectionFactory.invoke(ContextInjectionFactory.java:174)
	at org.eclipse.e4.core.commands.internal.HandlerServiceHandler.execute(HandlerServiceHandler.java:165)
	at org.eclipse.core.commands.Command.executeWithChecks(Command.java:488)
	at org.eclipse.core.commands.ParameterizedCommand.executeWithChecks(ParameterizedCommand.java:485)
	at org.eclipse.e4.core.commands.internal.HandlerServiceImpl.executeHandler(HandlerServiceImpl.java:204)
	at org.eclipse.e4.ui.workbench.renderers.swt.HandledContributionItem.executeItem(HandledContributionItem.java:444)
	at org.eclipse.e4.ui.workbench.renderers.swt.AbstractContributionItem.handleWidgetSelection(AbstractContributionItem.java:442)
	at org.eclipse.e4.ui.workbench.renderers.swt.AbstractContributionItem.lambda$2(AbstractContributionItem.java:464)
	at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:91)
	at org.eclipse.swt.widgets.Display.sendEvent(Display.java:5855)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1617)
	at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:5065)
	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:4517)
	at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$5.run(PartRenderingEngine.java:1151)
	at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:339)
	at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.run(PartRenderingEngine.java:1042)
	at org.eclipse.e4.ui.internal.workbench.E4Workbench.createAndRunUI(E4Workbench.java:152)
	at org.eclipse.ui.internal.Workbench.lambda$3(Workbench.java:639)
	at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:339)
	at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:546)
	at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:173)
	at com.kms.katalon.core.application.WorkbenchApplicationStarter.start(WorkbenchApplicationStarter.java:23)
	at com.kms.katalon.application.Application.runGUI(Application.java:209)
	at com.kms.katalon.application.Application.start(Application.java:114)
	at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:208)
	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:143)
	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:109)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:439)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:271)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:569)
	at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:668)
	at org.eclipse.equinox.launcher.Main.basicRun(Main.java:605)
	at org.eclipse.equinox.launcher.Main.run(Main.java:1481)
	at org.eclipse.equinox.launcher.Main.main(Main.java:1454)
1 Like

To resolve the “unable to save parts” error in Katalon Studio on Kubuntu, follow these steps:


1. Fix the NullPointerException in Test Case Variables

The error arises when saving a test case with variables. To bypass the bug:

  1. Manually edit the test case file:
  • Navigate to your project’s Test Cases folder.
  • Open the .tc file (e.g., YourTestCase.tc) in a text editor.
  • Remove or fix corrupted variables in the <variables> section:

xml

<variables>
  <variable name="validVar" scope="Test Case" type="String">
    <defaultValue>valid_value</defaultValue>
  </variable>
</variables>
  1. Avoid using the Variables tab in Katalon Studio until the bug is fixed.

2. Clear Katalon’s Cache

Corrupted workspace metadata often causes save failures:

bash

cd ~/katalon-workspace
rm -rf .metadata/ .recommenders/

Restart Katalon Studio afterward.


3. Adjust File Permissions

Ensure Katalon has write access to your project:

bash

chmod -R 755 ~/katalon-workspace/
chown -R $USER:$USER ~/katalon-workspace/

4. Use a Portable Version

Run Katalon from a directory with full permissions (e.g., /opt):

bash

sudo tar -xvzf Katalon_Studio_Linux_64-8.6.7.tar.gz -C /opt/

5. Workaround: Export Test Cases

  1. Export the test case to a .tsv file via File > Export > Test Cases.
  2. Edit the file externally and re-import it.

6. Disable Variable Editor (Advanced)

Modify Katalon’s Eclipse plugins to skip loading the faulty part:

  1. Navigate to Katalon’s plugin directory:

bash

cd /opt/Katalon_Studio/plugins
  1. Temporarily rename the variable editor plugin:

bash

mv com.kms.katalon.composer.testcase_*.jar com.kms.katalon.composer.testcase_*.jar.bak


Temporary Fix for Critical Work

Use Git to revert unsaved changes:

bash

git checkout -- Test\ Cases/YourTestCase.tc

Years ago, I encountered a similar (but not identical) error. See

I guess this error is caused by some dirty things inside the configurations and caches managed by Eclipse behind Katalon Studio. I think that Katalon is not responsible for this problem.

The following Q&A in the Stackoverflow suggests something worth trying:

https://stackoverflow.com/questions/13085534/problems-occurred-when-invoking-code-from-plug-in-org-eclipse-jface

Please try:

  1. close your katalon project
  2. in your katalon project, find the following folders:
$ tree -L 1 -a .
.
├── .classpath
├── .project
├── .settings
...
  1. remove the .classpath, .project and .settings.
  2. reopen the katalon project.
  3. the 3 folders will be recreated by Eclipse silently

I meant to initialize the config and caches created by Eclipse for the project.

If you, @junes, have a Git repository for the katalon project, you should make sure you do .gitignore those 3 folders out of the repository.

Also, it would worth trying

  1. remove the Katalon Studio installation completeley.
  2. to make sure, remove the directory where you installed the Katalon Studio.
  3. reinstall Katalon Studio (just the same version will do)

Then, any dirty stuff inside the Katalon-installation directory will be cleared out and you can start fresh.

Hey,

installing this seems to have fixed my issue:

sudo apt install libwebkit2gtk-4.1-0