Skip to main content

Problem Categories

Symptoms: PowerSheet shows empty cells where linked items should appear, or expansion paths don’t display child rows. Solution:
  1. Verify link role names match RTM model — Open .polarion/nextedy/models/rtm-model.yaml and check exact link role names:
    - name: refines
      source: desReq
      target: sysReq
    
    PowerSheet YAML must use identical role name: refines, not refinedBy or refinesRequirement.
  2. Check expansion path syntax — Ensure PowerSheet expansion path matches RTM relationship direction:
    # Correct: traverse FROM desReq TO sysReq via 'refines' role
    expansion:
      - relationship: refines
        entity: sysReq
    
    # Wrong: using backlink role not defined in RTM model
    expansion:
      - relationship: refinedBy  # RTM only defines 'refines'
        entity: sysReq
    
  3. Validate entity type names — Entity names in PowerSheet YAML are case-sensitive and must match work item type IDs exactly:
    entity: verificationTestCase  # ✓ Correct
    entity: VerificationTestCase  # ✗ Wrong case
    entity: testCase              # ✗ Wrong type ID
    
From support ticket #1847: PowerSheet showed empty test case columns because YAML used verifies relationship from requirement → test case, but RTM model only defined the reverse direction (verifies from test case → requirement). Fix: use correct relationship direction or add bidirectional role to RTM model.
Symptoms: Dashboard coverage bars show 0% or “0/31” even though Work Items Tracker shows links present. Solution:
  1. Check link role filter in coverage macro — Open the space dashboard page (e.g., .polarion/pages/spaces/Requirements/1 - Requirements/page.xml) and verify nxLinkCoverage parameters:
    #nxLinkCoverage("sysReq" "testCase" "verifies" "back")
    ##                       ↑ target   ↑ role    ↑ direction
    
    Direction must match link storage:
    • "back" — counts sysReq items WITH backlinks FROM testCase via ‘verifies’
    • "direct" — counts sysReq items WITH outgoing links TO testCase via ‘verifies’
  2. Test the gap query manually — Copy the Lucene query from nxLinkCoverage call and run in Work Items Tracker:
    type:sysReq AND NOT backlinkedWorkItems:verifies=TA*
    
    If this returns items that YOU see as linked, the link role name is wrong.
  3. Verify link role exists in Polarion — Navigate to Administration → Work Items → Link Roles and confirm the role ID matches exactly (case-sensitive).
The =TA* suffix in gap queries filters links to work items starting with project prefix “TA”. If your project uses a different prefix (e.g., “AEB”), coverage will show 0%. Update dashboard queries to match your project prefix.
Symptoms: Links disappear or show “Invalid link” after copying a document or moving work items between modules. Solution:
  1. Re-establish module-scoped links — If work items were copied to a different module, link references may point to old module context. Delete broken links and recreate:
    • Open work item in form view
    • Navigate to Links tab
    • Remove invalid link entries (show as red/strikethrough)
    • Add new links using work item picker
  2. Avoid cross-project links — TestAuto2 RTM model expects links within the same Polarion project. If you copied work items from another project, links won’t resolve. Use Import/Export instead of copy/paste for cross-project migration.
  3. Check for duplicate work item IDs — After module copy, duplicate IDs may exist. Run query:
    id:TA-REQ-001
    
    If multiple results appear, Polarion can’t resolve links unambiguously. Reassign IDs to copied items.

4. Calculated Column Shows “Cannot read property” Error

Symptoms: PowerSheet calculated columns display JavaScript error instead of computed value. Solution:
  1. Add null checks for link traversal — Custom renderers and calculated columns must handle missing links:
    // Wrong: assumes link always exists
    $linkedItem.customFields.get("severity")
    
    // Correct: check for null
    #if($linkedItem && $linkedItem.customFields.get("severity"))
      $linkedItem.customFields.get("severity").id
    #else
      "N/A"
    #end
    
  2. Verify link cardinality — If RTM model allows cardinality: "*" (many), renderer must iterate collection:
    #foreach($control in $failureMode.getLinkedWorkItems("mitigatedBy"))
      $control.id
    #end
    
  3. Check for circular references — If PowerSheet freezes or shows recursion errors, RTM expansion path may create a loop (e.g., sysReq → desReq → sysReq). Review RTM model for cycles.

Diagnostic Decision Tree

Link issue detected

├─ PowerSheet shows empty cells?
│  ├─ YES → Check expansion path direction (step 1.2)
│  │       Check entity/role spelling (step 1.1, 1.3)
│  │
│  └─ NO → Continue

├─ Dashboard coverage = 0% but Tracker shows links?
│  ├─ YES → Check nxLinkCoverage direction parameter (step 2.1)
│  │       Test gap query manually (step 2.2)
│  │       Verify project prefix filter (tip box)
│  │
│  └─ NO → Continue

├─ Links disappeared after copy/move?
│  ├─ YES → Check for duplicate IDs (step 3.3)
│  │       Re-establish links manually (step 3.1)
│  │
│  └─ NO → Continue

└─ JavaScript errors in calculated columns?
   └─ YES → Add null checks (step 4.1)
           Check cardinality handling (step 4.2)
           Review for circular references (step 4.3)
Source TypeTarget TypeLink RoleDirection
desReqsysReqrefinesDirect
sysReqcustomerRequirementrefinesDirect
testCasesysReqverifiesDirect
validationTestCasecustomerRequirementvalidatesDirect
failureModeriskControlmitigatedByDirect
characteristicfailureModehasFailureModeDirect
safetyGoalhazardmitigatesDirect
TestAuto2 uses active voice for link role names (e.g., refines, verifies, mitigates). Avoid passive forms (refinedBy, verifiedBy) unless explicitly defined in your RTM model. Check .polarion/nextedy/models/rtm-model.yaml for canonical role names.

Verification Step

After fixing link configuration:
  1. Reload PowerSheet — Hard refresh browser (Ctrl+Shift+R / Cmd+Shift+R)
  2. Check expansion — Linked items should appear as child rows in PowerSheet hierarchy
  3. Verify dashboard metrics — Coverage bars should update to reflect actual link counts
  4. Test gap query — Run the Lucene query from dashboard in Work Items Tracker; result count should match “uncovered” number
You should now see:
  • PowerSheet expansion showing linked work items in sub-rows
  • Dashboard coverage percentages matching actual traceability state
  • No “Invalid link” or “Cannot read property” errors in calculated columns

See Also