-
-
Notifications
You must be signed in to change notification settings - Fork 28.6k
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
Add sensors for Unifi latency #116737
base: dev
Are you sure you want to change the base?
Add sensors for Unifi latency #116737
Conversation
Hey there @Kane610, mind taking a look at this pull request as it has been labeled with an integration ( Code owner commandsCode owners of
|
If this accepted and almost done I will add documentation. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice addition, some small changes needed based on mypy
Please take a look at the requested changes, and use the Ready for review button when you are done, thanks 👍 |
1539df4
to
0963377
Compare
I've published aiounifi v78 Kane610/aiounifi@v77...v78 |
Should I update the dependency in this PR or does it need to be. Sperrte PR? |
You can do it in this one |
0963377
to
f1dbcb2
Compare
f1dbcb2
to
4448e15
Compare
4448e15
to
8264e58
Compare
fb9b5a7
to
311ce78
Compare
311ce78
to
ec79efa
Compare
It's way too much duplication here so need to figure out how it can be boiled down to one instance |
Any suggestions ? Tried to look at bit into it. |
You can deduplicate all instances of wan/wan2 with partial |
We could simplify the PR initially and only take one value from Wan as a start anf then look at improving it. |
Maybe some extra thing can be added to be the entity description that can be used to deduce that each entity is based on more data |
Will start with WAN.
Yes we have the same "problem" with storage. |
If you can guide me a bit, I'm willing to try to implement this |
So if you start with WAN and decide on just one latency source you can hard code it all. So I have a few alternate paths forward, they are not concrete but only notions yet. 1 Change a bit more how its exposed in the library, not sure how I think both 2 and 3 would benefit other sensors like TX/RX sensors as well |
Thinking more about it maybe 3 is the way to go for now |
@Kane610 I just did a rebase. I was more than 400 commits behind. I use a Mac with VSCode and dev containers.
|
Try starting with a./script/setup |
Breaking change
Proposed change
This PR aims to add Unifi latency to HA.
By adding this we have the ability to automate if it increase etc or other trigger what people can think of.
Type of change
Additional information
Checklist
ruff format homeassistant tests
)If user exposed functionality or configuration variables are added/changed:
If the code communicates with devices, web services, or third-party tools:
Updated and included derived files by running:
python3 -m script.hassfest
.requirements_all.txt
.Updated by running
python3 -m script.gen_requirements_all
..coveragerc
.To help with the load of incoming pull requests: