main is red in the typescript job: apps/app has 9 failing tests (run 22981 and the earlier ones), and that is what makes #90, #91 and #95 red.
Cause (from the CI log of run 22981, job 54139, and reproduced locally):
LocalFtp.test.tsx: since 54c40bd, useLocalFtp reads the client with useAuth(). The test renders the hook with no AuthProvider, so all 7 cases throw useAuth outside AuthProvider.
App.test.tsx: the same commit made useOfflineSync (mounted by App) call onSocketLive() from library/realtime. The test mock of that module only returned useLibraryLive, so the effect threw (No "onSocketLive" export is defined on the mock), the tree unmounted, and the sign-in and editor panel cases could not find their text.
Fix: only the two test mocks change. ../auth.js is mocked with a bare client (same pattern as FacesQueuePage.test.tsx), and the realtime mock now returns a no-op onSocketLive. No test is skipped and no product code changes.
Checked locally: apps/app typecheck passes, and vitest passes all 43 files and 148 tests (on main, 9 fail).
Update (2c77135): after main took #111 (899b45f, EHF), apps/apitest/sports.test.ts also went red on main. refreshDue now reads the six EHF club competitions, and the test's fake sites answered 404 for *.eurohandball.com (6 errors). The fake now serves an EHF season page with empty match lists, and the expected competitions list includes the six EHF entries. Checked locally against the same fake: EhfProvider.matches returns [] with no errors for all six. The API tests need Postgres with pgvector, so CI runs the full suite.
`main` is red in the **typescript** job: `apps/app` has 9 failing tests (run 22981 and the earlier ones), and that is what makes #90, #91 and #95 red.
Cause (from the CI log of run 22981, job 54139, and reproduced locally):
- `LocalFtp.test.tsx`: since 54c40bd, `useLocalFtp` reads the client with `useAuth()`. The test renders the hook with no `AuthProvider`, so all 7 cases throw `useAuth outside AuthProvider`.
- `App.test.tsx`: the same commit made `useOfflineSync` (mounted by `App`) call `onSocketLive()` from `library/realtime`. The test mock of that module only returned `useLibraryLive`, so the effect threw (`No "onSocketLive" export is defined on the mock`), the tree unmounted, and the sign-in and editor panel cases could not find their text.
Fix: only the two test mocks change. `../auth.js` is mocked with a bare client (same pattern as `FacesQueuePage.test.tsx`), and the `realtime` mock now returns a no-op `onSocketLive`. No test is skipped and no product code changes.
Checked locally: `apps/app` typecheck passes, and vitest passes all 43 files and 148 tests (on main, 9 fail).
**Update (2c77135):** after main took #111 (899b45f, EHF), `apps/api` `test/sports.test.ts` also went red on main. `refreshDue` now reads the six EHF club competitions, and the test's fake sites answered 404 for `*.eurohandball.com` (6 errors). The fake now serves an EHF season page with empty match lists, and the expected competitions list includes the six EHF entries. Checked locally against the same fake: `EhfProvider.matches` returns `[]` with no errors for all six. The API tests need Postgres with pgvector, so CI runs the full suite.
54c40bd made useLocalFtp read the signed-in client with useAuth() and made
useOfflineSync (mounted by App) subscribe through onSocketLive() from
library/realtime. The tests were not updated:
- LocalFtp.test.tsx renders the hook with no AuthProvider, so every case
threw "useAuth outside AuthProvider". It now mocks ../auth.js with a bare
client, the same way FacesQueuePage.test.tsx does. The target has no
organization, so the offline flush and local autopilot never call it.
- App.test.tsx mocks ./library/realtime.js without onSocketLive. The sync
effect threw, unmounted the tree and the sign-in and editor panel cases
could not find their text. The mock now returns a no-op subscription.
No test is skipped and no product code changes.
Detail: failed contexts: ci / typescript (pull_request)
The bot did not approve or schedule a merge for this head.
Fix the branch, approve as CTO, or close the PR. The bot re-checks on the next run.
@cto — Gitea autopilot needs a CTO decision on BitReport.pt/photoreport#107: CI is red on the PR head.
- Head: `cf2e466549c0`
- Detail: failed contexts: ci / typescript (pull_request)
- The bot did **not** approve or schedule a merge for this head.
- Fix the branch, approve as CTO, or close the PR. The bot re-checks on the next run.
<!-- gitea-autopilot-escalation kind=ci_failure sha=cf2e466549c0 -->
899b45f (#111) added the six EHF club competitions to the catalog and to
refreshDue. The fake sites in test/sports.test.ts did not know
*.eurohandball.com, so every EHF season page answered 404, refreshDue
returned six errors and "reads the Liga and FPA, and only again after six
hours" failed on main.
The fake now serves an EHF season page with its ids and empty match lists,
and the expected competitions include the six EHF ones (no fixtures yet).
spark
merged commit 06a4a9dd4a into main2026-10-21 22:53:51 +01:00
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
mainis red in the typescript job:apps/apphas 9 failing tests (run 22981 and the earlier ones), and that is what makes #90, #91 and #95 red.Cause (from the CI log of run 22981, job 54139, and reproduced locally):
LocalFtp.test.tsx: since54c40bd,useLocalFtpreads the client withuseAuth(). The test renders the hook with noAuthProvider, so all 7 cases throwuseAuth outside AuthProvider.App.test.tsx: the same commit madeuseOfflineSync(mounted byApp) callonSocketLive()fromlibrary/realtime. The test mock of that module only returneduseLibraryLive, so the effect threw (No "onSocketLive" export is defined on the mock), the tree unmounted, and the sign-in and editor panel cases could not find their text.Fix: only the two test mocks change.
../auth.jsis mocked with a bare client (same pattern asFacesQueuePage.test.tsx), and therealtimemock now returns a no-oponSocketLive. No test is skipped and no product code changes.Checked locally:
apps/apptypecheck passes, and vitest passes all 43 files and 148 tests (on main, 9 fail).Update (
2c77135): after main took #111 (899b45f, EHF),apps/apitest/sports.test.tsalso went red on main.refreshDuenow reads the six EHF club competitions, and the test's fake sites answered 404 for*.eurohandball.com(6 errors). The fake now serves an EHF season page with empty match lists, and the expected competitions list includes the six EHF entries. Checked locally against the same fake:EhfProvider.matchesreturns[]with no errors for all six. The API tests need Postgres with pgvector, so CI runs the full suite.@cto — Gitea autopilot needs a CTO decision on BitReport.pt/photoreport#107: CI is red on the PR head.
cf2e466549c0