-
Notifications
You must be signed in to change notification settings - Fork 96
LF-4788b Create GET endpoint to fetch individual IP from Ensemble (Frontend) #3825
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
LF-4788b Create GET endpoint to fetch individual IP from Ensemble (Frontend) #3825
Conversation
…-individual-ip-from-ensemble-frontend
This reverts commit 2fe500c. The type-based approach in the units PR is a better solution, and I forgot Ensemble is already returning this property to us as et_rate.
SayakaOno
left a comment
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.
Looks great! Just left one minor comment for potential cleanup.
I noticed there are mocks for the IP API with the comment "LF-4710" (wrong ticket?). Were you aware of it??
|
@SayakaOno thank you, cleaned up! 🙏
Are you referring to the TODOs from this PR comment here? I don't think it's the wrong ticket but I didn't fully follow the relationship myself; did you? |
|
Oh, I completely missed Duncan's comment, thank you for the link! Those TODOs were exactly what I was referring to. And no, I didn’t follow the relationship either. I didn't expect the old sensor implementation to be related to the IP... |
Hmmm, I don't think we have to. There aren't any I guess I see the logic in having that map match the keys in the |
|
Thank you Joyce! |
|
@SayakaOno I pushed the change simultaneous to your comment I think! 😅 |
|
It happened at exactly the same time! 🤣 |
|
@SayakaOno I'm gonna be honest, I don't know why Edit: Hmmm, reading about it, and very interesting. I guess in almost every case for a lookup dict like this we would want to use the |
|
ChatGPT says:
I'm still not sure what the best approach is in this kind of situation though... I still have more to learn! Update: It seems best to remove the explicit type when possible, but that’s not always an option... |
|
Really interesting example, thank you! I don't think I've ever thought about that when reaching for a |
Description
This PR is opened according to the original ticket & Ensemble API endpoint specifications. I have decided to create a separate ticket to incorporate the endpoint adjusts needed for the real incoming data, leaving this PR for the mocking solution as originally intended. Note that means this particular branch cannot be used with
shouldSend = true-- it will error since much of what Ensemble returns is not what we expected.Changes Included in this PR:
Backend:
Frontend:
store/apiJira link: https://lite-farm.atlassian.net/browse/LF-4788
Type of change
How Has This Been Tested?
Checklist:
pnpm i18nto help with this)