Skip to content

Use logbook livestream when requesting a time window that includes the future#12744

Merged
zsarnett merged 25 commits intohome-assistant:devfrom
bdraco:live_logbook
May 23, 2022
Merged

Use logbook livestream when requesting a time window that includes the future#12744
zsarnett merged 25 commits intohome-assistant:devfrom
bdraco:live_logbook

Conversation

@bdraco
Copy link
Copy Markdown
Member

@bdraco bdraco commented May 21, 2022

Requires home-assistant/core#72258

Proposed change

Use logbook livestream when requesting a time window that includes the future

Mobile

Main panel
May-21-2022 12-05-25
Areas
May-21-2022 12-09-16

More info
May-21-2022 12-07-38

Type of change

  • Dependency upgrade
  • Bugfix (non-breaking change which fixes an issue)
  • New feature (thank you!)
  • Breaking change (fix/feature causing existing functionality to break)
  • Code quality improvements to existing code or addition of tests

Example configuration

Additional information

  • This PR fixes or closes issue: fixes #
  • This PR is related to issue or discussion:
  • Link to documentation pull request:

Checklist

  • The code change is tested and works locally.
  • There is no commented out code in this PR.
  • Tests have been added to verify that the new code works.

If user exposed functionality or configuration variables are added/changed:

@bdraco
Copy link
Copy Markdown
Member Author

bdraco commented May 21, 2022

I wish I could figure out how to make the new rows fade in

@bdraco
Copy link
Copy Markdown
Member Author

bdraco commented May 21, 2022

Did some testing to make sure closing windows removes the subscriptions /developer-tools/event

@bdraco bdraco marked this pull request as ready for review May 21, 2022 23:35
balloob
balloob previously approved these changes May 22, 2022
@bdraco bdraco marked this pull request as draft May 22, 2022 20:40
@bdraco bdraco marked this pull request as ready for review May 22, 2022 20:40
@bdraco
Copy link
Copy Markdown
Member Author

bdraco commented May 22, 2022

I pulled the power on the access point my phone was connected to, watched it switch to 5g, continue to stream, and waited for the AP to power back up. It successfully recovered streaming events during the switch over and switch back

@bdraco
Copy link
Copy Markdown
Member Author

bdraco commented May 23, 2022

I think there is a bug here where its subscribing, unsubscribe, then subscribing when the logbook page loads

@bdraco
Copy link
Copy Markdown
Member Author

bdraco commented May 23, 2022

Still have one issue. It spins if you reload the page and the live stream is running.

@bdraco bdraco marked this pull request as draft May 23, 2022 16:24
@bdraco
Copy link
Copy Markdown
Member Author

bdraco commented May 23, 2022

So a hard refresh let changed = changedProps.get("time"); will always be true twice

  1. undefined
  2. the time

@balloob
Copy link
Copy Markdown
Member

balloob commented May 23, 2022

that's weird it would be set to undefined. That is a bug.

@bdraco bdraco marked this pull request as ready for review May 23, 2022 16:56
@zsarnett zsarnett merged commit da106d2 into home-assistant:dev May 23, 2022
@github-actions github-actions bot locked and limited conversation to collaborators May 24, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants