Xray
all clusters 1h 6h 24h 48h 3d 5d 7d 14d 30d ‹
Last 1 hour▾
Ends now. Anything up to this cluster's 30-day retention.
Start and end times
Cancel
Interpreted in UTC (change it at the right of this bar). Earliest available: 2026-10-24 09:44:03.
› →|
updated 5d ago
Sample data. This database was generated by scripts/seed_dev_db.py — every service, deploy, person and figure on this page is synthetic. Names are sample.*@seed.invalid and image tags are prefixed SEED-. Nothing here happened.

‹ Test triage

[Test failure] Study Team Training Log shows "In Progress"; new TC-10 expects "In progress"

Cause not clear confidence low · medium priority · e2e-tests-master, last seen in build 881

The verdict

Fix is in
not known yet
Issue
ENG-8877 · Completed
Owner
[email protected] (last changed visitExecStudy.page.js (de78c7210))
Filed in
Ready for Development, product project, in the current cycle
Service
sense
History when filed
new, this error since build 881
On screen
The Study Team Training Log table shows the trainee's status cell as "In Progress" (capital P).
Branches
fails on master; on production (e2e-tests-production build 860) 0 of 1 fail the same way, 0 pass.
TC-10 (new in de78c7210, first run) fails because the log's status cell shows "In Progress" and the test expects "In progress" (visitExecStudy.page.js:692, spec line 227). The source I read renders "In progress": toLogStatus in training-log-mappers.ts:171, shown by the Badge in useTrainingLogColumns.tsx:77. e2e/knowledge/training.md:22, verified 15 Nov, says the same. I found no commit that changed the label and no place in the source that produces a capital P in this log. So the deployed build (product_commit 82fca18) and the default-branch source seem to disagree. I could not confirm this from here. Second error, probably a knock-on: after the soft failure the test goes on to line 242, where waitForTrainingLogSearch times out at visitApiUtility.js:224 (50 s waiting for the site-log search response). Both retries failed the same way, so it is deterministic and not a race. Next: open the Study Team Training Log in Table view on the cluster and read the monitor's status. If it is "In Progress", find which FE build produces it. If the capital P is intended, change the test and the notes to "In Progress". If not, it is a product regression. No cluster pod or deploy trouble ties to this test, and no service logged an error under its requests.

Steps to reproduce

  1. Sign in as Test Admin in the CRO org (Tilda CRO).
  2. Use a CRO study with a team-scope staff training assigned to Cro Dm, Cro Monitor and Cro Pm. Dm and Pm must have completed it and Monitor must be part-way through.
  3. Open the study and go to the Trainings tab, then Study Team Training Log.
  4. Switch the view to Table (the log opens in Grid).
  5. Type the Cro Monitor user's name in the search box and wait for the list to narrow to one card.
  6. Read the Status cell of the staff training row.
  7. Expected: "In progress", as in training-log-mappers.ts and the 15 Nov notes; actual: "In Progress".

History of this root cause

  • filed ENG-8877 · build 881 6d ago
    Cause not clear, confidence low; 1 test; to [email protected] in Ready for Development
  • branches ENG-8877 6d ago

Tests 1

Oldest to newest, up to 30 runs. Green passed, red failed with this error, amber failed with another error. Skipped and collapsed runs are left out. Newest build: 882.

How the agent decided

Models
claude-sonnet-5-5 ($0.77, 26 lookups)
Settled by
the investigating model
Cost
$0.77

What it looked up (26, in order)

1. search_code repo=cleopatra, text=In Progress, path_prefix=src · 30 chars back
no match on the default branch
2. commits repo=cleopatra, path=e2e/tests/training/staff.spec.js · 712 chars back
de78c7210 2026-11-16T07:51 sbadiger: [E2E]: Training logs verifications (#16842) 4901909b7 2026-11-13T13:41 sbadiger: [E2E]: Training test fixes (#16803) a4e9aea2b 2026-11-12T17:57 Harsh-Tilda: [E2E] TA 230 shared state (#16769) 29817b18b 2026-11-11T17:24 Harsh-Tilda: [E2E] build the shared studies per study, only for the specs that ask (#16701) 6fa3ebc48 2026-11-11T10:44 sbadiger: [E2E]: Simplify execution (#16679) 11c6b32b4 2026-11-10T11:42 Harsh-Tilda: [E2E] changes folder structure and run to run module wise (#16639) 4f2467f3d 2026-11-03T07:45 arzatskis: Turn on the new filters toolbar everywhere and update e2e for it (#16330) 4f4ad96e7 2026-10-26T04:48 sbadiger: [E2E]: Staff training test (#16106)
3. search_code repo=cleopatra, text=In Progress · 590 chars back
packages/api/hooks/useOrgReportsQuery.ts 29: (report) => report.status === 'In Progress' packages/api/hooks/useStudyReportsQuery.ts 23: (report) => report.status === 'In Progress' apps/sense/src/components/training/utils.ts e2e/knowledge/training.md 22: - **Status copy differs from the side panel:** the log says `In progress`, the training side panel `In Progress`. 73: Trainee outcomes asserted after the full chain: PI `Passed`, QA `Failed`, DA `Pending`, Recruiter `In Progress`. packages/api/hooks/useProtocolExportMutation.ts packages/api/hooks/useParticipantVisitCRFQuery.ts
4. search_code repo=cleopatra, text=In progress · 399 chars back
packages/api/hooks/useOrgReportsQuery.ts packages/api/hooks/useStudyReportsQuery.ts apps/sense/src/components/training/utils.ts 16: return 'In progress'; e2e/knowledge/training.md 22: - **Status copy differs from the side panel:** the log says `In progress`, the training side panel `In Progress`. packages/api/hooks/useProtocolExportMutation.ts packages/api/hooks/useParticipantVisitCRFQuery.ts
5. read_file repo=cleopatra, path=apps/sense/src/components/training/utils.ts, start_line=1, end_line=60 · 521 chars back
apps/sense/src/components/training/utils.ts (17 lines), lines 1-17: 1 import { formatDate } from 'ui'; 2 3 export const getTrainingSubtitle = ( 4 status?: string, 5 updatedAt?: string | number | Date 6 ): string => { 7 if (status === 'Passed') { 8 return `Passed on ${formatDate(new Date(updatedAt!))}`; 9 } 10 if (status === 'Failed') { 11 return `Failed on ${formatDate(new Date(updatedAt!))}`; 12 } 13 if (status === 'Pending') { 14 return 'Assigned'; 15 } 16 return 'In progress'; 17 };
6. commits repo=cleopatra, path=apps/sense/src/components/training, since=2026-11-01T00:00:00Z · 38 chars back
no commits to that path in that window
7. search_code repo=cleopatra, text=data-column-id, path_prefix=apps/sense/src · 804 chars back
apps/sense/src/modules/documents/components/placeholders-grid-view.module.scss 25: :global(th[data-column-id='scope'] > div), 26: :global(td[data-column-id='scope'] > div) { 36: :global(th[data-column-id='scope'][data-pinned]), 37: :global(td[data-column-id='scope'][data-pinned]) { apps/sense/src/modules/documents/components/draft-placeholders-collapsible.module.scss 58: :global(td[data-column-id='select']) { apps/sense/src/modules/documents/utils/exportGridToPdf.ts 116: return node.getAttribute('data-column-id') !== 'select'; apps/sense/src/modules/ai-teammates/ai-workorders/work-order-config/recipients-table.module.scss 6: :global(th[data-column-id='site']), 7: :global(td[data-column-id='site']) { 11: :global(th[data-column-id='to']), 12: :global(td[data-column-id='to']),
8. read_file repo=cleopatra, path=e2e/knowledge/training.md, start_line=10, end_line=35 · 2605 chars back
e2e/knowledge/training.md (125 lines), lines 10-35: 10 11 Since main #16777 (ENG-8591, 13 Nov) the study Trainings tab's single Training Log is **Study Team Training Log** (`study-trainings-team-log-tab`) and **Site Training Log** (`study-trainings-site-log-tab`), beside Team T 12 13 ## Reading the training logs 14 15 Verified 2026-11-15 on `automation.master` (FE `main-b6287d4`, BE `master-7713ce2`) as Test Admin in the CRO org. 16 17 - **Which log:** a training with no site scope (the staff spec's `scope: 'team'`) is listed only in **Study Team Training Log**; a site-scoped one (regular, TBUT) only in **Site Training Log** (`getTrainingLogPath`, `tra 18 - **Grid vs Table:** the log always mounts as **Grid** (view state is in memory, not persisted), where each training is a column keyed by its id. `VisitStudiesPage.openTrainingLog` switches to **Table** (`trainings-log-v 19 - **Assert through `VisitStudiesPage.expectTrainingLogEntries`**: it searches each trainee and checks `status`, `assignedBy`, `completed`, `reason`, `reasonBy` or `absent` — whichever keys an entry gives. 20 - **Rows are attributed by narrowing, not by card:** `searchTrainingLog` fills the search (retried, since switching to Table remounts the box), waits for that search's own `GET …/study/<studyId>/training/assignees?search 21 - **Search matches trainee names only** (a training name returns *No log entries*). The list is paginated and the cards are virtualised, so always search the trainee first (`se … (1105 more characters not kept)
9. commit_diff repo=cleopatra, sha=de78c7210, path=e2e/tests/training/staff.spec.js · 3367 chars back
de78c7210 2026-11-16T07:51 sbadiger: [E2E]: Training logs verifications (#16842) 8 files changed: e2e/AGENTS.md, e2e/knowledge/training.md, e2e/pages/visitExecution/visitExecStudy.page.js, e2e/tests/training/regular.spec.js, e2e/tests/training/staff.spec.js, e2e/tests/training/tbut.spec.js, e2e/utils/apiUtility/visitApiUtility.js, e2e/utils/fixtures/visitExec.js --- e2e/tests/training/staff.spec.js @@ -13,13 +13,14 @@ const { staff: staffTrainingData } = JSON.parse( test.use({ executionSetup: STUDIES.CRO }); test.describe.configure({ mode: 'serial' }); -test.describe('Staff Training', () => { +test.describe('Staff Doc Training', () => { let trainingTemplateName; let documentTemplateName; let documentFileName; let dmUser; let monitorUser; let pmUser; + let adminTrainer; const studyName = data.croStudyName; const croOrg = data.croOrg; let trainingDetails = {}; @@ -28,6 +29,7 @@ test.describe('Staff Training', () => { dmUser = await userApiUtility.findUserDetails('Cro Dm'); monitorUser = await userApiUtility.findUserDetails('Cro Monitor'); pmUser = await userApiUtility.findUserDetails('Cro Pm'); + adminTrainer = await userApiUtility.findUserDetails('Test Admin'); }); test('TC-01: Upload and categorize staff training document', async ({ @@ -207,6 +209,42 @@ test.describe('Staff Training', () => { ]); }); + test('TC-10: Verify Staff Training entries in Study Team Training Log', async ({ + adminCro + }) => { … (1867 more characters not kept)
10. search_code repo=cleopatra, text=trainings-log-v · 417 chars back
e2e/knowledge/training.md 18: - **Grid vs Table:** the log always mounts as **Grid** (view state is in memory, not persisted), where each training is a column keyed by its id. `VisitStudiesPage.openTrainingLog` switches to **Table e2e/pages/visitExecution/visitExecStudy.page.js 570: 'trainings-log-view-toggle-table' apps/sense/src/components/trainings/training-log.tsx 1075: testId="trainings-log-view-toggle"
11. search_code repo=cleopatra, text=Completed on, path_prefix=apps/sense/src · 876 chars back
apps/sense/src/components/actor-slideover/training-print/csv.ts 28: 'Completed on', apps/sense/src/modules/studies/routes/studies/study/trainings-log-print/csv.ts 80: /** Training-level log: one row per trainee, one column per step, plus Overall/Completed on. */ 95: 'Completed on', apps/sense/src/modules/studies/hooks/useTrainingLogColumns.tsx 104: header: 'Completed on', apps/sense/src/components/trainings/my-trainings.tsx 184: header: 'Completed on', apps/sense/src/components/trainings/training-log.tsx 544: // Completed on + Reason (pinned right in the step view). Unassigned step 635: on/Due on/Completed on/Reason columns instead, so only the 801: header: 'Completed on', apps/sense/src/modules/studies/hooks/training-log-mappers.ts 130: /** Most recent completion timestamp across a trainee's entries, used for the grid's "Completed on" column. */
12. search_code repo=cleopatra, text=rogress, path_prefix=apps/sense/src/components/trainings · 94 chars back
apps/sense/src/components/trainings/my-trainings.tsx 36: pending: ['Pending', 'InProgress'],
13. search_code repo=cleopatra, text=rogress, path_prefix=apps/sense/src/modules/studies/hooks · 1081 chars back
apps/sense/src/modules/studies/hooks/useProgressNotesMenu.ts 2: CarePlanProgressNote, 4: useSubjectProgressNoteDeleteMutation, 7: import { useProgressNoteModal } from 'hooks'; 16: export const useProgressNotesMenu = ({ careplanId, studyId }: Props) => { apps/sense/src/modules/studies/hooks/useSubjectsData.ts 150: return subject.carePlan?.amendstatus !== 'AmendInProgress'; 153: const sitesAmendmentInProgress = useMemo(() => { 159: subject.carePlan?.amendstatus === 'AmendInProgress' && 175: sitesAmendmentInProgress, apps/sense/src/modules/studies/hooks/useSubjectFilters.ts 15: value: 'ScreenInProgress', apps/sense/src/modules/studies/hooks/useTrainingLogColumns.tsx 13: // Single source of truth for a trainee's progress-status badge color — 18: 'In progress': 'info', apps/sense/src/modules/studies/hooks/training-log-mappers.ts 14: | 'In progress' 23: 'In progress', 127: return 'In progress'; 171: if (lower.includes('progress')) return 'In progress'; apps/sense/src/modules/studies/hooks/useReportsColumns.tsx 17: 'In Progress': 'warning',
14. search_code repo=cleopatra, text=status, path_prefix=apps/sense/src/components/trainings/training-log.tsx · 59 chars back
could not do that: RuntimeError: GitHub 403 on /search/code
15. read_file repo=cleopatra, path=apps/sense/src/modules/studies/hooks/training-log-mappers.ts, start_line=105, end_line=180 · 3941 chars back
apps/sense/src/modules/studies/hooks/training-log-mappers.ts (357 lines), lines 105-180: 105 * Combined status across a trainee's different trainings, for the global 106 * log's "Overall" column — there's no single server status to read there, 107 * since each entry is a different training. Not for the single-training step 108 * log: there, the assignee's own `status` is the source of truth (see 109 * mapStepLogAssignee) since section statuses don't reflect e.g. a forceful 110 * completion. 111 */ 112 export const getOverallStatus = ( 113 entries: TrainingLogEntry[] 114 ): TrainingLogStatus => { 115 // An Unassigned entry is a kept record, not work owed: it decides Overall only when nothing is owed. 116 const owed = entries.filter((e) => e.assignmentState !== 'Unassigned'); 117 return overallOf(owed.length > 0 ? owed : entries); 118 }; 119 120 const overallOf = (entries: TrainingLogEntry[]): TrainingLogStatus => { 121 const statuses = entries.map((e) => e.status).filter((s) => s !== 'Removed'); 122 if (statuses.length === 0 && entries.length > 0) return 'Removed'; 123 if (statuses.every((s) => s === 'Passed')) return 'Passed'; 124 if (statuses.includes('Failed')) return 'Failed'; 125 if (statuses.includes('Overdue')) return 'Overdue'; 126 if (statuses.every((s) => s === 'Pending')) return 'Pending'; 127 return 'In progress'; 128 }; 129 130 /** Most recent completion timestamp across a trainee's entries, used for the grid's "Completed on" column. … (2441 more characters not kept)
16. read_file repo=cleopatra, path=apps/sense/src/modules/studies/hooks/useTrainingLogColumns.tsx, start_line=1, end_line=110 · 3595 chars back
apps/sense/src/modules/studies/hooks/useTrainingLogColumns.tsx (135 lines), lines 1-110: 1 import { 2 Badge, 3 BadgeTheme, 4 Button, 5 Icon, 6 IconThumbnail, 7 Time, 8 ColumnDef 9 } from 'ui'; 10 import { useNavigate, useNavigationOrigin } from 'router'; 11 import { TrainingLogEntry, TrainingLogStatus } from './useTrainingLogQuery'; 12 13 // Single source of truth for a trainee's progress-status badge color — 14 // every training status badge (trainees list, log grid/print/csv) should 15 // theme through this map instead of keeping its own local copy. 16 export const trainingLogStatusTheme: Record<TrainingLogStatus, BadgeTheme> = { 17 Pending: 'warning', 18 'In progress': 'info', 19 Passed: 'success', 20 Completed: 'success', 21 Overdue: 'danger', 22 Failed: 'danger', 23 Removed: 'neutral' 24 }; 25 26 export const useTrainingLogColumns = (): ColumnDef<TrainingLogEntry>[] => { 27 const navigate = useNavigate(); 28 const { pushBreadcrumb } = useNavigationOrigin(); 29 30 return [ 31 { 32 id: 'training', 33 header: 'Training', 34 accessorKey: 'trainingName', 35 meta: { primary: true }, 36 cell: ({ row }) => 37 row.original.workOrderTildaid ? ( 38 <div className="flex items-center gap-8"> 39 <IconThumbnail size="list" icon="graduation-cap" /> 40 <span>{row.original.trainingName}</span> 41 <div onClick={(e) => e.stopPropagation()}> 42 <Button 43 … (2095 more characters not kept)
17. commits repo=cleopatra, path=apps/sense/src/modules/studies/hooks/useTrainingLogColumns.tsx, since=2026-11-01T00:00:00Z · 38 chars back
no commits to that path in that window
18. read_file repo=cleopatra, path=apps/sense/src/components/trainings/training-log.tsx, start_line=700, end_line=830 · 5091 chars back
apps/sense/src/components/trainings/training-log.tsx (1141 lines), lines 700-830: 700 <div> 701 <Text 702 as="span" 703 theme="white" 704 weight="bold" 705 size="sm" 706 > 707 Reason:{' '} 708 </Text> 709 <Text as="span" theme="white" size="sm"> 710 {entry.reason} 711 </Text> 712 </div> 713 <div> 714 <Text 715 as="span" 716 theme="white" 717 weight="bold" 718 size="sm" 719 > 720 Reason by:{' '} 721 </Text> 722 <Text as="span" theme="white" size="sm"> 723 {entry.reasonAuthor || '-'} 724 </Text> 725 </div> 726 </> 727 )} 728 </div> 729 } 730 > 731 <span className="flex cursor-default">{badge}</span> 732 </Tooltip> 73 … (3591 more characters not kept)
19. search_code repo=cleopatra, text=toLogStatus · 258 chars back
apps/sense/src/modules/studies/hooks/training-log-mappers.ts 162: const toLogStatus = (status?: string): TrainingLogStatus => { 185: const normalized = toLogStatus(status); 267: toLogStatus(assignee.status) === 'Removed' ? undefined : assignee.dueDate;
20. commits repo=cleopatra, path=apps/sense/src/modules/studies/hooks/training-log-mappers.ts, since=2026-11-01T00:00:00Z · 245 chars back
beac1f8a3 2026-11-13T17:02 ramyala: Trainings: split Team Trainings into Org Trainings and Study Trainings (ENG-8591) (#16777) a3ce2a6d0 2026-11-13T08:51 ramyala: Trainings: tab counts, progress bars, and training log and slideover nits (#16776)
21. read_file repo=cleopatra, path=apps/sense/src/modules/studies/hooks/training-log-mappers.ts, start_line=180, end_line=300 · 5154 chars back
apps/sense/src/modules/studies/hooks/training-log-mappers.ts (357 lines), lines 180-300: 180 181 export const normalizeStatus = ( 182 status?: string, 183 dueDate?: string 184 ): TrainingLogStatus => { 185 const normalized = toLogStatus(status); 186 const isUnfinished = normalized === 'Pending' || normalized === 'In progress'; 187 return isUnfinished && isPastDue(dueDate) ? 'Overdue' : normalized; 188 }; 189 190 /** Pass/fail is only scored for the training as a whole, so a finished section is just Completed. */ 191 export const normalizeSectionStatus = ( 192 status?: string, 193 dueDate?: string 194 ): TrainingLogStatus => { 195 const normalized = normalizeStatus(status, dueDate); 196 return normalized === 'Passed' ? 'Completed' : normalized; 197 }; 198 199 const nonEmptyStrings = (values: (string | undefined)[]): string[] => 200 values.filter((v): v is string => !!v); 201 202 /** Role codes (e.g. "crc") come back raw from the backend; format for display. */ 203 const humanRoles = (roles: (string | undefined)[]): string[] => 204 nonEmptyStrings(roles).map(roleTitleToHumanString); 205 206 /** 207 * One envelope trainee = one row. The server already groups a trainee's 208 * sites and returns only real assignments, so there is no per-site 209 * regrouping or placeholder filtering left to do here. 210 */ 211 export const mapLogTrainee = ( 212 trainee: TrainingLogTraineeDto 213 ): TrainingLogTrainee => { 214 const entries: TrainingLogEntry[] = ( … (3654 more characters not kept)
22. read_file repo=cleopatra, path=apps/sense/src/components/trainings/training-log.tsx, start_line=830, end_line=1000 · 6425 chars back
apps/sense/src/components/trainings/training-log.tsx (1141 lines), lines 830-1000: 830 831 return [traineeColumn, ...groupColumns, ...stepColumns, ...trailingColumns]; 832 }, [ 833 trainings, 834 isStepView, 835 studyId, 836 navigate, 837 pushBreadcrumb, 838 expandedUserIds, 839 loadingUserIds 840 ]); 841 842 // Only Trainees stays pinned — the step view added enough trailing columns 843 // (Overall/Assigned/Due/Completed/Reason) that pinning them too left no 844 // room for the step columns; letting everything but Trainees scroll 845 // horizontally is preferable to squeezing every column onscreen at once. 846 const gridPinnedColumns = useMemo(() => ({ left: ['trainee'] }), []); 847 848 const trainingName = 849 logQuery.data.trainings.find((t) => t.id === trainingId)?.name ?? 850 'Training'; 851 852 const cardView = ( 853 <ScrollView ref={cardsScrollRef} className="mt-16"> 854 <div 855 className="relative" 856 style={{ height: cardVirtualizer.getTotalSize() }} 857 > 858 {cardVirtualizer.getVirtualItems().map((virtualItem) => { 859 const item = cardItems[virtualItem.index]; 860 return ( 861 <div 862 key={virtualItem.key} 863 ref={cardVirtualizer.measureElement} 864 data-index={virtualItem.index} 865 className={cx( 866 'absolute inset-x-0 top-0', 867 // A hea … (4925 more characters not kept)
23. search_code repo=cleopatra, text=mapStatus · 449 chars back
packages/api/hooks/useStudyTrainingTraineesQuery.ts 107: const mapStatus = (status: string | undefined): TrainingTrainee['status'] => { 146: status: mapStatus(assignee.status), apps/sense/src/modules/studies/hooks/training-log-mappers.ts 165: // Mirrors mapStatus in useStudyTrainingTraineesQuery.ts, which reads this apps/sense/src/modules/studies/hooks/useTrainingLogQuery.ts 34: // values ('InProgress', 'Init') — same mismatch mapStatus/
24. read_file repo=cleopatra, path=e2e/pages/visitExecution/visitExecStudy.page.js, start_line=540, end_line=665 · 5686 chars back
e2e/pages/visitExecution/visitExecStudy.page.js (5186 lines), lines 540-665: 540 .first(); 541 this.trainingBackButton = page.getByTestId('training-task-back-button'); 542 this.fillDocButton = page 543 .locator('[data-field-type="marker-field"]') 544 .filter({ hasText: 'Fill' }); 545 this.studiesBreadcrumb = page.getByTestId('studies-breadcrumb'); 546 547 // Study trainings tab and its category tabs 548 this.studyTrainingsTab = page.getByTestId('app-header-study-trainings-tab'); 549 this.allTrainingTab = page.locator( 550 '[data-testid*="study-trainings-list-tab-tab"]' 551 ); 552 this.studyTeamTrainingLogTab = page.locator( 553 '[data-testid*="study-trainings-team-log-tab-tab"]' 554 ); 555 this.siteTrainingLogTab = page.locator( 556 '[data-testid*="study-trainings-site-log-tab-tab"]' 557 ); 558 this.myTrainingTab = page.locator( 559 '[data-testid*="study-trainings-mine-tab-tab"]' 560 ); 561 // My Trainings table 562 this.myTrainingsTable = page.getByTestId('study.trainings-mine.table'); 563 this.myTrainingRow = (trainingName) => 564 this.myTrainingsTable.getByRole('row', { 565 name: new RegExp(trainingName) 566 }); 567 // Study Team / Site Training Log (table view: one card per trainee) 568 this.trainingLogSearch = page.getByTestId('trainings-log-grid-search'); 569 this.trainingLogTableViewToggle = page.getByTestId( 570 'trainings-lo … (4186 more characters not kept)
25. read_file repo=cleopatra, path=apps/sense/src/modules/studies/hooks/useTrainingLogQuery.ts, start_line=1, end_line=70 · 2716 chars back
apps/sense/src/modules/studies/hooks/useTrainingLogQuery.ts (559 lines), lines 1-70: 1 import { useCallback, useMemo } from 'react'; 2 import { 3 useQueries, 4 useQuery, 5 skipToken, 6 type UseQueryResult 7 } from '@tanstack/react-query'; 8 import { 9 fetchAllStudyTrainingLog, 10 fetchAllTrainingAssignees, 11 fetchAllTrainingAssigneesWithSections, 12 fetchStudyTrainingLog, 13 fetchTrainingAssignees, 14 TrainingAssigneeFilterParams, 15 TrainingScope, 16 trainingScopeKey 17 } from 'api'; 18 import { useDebounce } from 'ui'; 19 import { 20 buildStepColumns, 21 mapLogTrainee, 22 mapStepLogAssignee, 23 TrainingLogStatus, 24 TrainingLogStatusFilter, 25 TrainingLogTraining, 26 TrainingLogTrainee, 27 TRAINING_LOG_STATUSES 28 } from './training-log-mappers'; 29 30 export * from './training-log-mappers'; 31 32 // `TrainingLogStatus` is a display label ('In progress', 'Pending'), but the 33 // PA status values normalizeStatus reads back from the API are raw enum 34 // values ('InProgress', 'Init') — same mismatch mapStatus/ 35 // TrainingTrainee['status'] guards against elsewhere. 'Overdue' has no 36 // backend equivalent (see TrainingEntryStatusCounts.overdue): due date having 37 // passed is a client-side read, not a status the server tracks, so filtering 38 // by it can't match anything server-side. 39 const STATUS_TO_RAW: Record<TrainingLogStatus, string> = { 40 Passed: 'Completed,CompletedOffline', 41 Completed: 'Completed,CompletedOffl … (1216 more characters not kept)
26. commits repo=cleopatra, path=apps/sense/src/components/trainings/training-log.tsx, since=2026-11-13T00:00:00Z · 245 chars back
beac1f8a3 2026-11-13T17:02 ramyala: Trainings: split Team Trainings into Org Trainings and Study Trainings (ENG-8591) (#16777) a3ce2a6d0 2026-11-13T08:51 ramyala: Trainings: tab counts, progress bars, and training log and slideover nits (#16776)

What it was shown (build 881, 47.1 KB)

The run
{ "job": "e2e-tests-master", "build": 881, "kind": "ui-tests", "result": "UNSTABLE", "started": "2026-11-16T08:54:38Z", "tests": 714, "failed": 36, "test_commit": "de78c7210", "branch": "master", "cluster_prepared": { "mode": "verify", "result": "ready", "product_commit": "82fca18" } }
services
[ "docsvc", "execsvc", "patientsvc", "schedsvc", "enrollsvc", "studiosvc", "finsvc", "notifsvc", "dslsvc", "authz", "dashQL", "dashRsvc", "regsvc", "advpsvc", "workplansvc", "datasvc", "payoutsvc", "tusker", "authsvc", "eventsvc", "ehrsvc", "docproc", "studioai", "sense" ]
The cluster during the run
{ "cluster": "automation", "findings_opened_around_the_run": [ { "kind": "error.novel", "severity": "critical", "subject": "execsvc", "title": "execsvc: a new error shape, 5\u00d7 in the last hour, never seen in 90 days (Request completed \u2014 ? \u00b7 {?:\" failed to create Actor for Study ? Actor )", "opened_minutes_after_run_start": -38 }, { "kind": "error.novel", "severity": "critical", "subject": "execsvc", "title": "execsvc: a new error shape, 5\u00d7 in the last hour, never seen in 90 days (Request completed \u2014 ? \u00b7 {?:\" failed to create Actor for Study ? Actor )", "opened_minutes_after_run_start": -38 }, { "kind": "error.novel", "severity": "critical", "subject": "docproc", "title": "docproc: a new error shape, 6\u00d7 in the last hour, never seen in 90 days (Failed to create document processing AIRun \u2014 aborting pipeline (refuse)", "opened_minutes_after_run_start": -38 }, { "kind": "error.novel", "severity": "critical", "subject": "docproc", "title": "docproc: a new error shape, 5\u00d7 in the last hour, never seen in 90 days (Recovery failed \u2014 AIRun creation failed for document ? (document proce)", "opened_minutes_after_run_start": -38 }, { "kind": "error.novel", "severity": "warning", "subject": "execsvc", "title": "execsvc: a new error shape, 5\u00d7 in the last hour, never seen in 90 days (failed to find study protocol for study study ? site ?: bad status of )", "opened_minutes_after_run_start": 85 }, { "kind": "error.novel", "severity": "warning", "subject": "execsvc", "title": "execsvc: a new error shape, 10\u00d7 in the last hour, never seen in 90 days (failed to create Actor for Study error: user ? is not a member of orga)", "opened_minutes_after_run_start": -38 }, { "kind": "error.novel", "severity": "warning", "subject": "execsvc", "title": "execsvc: a new error shape, 10\u00d7 in the last hour, never seen in 90 days (failed to create Actor for Study \u2014 user ? is not a member of organizat)", "opened_minutes_after_run_start": -38 }, { "kind": "error.novel", "severity": "warning", "subject": "virtual-assistant", "title": "virtual-assistant: a new error shape, 23\u00d7 in the last hour, never seen in 90 days ([PlaceholderMatch][placeholder_id=?] Failed to record match: Failed to)", "opened_minutes_after_run_start": 12 } ], "long_standing_findings_left_out": 25, "pods_in_trouble_during_the_run": [], "deploys_during_the_run": [] }
The group
{ "tests": 1, "suite": "staff", "members": [ { "test": "staff::TC-10: Verify Staff Training entries in Study Team Training Log", "pattern": "new", "meaning": "first seen failing", "newest_first": "F", "failing_in_a_row": 1, "this_error_in_a_row": 1, "this_error_since_build": 881, "failing_since_build": 881, "last_passed_build": null } ] }
The failure
{ "test": "staff::TC-10: Verify Staff Training entries in Study Team Training Log", "status": "failed", "message": "expect(locator).toHaveText(expected) failed", "traceback_tail": "\n at pages/visitExecution/visitExecStudy.page.js:692\n\n 690 | if (entry.status !== undefined) {\n 691 | logger.info(`Training log: ${traineeName} status is ${entry.status}`);\n > 692 | await expect.soft(cells.status).toHaveText(entry.status);\n | ^\n 693 | }\n 694 | if (entry.assignedBy !== undefined) {\n 695 | logger.info(\n at VisitStudiesPage.expectTrainingLogEntries (/home/jenkins/agent/workspace/ui-tests-master/e2e/pages/visitExecution/visitExecStudy.page.js:692:41)\n at /home/jenkins/agent/workspace/ui-tests-master/e2e/tests/training/staff.spec.js:217:5\n\n TimeoutError: page.waitForResponse: Timeout 50000ms exceeded while waiting for event \"response\"\n\n at utils/apiUtility/visitApiUtility.js:224\n\n 222 | */\n 223 | static waitForTrainingLogSearch(page, search) {\n > 224 | return page.waitForResponse((response) => {\n | ^\n 225 | const url = new URL(response.url());\n 226 | return (\n 227 | response.request().method() === 'GET' &&\n at VisitApiUtil.waitForTrainingLogSearch (/home/jenkins/agent/workspace/ui-tests-master/e2e/utils/apiUtility/visitApiUtility.js:224:17)\n at VisitStudiesPage.searchTrainingLog (/home/jenkins/agent/workspace/ui-tests-master/e2e/pages/visitExecution/visitExecStudy.page.js:640:24)\n at /home/jenkins/agent/workspace/ui-tests-master/e2e/tests/training/staff.spec.js:242:5\n\n attachment #1: screenshot (image/png) \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n reports/staff-Staff-Doc-Training-T-90cc7--in-Study-Team-Training-Log-training-retry1/test-failed-1.png\n \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n\n attachment #2: video (video/webm) \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n reports/staff-Staff-Doc-Training-T-90cc7--in-Study-Team-Training-Log-training-retry1/video.webm\n \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n\n Error Context: reports/staff-Staff-Doc-Training-T-90cc7--in-Study-Team-Training-Log-training-retry1/error-context.md\n\n attachment #5: trace (application/zip) \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n reports/staff-Staff-Doc-Training-T-90cc7--in-Study-Team-Training-Log-training-retry1/trace.zip\n Usage:\n\n yarn playwright show-trace reports/staff-Staff-Doc-Training-T-90cc7--in-Study-Team-Training-Log-training-retry1/trace.zip\n\n \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500", "requests": [ { "trace_id": "e2e7e5789a53701989c44572eeed948a", "method": "GET", "path": "/api/myprofile/v2", "status": "None", "error": "net::ERR_ABORTED" }, { "trace_id": "e2e7e5789a53701989c4457b9e301e42", "method": "GET", "path": "/api/trialexec/v2/study/ef7d1982-9fd0-46f6-aaed-10958a2fbac6/training/assignees", "status": "200", "error": "None" }, { "trace_id": "e2e7e5789a53701989c4457748eef429", "method": "POST", "path": "/api/myprofile/stillActive", "status": "200", "error": "None" }, { "trace_id": "e2e7e5789a53701989c445796feaa4e6", "method": "POST", "path": "/api/journey", "status": "204", "error": "None" }, { "trace_id": "e2e7e5789a53701989c44573601774a2", "method": "POST", "path": "/api/journey", "status": "204", "error": "None" }, { "trace_id": "e2e7e5789a53701989c4457805251254", "method": "GET", "path": "/api/studio/events", "status": "200", "error": "None" } ], "errors_the_services_logged_for_these_requests": "none: no service logged an error under these requests' trace ids", "raised_at": "e2e/pages/visitExecution/visitExecStudy.page.js:692", "code_frame": " at pages/visitExecution/visitExecStudy.page.js:692\n\n 690 | if (entry.status !== undefined) {\n 691 | logger.info(`Training log: ${traineeName} status is ${entry.status}`);\n> 692 | await expect.soft(cells.status).toHaveText(entry.status);\n | ^\n 693 | }\n 694 | if (entry.assignedBy !== undefined) {\n 695 | logger.info(", "playwright_call_log": [ "- Expect \"soft toHaveText\" getByRole('row').filter({ hasText: 'Staff Training - 1794822609523' }).locator('td[data-column-id=\"status\"]') with timeout 50000ms", "- waiting for getByRole('row').filter({ hasText: 'Staff Training - 1794822609523' }).locator('td[data-column-id=\"status\"]')", "- unexpected value \"In Progress\"" ], "attempts": { "errors": [ "Error: expect(locator).toHaveText(expected) failed", "Error: expect(locator).toHaveText(expected) failed" ], "note": "every attempt failed the same way: deterministic, not a race" } }
Console lines about this test
{ "from": "console.log", "lines": [ "5061: INFO Check partner does not appear in the list", "5062: INFO \u2713 383 [study] \u203a tests/study/partners.spec.js:75:3 \u203a Study Partners \u203a Verify removing an approved partner from the study (32.6s)", "5063: INFO Uploaded training certificate file: TBUTCertificate-807908.pdf", "5064: INFO \u2718 373 [training] \u203a tests/training/staff.spec.js:212:3 \u203a Staff Doc Training \u203a TC-10: Verify Staff Training entries in Study Team Training Log (2.5m)", "5065: INFO - 387 [training] \u203a tests/training/staff.spec.js:248:3 \u203a Staff Doc Training \u203a TC-11: Verify training status and check override options on CRO side", "5066: INFO - 388 [training] \u203a tests/training/staff.spec.js:282:3 \u203a Staff Doc Training \u203a TC-12: Verify Study Team Training Log after reassign and unassign", "5067: INFO Finding user with role Cro Pm", "\u2026", "5802: INFO Selecting Study Automation Test Study 1794822929831 and compliance tab", "5803: INFO The recruiter sees only the two studies they are on", "5804: INFO \u2713 441 [study] \u203a tests/study/studiesList.spec.js:58:3 \u203a Studies list \u203a TC-STD-101: My studies lists only the studies a member is on (11.6s)", "5805: INFO \u2718 428 [training] \u203a tests/training/staff.spec.js:212:3 \u203a Staff Doc Training \u203a TC-10: Verify Staff Training entries in Study Team Training Log (retry #1) (2.7m)", "5806: INFO - 445 [training] \u203a tests/training/staff.spec.js:248:3 \u203a Staff Doc Training \u203a TC-11: Verify training status and check override options on CRO side (retry #1)", "5807: INFO Re-entered the AI Teammates app", "5808: INFO Selected study Automation Test Study 1794822929831", "\u2026", "14706: INFO attachment #2: video (video/webm) \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500", "14707: INFO Error Context: reports/regular-Regular-Training-T-ff016-lar-training-activity-as-PI-training-retry1/error-context.md", "14708: INFO yarn playwright show-trace reports/regular-Regular-Training-T-ff016-lar-training-activity-as-PI-training-retry1/trace.zip", "14709: INFO 13) [training] \u203a tests/training/staff.spec.js:212:3 \u203a Staff Doc Training \u203a TC-10: Verify Staff Training entries in Study Team Training Log", "14710: INFO Error: expect(locator).toHaveText(expected) failed", "14711: INFO Locator: getByRole('row').filter({ hasText: 'Staff Training - 1794822055211' }).locator('td[data-column-id=\"status\"]')", "14712: INFO Expected: \"In progress\"", "\u2026", "15462: INFO [workplan] \u203a tests/workplan/feasibilityWorkPlan.spec.js:148:3 \u203a AI Teammates - Feasibility Work Plan \u203a TC-03: Create a work plan from the feasibility template with documents and form attached", "15463: INFO [workplan] \u203a tests/workplan/feasibilityWorkPlan.spec.js:360:3 \u203a AI Teammates - Feasibility Work Plan \u203a TC-05: Every milestone of a published work plan is listed and starts progressing", "15464: INFO [training] \u203a tests/training/regular.spec.js:182:3 \u203a Regular Training \u203a TC-07: Verify completing regular training activity as PI", "15465: INFO [training] \u203a tests/training/staff.spec.js:212:3 \u203a Staff Doc Training \u203a TC-10: Verify Staff Training entries in Study Team Training Log", "15466: INFO [training] \u203a tests/training/tbut.spec.js:149:3 \u203a TBUT Training \u203a TC-07: Verify completing training activity as PI", "15467: INFO [study] \u203a tests/study/studyFeed.spec.js:77:3 \u203a Study feed \u203a TC-03: A populated feed shows the brief, sections, rows and the nav badge", "15468: INFO [study] \u203a tests/study/studyFeed.spec.js:151:3 \u203a Study feed \u203a TC-06: The row menu reminds and hides" ] }
The test's history
{ "pattern": "new", "meaning": "first seen failing", "newest_first": "F", "failing_in_a_row": 1, "this_error_in_a_row": 1, "this_error_since_build": 881 }
other_branch
{ "branch": "production", "job": "e2e-tests-production", "build": 858, "these_tests_there": { "absent": 1 }, "reading": "fails on master; this test is not in the production suite (`e2e-tests-production` build 858)." }
The test's source
{ "repo": "tildabio/cleopatra", "at": "de78c7210", "path": "e2e/tests/training/staff.spec.js", "from_line": 212, "failing_line": 212, "code": "212> test('TC-10: Verify Staff Training entries in Study Team Training Log', async ({\n213 adminCro\n214 }) => {\n215 await adminCro.searchStudy(studyName);\n216 await adminCro.openTrainingLog('team');\n217 await adminCro.expectTrainingLogEntries(trainingDetails.name, [\n218 {\n219 traineeName: dmUser.userName,\n220 status: 'Passed',\n221 assignedBy: adminTrainer.userName,\n222 completed: true\n223 },\n224 {\n225 traineeName: monitorUser.userName,\n226 status: 'In progress',\n227 assignedBy: adminTrainer.userName,\n228 completed: false\n229 },\n230 {\n231 traineeName: pmUser.userName,\n232 status: 'Passed',\n233 assignedBy: adminTrainer.userName,\n234 completed: true\n235 }\n236 ]);\n237 \n238 logger.info(\n239 'Verifying the study team training is not in the Site Training Log'\n240 );\n241 await adminCro.openTrainingLog('site');\n242 await adminCro.searchTrainingLog(dmUser.userName);\n243 await expect(\n244 adminCro.trainingLogEntryRow(trainingDetails.name)\n245 ).toHaveCount(0);\n246 });\n247 \n248 test('TC-11: Verify training status and check override options on CRO side', async ({\n249 trainingPage\n250 }) => {\n251 await trainingPage.searchStudy(studyName);\n252 await trainingPage.studyTrainingsTab.click();\n253 await trainingPage.allTrainingTab.click();\n254 await expect(trainingPage.trainingsSearch).toBeVisible();\n255 await trainingPage.openTraining(trainingDetails.name);\n256 await expect(\n257 trainingPage.trainingSlideover\n258 .getByRole('tab', { name: 'Trainees' })\n259 .getByText('3')\n260 ).toBeVisible();\n261 \n262 logger.info('Reassigning completed Cro Dm training');\n263 await trainingPage.selectTraineeAction(\n264 dmUser.userName,\n265 'Reassign Training'\n266 );\n267 logger.info('Unassigning completed Cro Monitor training');\n268 await trainingPage.selectTraineeAction(\n269 monitorUser.userName,\n270 'Unassign training'\n271 );\n272 await trainingPage.verifyTraineesInSidePanel([\n273 { name: dmUser.userName, status: 'Pending' }\n274 ]);\n275 await expect(\n276 trainingPage.trainingSlideover\n277 .getByRole('tab', { name: 'Trainees' })\n278 .getByText('2')\n279 ).toBeVisible();\n280 });\n281 \n282 test('TC-12: Verify Study Team Training Log after reassign and unassign', async ({" }
The page when it failed
{ "what": "Playwright's accessibility snapshot of the page at the moment the test gave up (error-context.md): what was really on screen", "snapshot": "# Instructions\n\n- Following Playwright test failed.\n- Explain why, be concise, respect Playwright best practices.\n- Provide a snippet of code with the fix, if possible.\n\n# Test info\n\n- Name: tests/training/staff.spec.js >> Staff Doc Training >> TC-10: Verify Staff Training entries in Study Team Training Log\n- Location: tests/training/staff.spec.js:212:3\n\n# Error details\n\n```\nError: expect(locator).toHaveText(expected) failed\n\nLocator: getByRole('row').filter({ hasText: 'Staff Training - 1794822055211' }).locator('td[data-column-id=\"status\"]')\nExpected: \"In progress\"\nReceived: \"In Progress\"\nTimeout: 50000ms\n\nCall log:\n - Expect \"soft toHaveText\" getByRole('row').filter({ hasText: 'Staff Training - 1794822055211' }).locator('td[data-column-id=\"status\"]') with timeout 50000ms\n - waiting for getByRole('row').filter({ hasText: 'Staff Training - 1794822055211' }).locator('td[data-column-id=\"status\"]')\n 100 \u00d7 locator resolved to <td data-column-id=\"status\">\u2026</td>\n - unexpected value \"In Progress\"\n\n```\n\n```yaml\n- cell \"In Progress\"\n```\n\n```\nTimeoutError: page.waitForResponse: Timeout 50000ms exceeded while waiting for event \"response\"\n```\n\n# Test source\n\n```ts\n \u2026\n 187 | status: 'Completed',\n \u2026\n | ^ TimeoutError: page.waitForResponse: Timeout 50000ms exceeded while waiting for event \"response\"\n \u2026\n 269 | const onFailed = (request) => {\n \u2026\n 271 | failures.push(`${request.url()} \u2014 ${request.failure()?.errorText}`);\n \u2026\n 277 | if (isActivitySave(request) && response.status() >= 400) {\n 278 | failures.push(`${request.url()} \u2014 HTTP ${response.status()}`);\n \u2026\n 284 | page.on('requestfailed', onFailed);\n \u2026\n 305 | page.off('requestfailed', onFailed);" }
The code where it failed
{ "path": "e2e/pages/visitExecution/visitExecStudy.page.js", "failing_line": 692, "code": "667 * - `status` \u2014 log copy, e.g. 'Passed', 'In progress', 'Pending', 'Failed'\n668 * - `assignedBy`, `reasonBy` \u2014 user names\n669 * - `completed` \u2014 true: a completion date is shown; false: it is empty\n670 * - `reason` \u2014 force-completion reason; '' asserts it is empty\n671 *\n672 * @param {string} trainingName\n673 * @param {{ traineeName: string, absent?: boolean, status?: string, assignedBy?: string,\n674 * completed?: boolean, reason?: string, reasonBy?: string }[]} entries\n675 */\n676 async expectTrainingLogEntries(trainingName, entries) {\n677 for (const entry of entries) {\n678 const { traineeName } = entry;\n679 await this.searchTrainingLog(traineeName);\n680 \n681 if (entry.absent) {\n682 logger.info(\n683 `Training log: ${traineeName} has no \"${trainingName}\" entry`\n684 );\n685 await expect(this.trainingLogEntryRow(trainingName)).toHaveCount(0);\n686 continue;\n687 }\n688 \n689 const cells = this.trainingLogEntry(trainingName);\n690 if (entry.status !== undefined) {\n691 logger.info(`Training log: ${traineeName} status is ${entry.status}`);\n692> await expect.soft(cells.status).toHaveText(entry.status);\n693 }\n694 if (entry.assignedBy !== undefined) {\n695 logger.info(\n696 `Training log: ${traineeName} assigned by ${entry.assignedBy}`\n697 );\n698 await expect.soft(cells.assignedBy).toHaveText(entry.assignedBy);\n699 }\n700 if (entry.completed !== undefined) {\n701 logger.info(\n702 `Training log: ${traineeName} completion date ${entry.completed ? 'shown' : 'empty'}`\n703 );\n704 if (entry.completed) {" }
Commits in the window
{ "note": "no last pass and first failure are on record for these tests, so there is no window of commits to look in" }
The issue as the agent wrote it
**Fix is in:** not known yet. **What failed:** `expect(locator).toHaveText(expected) failed` **On screen when it failed:** The Study Team Training Log table shows the trainee's status cell as "In Progress" (capital P). ![The page when the test failed](https://uploads.linear.app/d1b9dc36-3ae8-49c0-8ea8-02f9d1566efc/2968aa4e-2117-4e43-b09c-3144ad9667f8/bdd39bdd-7141-4dc3-98ca-cf19ba8c3074) **Cause not clear**, confidence low. Found in `e2e-tests-master` build 881: [run in X-ray](https://xray.tilda.pizza/tests/run/e2e-tests-master/881). **Root cause in X-ray:** [the verdict, each test's history and the evidence the agent read](https://xray.tilda.pizza/test-triage/7cd336fbe6cb0e) **Branches:** fails on master; this test is not in the production suite (`e2e-tests-production` build 858). TC-10 (new in de78c7210, first run) fails because the log's status cell shows "In Progress" and the test expects "In progress" (visitExecStudy.page.js:692, spec line 227). The source I read renders "In progress": toLogStatus in training-log-mappers.ts:171, shown by the Badge in useTrainingLogColumns.tsx:77. e2e/knowledge/training.md:22, verified 15 Nov, says the same. I found no commit that changed the label and no place in the source that produces a capital P in this log. So the deployed build (product_commit 82fca18) and the default-branch source seem to disagree. I could not confirm this from here. Second error, probably a knock-on: after the soft failure the test goes on to line 242, where waitForTrainingLogSearch times out at visitApiUtility.js:224 (50 s waiting for the site-log search response). Both retries failed the same way, so it is deterministic and not a race. Next: open the Study Team Training Log in Table view on the cluster and read the monitor's status. If it is "In Progress", find which FE build produces it. If the capital P is intended, change the test and the notes to "In Progress". If not, it is a product regression. No cluster pod or deploy trouble ties to this test, and no service logged an error under its requests. **Service:** sense **Assigned to:** [email protected] (last changed visitExecStudy.page.js (de78c7210)). ### Steps to reproduce 1. Sign in as Test Admin in the CRO org (Tilda CRO). 2. Use a CRO study with a team-scope staff training assigned to Cro Dm, Cro Monitor and Cro Pm. Dm and Pm must have completed it and Monitor must be part-way through. 3. Open the study and go to the Trainings tab, then Study Team Training Log. 4. Switch the view to Table (the log opens in Grid). 5. Type the Cro Monitor user's name in the search box and wait for the list to narrow to one card. 6. Read the Status cell of the staff training row. 7. Expected: "In progress", as in training-log-mappers.ts and the 15 Nov notes; actual: "In Progress". **Failing tests (1):** - [staff::TC-10: Verify Staff Training entries in Study Team Training Log](https://xray.tilda.pizza/tests/case/3486b23fd70e1973) (first time seen) **Error:** ``` expect(locator).toHaveText(expected) failed ``` +++ Agent notes Filed by X-ray's triage agent. Models asked: claude-sonnet-5-5; settled by deep; 26 lookups in the code and its history. Group `triage:7cd336fbe6cb0e` (one issue per root cause). A wrong verdict can be corrected on the run page in X-ray. +++