Skip to content

Conversation

@simonw
Copy link
Owner

@simonw simonw commented Dec 17, 2025

Claude Code: https://gistpreview.github.io/?c06c3d848c55b674955cd29a3f368dd1

take a look at 695.diff and think about what it might take to apply that (it no longer applies cleanly)

Refs:


📚 Documentation preview 📚: https://sqlite-utils--697.org.readthedocs.build/en/697/

simonw and others added 2 commits December 16, 2025 21:31
- mypy.ini: expanded configuration with module-specific settings
- hookspecs.py: type annotations for hook functions
- plugins.py: typed get_plugins() return value
- recipes.py: full type annotations for parsedate, parsedatetime, jsonsplit
- utils.py: extensive type annotations including Row type alias,
  TypeTracker, ValueTracker, and all utility functions
- db.py: type annotations for Database methods (__exit__,
  ensure_autocommit_off, tracer, register_function, etc.) and
  Queryable class methods
- tests/test_docs.py: updated to match new signature display format

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Add type: ignore comments for external library type stub limitations
  (csv.reader, click.progressbar, IOBase.name, Callable.__name__)
- Change Iterable to Sequence for SQL where_args parameters
- Use db.table() instead of db[name] for proper Table return type
- Fix rebuild_fts return type from None to Table
- Update test_tracer to expect fewer queries (optimization side effect)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@codecov
Copy link

codecov bot commented Dec 17, 2025

Codecov Report

❌ Patch coverage is 99.23664% with 1 line in your changes missing coverage. Please review.
✅ Project coverage is 95.15%. Comparing base (8710385) to head (8d185d4).
⚠️ Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
sqlite_utils/db.py 97.91% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #697      +/-   ##
==========================================
+ Coverage   95.12%   95.15%   +0.02%     
==========================================
  Files           8        8              
  Lines        3100     3114      +14     
==========================================
+ Hits         2949     2963      +14     
  Misses        151      151              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

- Add type: ignore comments for runtime-valid patterns mypy can't verify
- Fix new_column_types annotation to Dict[str, Set[type]]
- Add type: ignore for Default sentinel values passed to create_table

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Comment on lines +62 to +64
# Type alias for row dictionaries - values can be various SQLite-compatible types
RowValue = Union[None, int, float, str, bytes, bool]
Row = Dict[str, RowValue]
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is nice.

@simonw
Copy link
Owner Author

simonw commented Dec 17, 2025

Claude Code transcript for mypy fixes: https://gistpreview.github.io/?deaab4ddeb6974a5b056d80d2f875b6e

simonw and others added 2 commits December 16, 2025 21:50
- Add Callable and Optional to exclusion list in _generate_convert_help()
- Regenerate docs/cli-reference.rst with cog
- Add [mypy-tests.*] ignore_errors = True to skip test type errors

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@simonw
Copy link
Owner Author

simonw commented Dec 17, 2025

@simonw simonw merged commit 8d74ffc into main Dec 17, 2025
90 checks passed
@simonw simonw deleted the type-hints branch December 17, 2025 06:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants