You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Firebase SDK version: 4.9.0 (also appears to be a problem for 4.8.0)
Firebase Component: Firestore
Component version: 0.10.1 (also appears to be a problem for 0.9.4)
Steps to reproduce:
When multiple "Missing or insufficient permissions" errors occur in quick succession, the client stops successfully writing to Firestore, and apparently stops trying to.
I'll provide specific code later, but the outline is:
Set up rules with a collection that can't be written to, foo, and a collection that can be written to, bar.
Write something to "bar" to confirm you can.
In a loop, write something to "foo" three times.
Confirm you can no longer write to "bar", or even get a callback with an error from attempting to write to "foo".
Relevant Code:
Firestore rules:
service cloud.firestore {
match /databases/{database}/documents {
match /bar/{id} {
allow read, write: if true;
}
match /foo/{id} {
allow read, write: if false;
}
}
}
Code:
Take quickstart-ios's firestore "FriendlyEats" quickstart.
Replace the following two functions in RestaurantsTableViewController as follows:
Thanks very much for the detailed report. We found this issue ourselves a few days ago and the fix was checked in as #810. There was indeed a race condition when rapidly doing writes after a permission denied failure. The fix should be included in the next Firebase iOS SDK release. Thanks again and sorry for your trouble!
Steps to reproduce:
When multiple "Missing or insufficient permissions" errors occur in quick succession, the client stops successfully writing to Firestore, and apparently stops trying to.
I'll provide specific code later, but the outline is:
Relevant Code:
Firestore rules:
Code:
This bug appears to be independent of whether offline persistence is enabled.
Start the app, and log in.
Click "populate" and check your database to confirm that something was written in the "bar" collection.
Click "filter" and confirm that you get a bunch of "Missing or insufficient permissions" errors.
Click "populate" and "filter" and confirm that you don't get any more callbacks or any database writes; just "X button tapped" log messages.
The text was updated successfully, but these errors were encountered: