mirror of
https://github.com/home-assistant/core.git
synced 2025-07-23 21:27:38 +00:00
Update pwaqi to 3.0 to use public API (#6376)
The underlying PWAQI library version 3.0 is now using public API to access AQICN data.
This commit is contained in:
parent
edf130b341
commit
568c549353
@ -16,7 +16,7 @@ from homeassistant.helpers.config_validation import PLATFORM_SCHEMA
|
||||
from homeassistant.helpers.entity import Entity
|
||||
from homeassistant.util import Throttle
|
||||
|
||||
REQUIREMENTS = ['pwaqi==2.0']
|
||||
REQUIREMENTS = ['pwaqi==3.0']
|
||||
|
||||
_LOGGER = logging.getLogger(__name__)
|
||||
|
||||
@ -162,7 +162,7 @@ class WaqiData(object):
|
||||
"""Get the data from World Air Quality Index and updates the states."""
|
||||
import pwaqi
|
||||
try:
|
||||
self.data = pwaqi.getStationObservation(
|
||||
self.data = pwaqi.get_station_observation(
|
||||
self._station_id, self._token)
|
||||
except AttributeError:
|
||||
_LOGGER.exception("Unable to fetch data from WAQI")
|
||||
|
@ -433,7 +433,7 @@ pushbullet.py==0.10.0
|
||||
pushetta==1.0.15
|
||||
|
||||
# homeassistant.components.sensor.waqi
|
||||
pwaqi==2.0
|
||||
pwaqi==3.0
|
||||
|
||||
# homeassistant.components.sensor.cpuspeed
|
||||
py-cpuinfo==0.2.6
|
||||
|
Loading…
x
Reference in New Issue
Block a user