Repository navigation
6.0.0
SwiftStore now resolves query columns from metadata generated by @Entity, fixing key-path queries that could produce invalid SQL in optimized builds. The existing filter(\.id == id), ordering, projection and update DSL remains unchanged.
Changes:
- Generate explicit property-to-column mappings from the same declarations as the schema and SQLite codec, without parsing key-path debug descriptions.
- Use declared identity columns for CRUD, including single-field
#SyncKeyaliases and composite identities. - Reject unmapped query properties before executing SQL.
- Keep single-key batch queries as
INexpressions. - Preserve the encoded Swift property names in nested JSON paths for both ordinary and full-text indexes; SQL column names remain snake_case.
Breaking API changes:
- Direct calls to
columnName(for:)andColumn.namenow requiretry. - Handwritten
EntityProtocolimplementations must providecolumnName(for:)for key-path queries; composite identities also requiresqliteIdentityValues(for:)insyncKeyColumnsorder. - Previously generated nested JSON indexes using snake_case JSON paths are not automatically migrated. This release adds no compatibility fallback.
Validation completed during implementation: full Debug tests and focused Release regression tests, including generic ID access, composite keys, invalid mappings, bulk ID queries and camelCase JSON index updates. The release workflow builds the macOS arm64 CLI and verifies the packaged and published artifacts.