firebase-ios-sdk
firebase-ios-sdk copied to clipboard
[FR]: Disable warning [I-FST000002]: Attempting to initialize or set a @DocumentID property with a non-nil value
Description
For many of my applications I use Structs, that I also use for Firebase (Codable), to feed Views in SwiftUI.
For testing cases and other reasons, sometimes it is important for me to create static instances of those types e.g. unknown or placeholder. And to not trigger unexpected behavior I assign those static instances an ID, just to not break SwiftUI code.
However every time those static instances are initialized, I get this warning in the console
11.8.1 - [FirebaseFirestore][I-FST000002] Attempting to initialize or set a @ DocumentID property with a non-nil value: "placeholder". The document ID is managed by Firestore and any initialized or set value will be ignored. The ID is automatically set when reading from Firestore.
I surely know about the stated behavior and would like to not get that warning all the time, since it is a large portion of my console logs.
API Proposal
I would appreciate a way to suppress those warnings either by an environment variable, Info.plist key or from within the code.
Firebase Product(s)
Firestore