Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Version details #1

Open
richsilv opened this issue Oct 23, 2014 · 3 comments
Open

Version details #1

richsilv opened this issue Oct 23, 2014 · 3 comments

Comments

@richsilv
Copy link

Interestingly, this works fine for me when I clone the repo. I'm running Ubuntu 14.04, and it works perfectly in both Chrome and FF. What spec are you running?

Also, can you do ampify.store('dumbCollection_dumber') in the console, and have a look at the results? If there are three similar objects, can you open one up and paste it in here? If there are more (or less) than three then that's more interesting.

Thanks

@shilman80
Copy link
Collaborator

Ah, I'd assumed it would fail on your machine so I didn't provide as much detail as I should have. My specs:

  • OS X Yosemite
  • Original failure in Chrome; verified failed in Firefox / Safari

Here are the contents of localStorage. Only three items:

__amplify__dumbCollection_dumber: "{"data":[{"name":"foo","_id":{"_str":"544939d0f1f4e10000e55db6"}},{"name":"bar","_id":{"_str":"544939d0f1f4e10000e55db7"}},{"name":"baz","_id":{"_str":"544939d0f1f4e10000e55db8"}}],"expires":null}"

Let me know what you think, or if you need more info.

@shilman80
Copy link
Collaborator

Suddenly it is working on my machine. It was consistently failing across multiple DBs and multiple browsers and I haven't changed anything per se.

I will investigate in more detail tonight, but please don't waste any more time until I can reliably reproduce the problem again.

@richsilv
Copy link
Author

Interesting. It looks like the _id was being stored as an _str in localStorage rather than a string primitive, which I'm sure is why the error was being thrown. However, I don't know if this is an OSX thing or more general, so I'll have to do a bit more research. I also have no idea why it suddenly works!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants