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

Replace API.sensors.async_get_nearby_sensor_indices #24

Merged
merged 1 commit into from
Nov 22, 2022
Merged

Conversation

bachya
Copy link
Owner

@bachya bachya commented Nov 22, 2022

Describe what the PR does:

It turns out that API.sensors.async_get_nearby_sensor_indicies isn't quite right – it adds unnecessary complexity to the request model and if the user wants more information on those sensors, they're stuck doing two API calls. This PR replaces API.sensors.async_get_nearby_sensor_indicies with API.sensors.async_get_nearby_sensors: instead of returning a sorted list of sensor indices, we now return a sorted list of SensorModel objects.

Does this fix a specific issue?

N/A

Checklist:

  • Confirm that one or more new tests are written for the new functionality.
  • Run tests and ensure everything passes (with 100% test coverage).
  • Update README.md with any new documentation.
  • Add yourself to AUTHORS.md.

@bachya bachya added the breaking-change A breaking change for existing users label Nov 22, 2022
@bachya bachya self-assigned this Nov 22, 2022
@codeclimate
Copy link

codeclimate bot commented Nov 22, 2022

Code Climate has analyzed commit d55d8c3 and detected 0 issues on this pull request.

View more on Code Climate.

@codecov
Copy link

codecov bot commented Nov 22, 2022

Codecov Report

Merging #24 (d55d8c3) into dev (db6269c) will not change coverage.
The diff coverage is 100.00%.

@@            Coverage Diff            @@
##               dev       #24   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           12        12           
  Lines          481       480    -1     
=========================================
- Hits           481       480    -1     
Impacted Files Coverage Δ
aiopurpleair/api.py 100.00% <100.00%> (ø)
aiopurpleair/endpoints/sensors.py 100.00% <100.00%> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

@bachya bachya merged commit 3de0907 into dev Nov 22, 2022
@bachya bachya deleted the nearby-sensors branch November 22, 2022 17:57
@bachya bachya mentioned this pull request Nov 22, 2022
4 tasks
@github-actions github-actions bot locked and limited conversation to collaborators Nov 24, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
breaking-change A breaking change for existing users
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant