-
Notifications
You must be signed in to change notification settings - Fork 33
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Is there an existing issue?
- [ x] I have searched existing issues
Build info
- ObjectBox version: 4.4.1
- OS: running on macOS 15.7, project targets iOS 17
- Device/chipset: M1 Pro
Steps to reproduce
- Reintegrate Cocoapods from existing project, remove all files and build step for auto generation
- Add objectbox SPM
- Ensured I don't have any Folders, only Groups
- Run ObjectBoxGeneratorCommand plugin
Expected behavior
Source files are correctly autogenerated
Actual behavior
All enttiy data is removed from the EntityInfo-*
file.
For example, cModel looks like this:
fileprivate func cModel() throws -> OpaquePointer {
let modelBuilder = try ObjectBox.ModelBuilder()
// Previously had ~15 x try SomeEntity.buildEntity(modelBuilder: modelBuilder)
modelBuilder.lastEntity(id: 27, uid: 5950384143574972928)
modelBuilder.lastIndex(id: 36, uid: 8353492716365687552)
modelBuilder.lastRelation(id: 8, uid: 5131698544966963456)
return modelBuilder.finish()
}
Logs, stack traces
Logs of the plugin:
Showing Recent Messages
working directory:
/path/to/project
tool mapping:
objectbox-generator: /path/to/packages/SourcePackages/artifacts/objectbox-swift-spm/ObjectBoxGenerator/Contents/MacOS/Sourcery [arm64-apple-macosx]
tool paths:
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin
/Applications/Xcode.app/Contents/Developer/usr/bin
/bin
/sbin
/usr/bin
/usr/sbin
No config file or project path provided or it does not exist. Using command line arguments.
Scanning sources...
Found 2217 types in 1383 files, 1383 changed from last run.
note: ObjectBox ID Model file changed: model-Target.json, creating backup file (.bak).
Loading templates...
Loaded 1 templates.
Generating code...
Finished.
Done.
2025-09-25 14:33:06.073 Sourcery[13531:935145] NetworkStorageDB:_openDBReadConnections: failed to open read connection to DB @ /Users/x/Library/Caches/$(PRODUCT_BUNDLE_IDENTIFIER)/Cache.db. Error=14. Cause=unable to open database file
2025-09-25 14:33:06.073 Sourcery[13531:935145] The read-connection to the DB=/Users/x/Library/Caches/$(PRODUCT_BUNDLE_IDENTIFIER)/Cache.db is NOT valid. Unable to determine schema version.
2025-09-25 14:33:06.073 Sourcery[13531:935145] NetworkStorageDB:_openDBWriteConnections: failed to open write connection to DB @ /Users/x/Library/Caches/$(PRODUCT_BUNDLE_IDENTIFIER)/Cache.db. Error=14. Cause=unable to open database file
2025-09-25 14:33:06.073 Sourcery[13531:935145] DEBUG: there is no SQL cache DB located at /Users/x/Library/Caches/$(PRODUCT_BUNDLE_IDENTIFIER)/Cache.db.
2025-09-25 14:33:06.073 Sourcery[13531:935145] DEBUG: there is no SQL cache DB located at /Users/x/Library/Caches/$(PRODUCT_BUNDLE_IDENTIFIER)/Cache.db-shm.
2025-09-25 14:33:06.073 Sourcery[13531:935145] DEBUG: there is no SQL cache DB located at /Users/x/Library/Caches/$(PRODUCT_BUNDLE_IDENTIFIER)/Cache.db-wal.
🟩 The plugin execution finished.
! Add the generated source file in 'generated/EntityInfo-Target.generated.swift' to the project and version control
! Add the generated model file in 'model-Target.json' to version control, this is important for ObjectBox model generation
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working