8000 fix(search): satisfy mypy on the text index sync at startup by adeelahmad · Pull Request #178 · adeelahmad/lense · GitHub
[go: up one dir, main page]

Skip to content

fix(search): satisfy mypy on the text index sync at startup - #178

Merged
adeelahmad merged 1 commit into
mainfrom
claude/project-thread-gtjiy6-mypy
Oct 5, 2026
Merged

adeelahmad merged 1 commit into
mainfrom
claude/project-thread-gtjiy6-mypy

Conversation

@adeelahmad
Copy link
Copy Markdown
Owner

Requested by Adeel · project thread

Before: main fails the backend CI job's type check (app/core/runtime.py:52: Item "None" of "Any | None" has no attribute "sync"), added in #166 while the runner was down, so the backend tests never run.

After: the type check passes and the startup text-index sync returns early when there is no SQLite index (the caller already only starts it when one exists, so behaviour is unchanged).

How: read self.db.textindex into a local and bail out when it is None before calling sync().

Local CI (ci/local-ci.sh, a faithful replay of ci.yml) on this head: FastAPI (embedded SurrealDB) passes, lint, mypy, OpenAPI drift and all tests, in 471 s.

🤖 Generated with Claude Code

https://claude.ai/code/session_016Z1gJcSd2Kp39i5j5KZivi


Generated by Claude Code

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_016Z1gJcSd2Kp39i5j5KZivi
@adeelahmad adeelahmad self-assigned this Oct 5, 2026
@adeelahmad
adeelahmad merged commit 2f08afe into main Oct 5, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

0