Trying to create a sub category using java api
parentCategoryHandle = service.findCategoryByNamePath(project,namePath, MONITOR);
if (parentCategoryHandle == null) { return "ERROR: Category " + categoryName + " parent not found"; } // Create category (error line 272) category = service.createSubcategory(parentCategoryHandle,categoryName,MONITOR); Error I get is: Exception in thread "main" org.eclipse.core.runtime.AssertionFailedException: assertion failed: at org.eclipse.core.runtime.Assert.isTrue(Assert.java:110) at org.eclipse.core.runtime.Assert.isTrue(Assert.java:96) at com.ibm.team.workitem.common.internal.util.CategoriesHelper.createCategoryId(CategoriesHelper.java:175) at com.ibm.team.workitem.common.internal.WorkItemCommon.createSubcategory(WorkItemCommon.java:738) at interations_releases.Repository.createCatagory(Repository.java:272) |
Be the first one to answer this question!
Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.
Comments
service is
IWorkItemClient service = (IWorkItemClient) repo.getClientLibrary(IWorkItemClient.class);