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

Syncing across multiple devices (causes NaN errors) #126

Closed
iteles opened this issue Apr 13, 2015 · 7 comments
Closed

Syncing across multiple devices (causes NaN errors) #126

iteles opened this issue Apr 13, 2015 · 7 comments
Assignees
Labels
bug Suspected or confirmed bug (defect) in the code MVP

Comments

@iteles
Copy link
Member

iteles commented Apr 13, 2015

[By the end of writing this issue it appears that the real issue is that timers need to be synced across devices - is this an alpha issue?]

Original title of this issue: If I log in from a different browser/device, causes NaN on any already running timers
I started a timer in my browser for styling the logout button:
dwyl-alpha -running-timer

I then decided to log into my account on my phone. As the timer starts automatically when I open the app on my phone, I had a second running timer when I logged in (one I didn't care about and would have deleted). This caused the logout button timer I had started in my browser to **render as a NaN on the phone whilst it was still running in the browser):
[dwyl-alpha]-timer-renders-as-NaN-if-already-running-in-another-browser

Once the timer in the browser was stopped, this:
a) rendered correctly in the browser straight away, but on refresh, a blank NaN timer appeared (looks like this might be because the timer on the phone was still running):
dwyl-alpha -blank-nan-appears-on-refresh

b) rendered correctly on the phone after a manual refresh, replacing the NaN timer BUT after a few minutes, the same blank NaN timer which appears in the browser above appears on the phone as well
[dwyl-alpha]-timer-rerenders-correctly-replacing-NaN

@iteles iteles added bug Suspected or confirmed bug (defect) in the code FrontEnd labels Apr 13, 2015
@nelsonic
Copy link
Member

Spotted this too. But... have a related question:

What happens if there is more than one active timer?
i.e. you have one running on your phone and another on your desktop (anonymously) and then you login, should both timers continue running on the different devices?
(@iteles this is the interesting/hard part...)

@nelsonic nelsonic assigned iteles and unassigned nelsonic Apr 13, 2015
@nelsonic
Copy link
Member

Relates to: #128 (Multiple Concurrent Timers)

@iteles
Copy link
Member Author

iteles commented Apr 13, 2015

If there's more than one active timer, then I feel like the most obvious thing to happen is that they're synced across your devices as soon as you log in - so rather than displaying one active timer, you display two.

This will have UI implications as well, but is not an [alpha] feature. For the next 24 hours we only worry about [alpha] bugs as this will most likely all change as soon as alpha is out the door!

@nelsonic
Copy link
Member

So, is _this_ an alpha bug then...?
How many people are going to be using this on two devices from tomorrow?

@iteles
Copy link
Member Author

iteles commented Apr 13, 2015

This was exactly the question I posed at the very top of the issue. I think for alpha we can tell people that they're limited to one device.
Agreed @nelsonic ?

@nelsonic
Copy link
Member

Agreed. The plan is to add Socket.IO V. Soon so devices are sync-ed.
for now pick your browser. one timer (at a time ... no multi-tasking)

@iteles iteles added MVP and removed [alpha] labels Apr 13, 2015
@iteles iteles added this to the MVP milestone Apr 13, 2015
@iteles iteles assigned nelsonic and unassigned iteles Apr 15, 2015
@iteles iteles changed the title If I log in from a different browser/device, causes NaN on any already running timers Syncing across multiple devices (causes NaN errors) Apr 20, 2015
@nelsonic nelsonic removed this from the MVP milestone Nov 11, 2019
@nelsonic
Copy link
Member

This should not be an issue with Phoenix Channels 👍
See: https://github.com/dwyl/technology-stack#the-pete-stack

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Suspected or confirmed bug (defect) in the code MVP
Projects
None yet
Development

No branches or pull requests

2 participants