Changes on firebase data is not reflected until reload of the items.
Hi,
When I add a new todo and then go into the firebase web UI and change the value, the value on the app isn't updated automatically. However if I reload the app then updating the old todos work fine.
Received firebase-child-changed event for unknown child "-JzoUYjzV9Ll0gOxKRI2"
Hm, I'm not able to reproduce this issue. I just went to the firebase UI and was able to update the text of one of my todos and see it reflected.
Just want to double check that you're using the bower.json from this project? The firebase dependency points at a branch of the firebase-element so that may be a possible culprit if you're not using that one
Hi,
I re-did everything, and still get the issue.
Since I'm new to most of this Polymer, npm, bower etc stuff, this is what I did:
mkdir todo
cd todo
yo polymer && gulp serve
git clone https://github.com/PolymerLabs/todo-list.git
cp -R todo-list/* .
bower install
gulp serve
The only thing I changed in the code was the reference to my own firebase db.
@pekelund I did clone the repo, did npm install && bower install then I changed the reference to my own firebase instance. Everything works, from app to firebase and vice-versa.
The error I recieved: Received firebase-child-removed event for unknown child "-K-N1yz28CTfACATYlNW"'
I connected two devices to a depolyed(to firebase) version of your repo, using the same google account on each device. When one deleted an item the other device threw the error above.
I cloned your repo, bower update, changed the firebase element from your firebase to mine, ran gulp and then firebase deployed it to my firebase after editing firebase.json. Those are the only changes I made.
Also shows up for editing: Received firebase-child-changed event for unknown child "-K-N56Pd9ebRqLPGBsHo"
I assume it wasn't meant to be used this way since probably each account should only be active on one device but if you have a simple fix it would be a nice feature to have. I believe it may be the firebase object id changes.
It seems as if it doesnt show up all the time either. Might be a race condition.
This is another explanation of what I think @pekelund meant.
Yeah it may be something off with the firebase-collection element. @cdata in case he's seen this before
Hi Guys, I stumbled upon this issue few days ago. I couldn't solve it but I may have found some sort of pattern.
In my case when I create a new element and then I try to delete this right after, it gets removed from the array but the database doesn't get updated. Therefore when I then refresh the page I can still see the element in the list, but after the page refresh if I remove the element again (or any other element created before the refresh), everything will work as it should.
I had a look at firebase-collection.html, and I noticed that when I try to remove the element right after I added it, the code acts like "data" or "data.firebaseKey" are null. Here's is the link to my test app https://luminous-fire-2392.firebaseapp.com/ . To riproduce the error you can go to the "comment" section and update the comments in the way I described above. You can also check the behaviour from the console since I left a couple of comments in the "remove" function inside firebase-collection.html. Hope this can help.
@pekelund just noticed you ran yo polymer. You shouldn't need to do that. In fact I would discourage it in this case. You're basically scaffolding out the project, then cloning another version on top of it when you do that. Except they're going to be running slightly different versions of Polymer Starter Kit so their package.json files may have diverged.
ok I created a brand new project and was able to reproduce @pekelund's original issue. Modifying a child in the firebase db throws this error in the app Received firebase-child-changed event for unknown child "-K-dKvc77QU13vRZjLbt" and the child in the app does not update. The version I've got running in my dev directory doesn't suffer from this same problem so I'm wondering if it's possibly a Polymer issue (since I set the dependency on master). Either way I'll see if I can work with @cdata to get it resolved.
I'm seeing the same problem in an app derived from this repo (even after running bower update).
In this case, I add an item to a collection in one pane (using firebase-collection), then edit it in another pane (using firebase-document). When the change propogates back out to the collection, it gives the Received firebase-child-changed event for unknown child … error.
There is an item in the collection with the correct key, but for some reason the firebase-collection doesn't know it's there to apply the changes to it.
After reloading the page, changes propagate out to the collection as expected.
I think it might be something to do with the 61-kschaaf-local-key branch of firebase-element. Of course, none of this works with firebase-element#master, as the newly created item doesn't even have a key…
I have a new branch of firebase-collection to try out today. We'll see if that fixes the issue :)
On Mon, Oct 5, 2015 at 7:35 AM, Alf Eaton [email protected] wrote:
I'm seeing the same problem in an app derived from this repo (even after running bower update).
In this case, I add an item to a collection in one pane (using firebase-collection), then edit it in another pane (using firebase-document). When the change propogates back out to the collection, it gives the Received firebase-child-changed event for unknown child … error.
There is an item in the collection with the correct key, but for some reason the firebase-collection doesn't know it's there to apply the changes to it.
After reloading the page, changes propagate out to the collection as expected.
I think it might be something to do with the 61-kschaaf-local-key branch of firebase-element. Of course, none of this works with firebase-element#master, as the newly created item doesn't even have a key…
— Reply to this email directly or view it on GitHub https://github.com/PolymerLabs/todo-list/issues/3#issuecomment-145548370 .
New branch didn't work out :| But, I think we've narrowed the test case down a bit. If you start the app with todos that are already in firebase then you can modify them just fine. If, however, you add a new todo and immediately start editing it in Firebase then it'll throw the error. We'll keep working on it...
Thanks Rob. I appreciate your work on this, as well as your team.
I just pushed an update to the master branch. Would you all mind testing your apps against the latest commit on master? You'll need to reinstall your bower components
That's fixed it for me - thanks @robdodson!
Yes that fixed it. I believe you may have left some error checking console logs in fire-base query behavior script.
Thanks again.
On Tue, Oct 13, 2015 at 12:33 PM, Alf Eaton [email protected] wrote:
That's fixed it for me - thanks @robdodson https://github.com/robdodson!
— Reply to this email directly or view it on GitHub https://github.com/PolymerLabs/todo-list/issues/3#issuecomment-147825164 .
Yeah. If fixed it for me as well. But somehow now I'm experiencing Issue #9
If you read the documentation in firebase database carefully, there is this child_changed event. If you modified the value at the same time the child_changed event triggers and it listen to what happen to the child. It works fine to me.