GithubHelp home page GithubHelp logo

limych / ha-gismeteo Goto Github PK

View Code? Open in Web Editor NEW
118.0 5.0 21.0 1.42 MB

Gismeteo Weather Provider for Home Assistant

License: Other

Python 87.12% Shell 11.87% Dockerfile 0.15% Makefile 0.85%
home-assistant gismeteo gismeteo-weather weather-provider sensor forecast hacs sensors

ha-gismeteo's Introduction

Please ⭐ this repo if you find it useful

Gismeteo Weather Provider for Home Assistant

GitHub Release GitHub Activity License

hacs Project Maintenance Support me on Patreon

Community Forum

Component to integrate with Gismeteo weather provider.

This component can be used in two different ways: as a weather provider and as a set of sensors.

Gismeteo Logo

NB. You can find a real example of using this component in my Home Assistant configuration.

I also suggest you visit the support topic on the community forum.

Installation

Install from HACS (recommended)

  1. Have HACS installed, this will allow you to easily manage and track updates.
  2. Search for "Gismeteo Weather Provider".
  3. Click Install below the found integration.
  4. If you want to configure component via Home Assistant UI...
    in the HA UI go to "Configuration" -> "Integrations" click "+" and search for "Gismeteo".
  5. If you want to configure component via configuration.yaml...
    follow instructions below, then restart Home Assistant.

Manual installation

  1. Using the tool of choice open the directory (folder) for your HA configuration (where you find configuration.yaml).
  2. If you do not have a custom_components directory (folder) there, you need to create it.
  3. In the custom_components directory (folder) create a new folder called gismeteo.
  4. Download file gismeteo.zip from the [latest release section][latest-release] in this repository.
  5. Extract all files from this archive you downloaded in the directory (folder) gismeteo you created.
  6. Restart Home Assistant
  7. If you want to configure component via Home Assistant UI...
    in the HA UI go to "Configuration" -> "Integrations" click "+" and search for "Gismeteo".
  8. If you want to configure component via configuration.yaml...
    follow instructions below, then restart Home Assistant.

Breaking Changes

  • Since version 3.0.0...
    • the format of the component settings in file configuration.yaml has been changed. Now all the component settings are collected in a single block gismeteo.
    • forecast sensor is removed from component. Use forecast_days option instead.
  • Since version 2.2.0 forecast sensor has the name ... 3h Forecast instead of ... Forecast.

Configuration Examples

Adding the following to your configuration.yaml file will create two weather locations, one for the home coordinates and one for the remote location.

The first location will create one entity: just weather provider. The second location will create 21 sensors: four groups of sensors for current weather and forecasts for today and 2 days forward. Another 78 sensors will be created but disabled. You can enable that sensors through device settings.

# Example configuration.yaml entry
gismeteo:
  sweet_home:

  dacha:
    name: Our Country House
    latitude: ...
    longitude: ...
    add_sensors: yes
    forecast_days: 2

See below detailed descriptions to configure component.

* * *

I put a lot of work into making this repo and component available and updated to inspire and help others! I will be glad to receive thanks from you — it will give me new strength and add enthusiasm:


Patreon
or support via Bitcoin or Etherium:
Bitcoin
16yfCfz9dZ8y8yuSwBFVfiAa3CNYdMh7Ts

Configuration variables

gismeteo:
(map) (Required)
Map of your weather locations.

name:
(string) (Optional)
Name to use in the frontend.

latitude:
(float) (Optional) (Default: coordinates from the Home Assistant configuration)
Latitude coordinate to monitor weather of (required if longitude is specified).

longitude:
(float) (Optional) (Default: coordinates from the Home Assistant configuration)
Longitude coordinate to monitor weather of (required if latitude is specified).

add_sensors:
(boolean) (Optional) (Default: false)
Enable this option to add current weather and forecast sensors to the frontend.

forecast_days:
(positive int; 0–6) (Optional) (Default: do not create any sensors)
How many days ahead to make forecast sensors.
Note: Forecast sensors will be created only if add_sensors option is enabled.
Note: If you only need a forecast sensors for today, specify 0.

When sensors option are enabled, it creates 20 sensors. Each shows one aspect of current weather. Only few basic sensors are enabled by default. But you can enable any sensor through device settings.

When you add forecast_days option, integration creates additional 21 sensors for each day. Each shows one aspect of forecast weather for that day. As usual, only few basic sensors are enabled by default.

List of sensors that will be created:

condition
A human-readable text summary.

temperature
The air temperature.

apparent_temperature
The apparent air temperature.

low_temperature
The lowest air temperature per day.

humidity
The relative humidity of air.

pressure
The sea-level air pressure.

wind_speed
The wind speed.

wind_gusts_speed
The wind gusts speed.

wind_bearing
The wind bearing as an angle.

wind_bearing_2
The wind bearing as human-readable text.

cloud_coverage
Cloud coverage as a percentage.

precipitation
The precipitation amount volume.

rain_amount
The rain amount volume.

snow_amount
The snow amount volume.

storm
The storm prediction.

geomagnetic_field
The geomagnetic field value:
1 = No noticeable geomagnetic disturbance
2 = Small geomagnetic disturbances
3 = Weak geomagnetic storm
4 = Small geomagnetic storm
5 = Moderate geomagnetic storm
6 = Severe geomagnetic storm
7 = Hard geomagnetic storm
8 = Extreme geomagnetic storm

water_temperature
The temperature of water.

uv_index
The ultraviolet index:
0–2 = Low
3–5 = Moderate
6–7 = High
8–10 = Very high
11+ = Extreme

birch_pollen
Birch pollen concentration index:
1–10 = Low
11–50 = Moderate
51–500 = High
501+ = Very high

grass_pollen
Cereal grasses pollen concentration index:
1–10 = Low
11–50 = Moderate
51–500 = High
501+ = Very high

ragweed_pollen
Ragweed pollen concentration index:
1–10 = Low
11–50 = Moderate
51–500 = High
501+ = Very high

road_condition
Road surface condition as a human-readable text.

Track updates

You can automatically track new versions of this component and update it by HACS.

Troubleshooting

To enable debug logs use this configuration:

# Example configuration.yaml entry
logger:
  default: info
  logs:
    custom_components.gismeteo: debug

... then restart HA.

Contributions are welcome!

This is an active open-source project. We are always open to people who want to use the code or contribute to it.

We have set up a separate document containing our contribution guidelines.

Thank you for being involved! 😍

Authors & contributors

The original setup of this component is by Andrey "Limych" Khrolenok.

For a full list of all authors and contributors, check the contributor's page.

License

creative commons Attribution-NonCommercial-ShareAlike 4.0 International License

See separate license file for full text.


ha-gismeteo's People

Contributors

alex107ivanov avatar antonverburg avatar ctso avatar cvc90 avatar dependabot[bot] avatar eifinger avatar eseglem avatar github-actions[bot] avatar hudsonbrendon avatar iantrich avatar jcgoette avatar limych avatar linushoppe avatar ludeeus avatar matthewflamm avatar mattrayner avatar misa1515 avatar mjmeli avatar myztillx avatar nepozs avatar oncleben31 avatar raman325 avatar rianoc avatar rodpayne avatar rroller avatar salem84 avatar scottg489 avatar swartjean avatar tefinger avatar tetienne avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

ha-gismeteo's Issues

WARNING: Deprecated condition "weather". Please replace it to "condition"

Environment

  • Home Assistant Core release with the issue: 2021.3.4
  • This custom component release with the issue: 2.2.0
  • Last working this custom component release (if known):
  • Operating environment (Home Assistant/Supervisor/Docker/venv): 2021.3.4/supervisor-2021.03.9/Debian

Describe the bug

Get a warning message in log:

Logger: custom_components.gismeteo.sensor
Source: custom_components/gismeteo/sensor.py:98
Integration: Gismeteo (documentation, issues)
First occurred: 7 апреля 2021 г., 1:13:01 (1 occurrences)
Last logged: 7 апреля 2021 г., 1:13:01

Deprecated condition "weather". Please replace it to "condition"

Road weather support

Hello. Thanks for awesome project!

Is it possible to add road weather support?

Снимок экрана 2021-01-03 в 16 30 04

Интеграция gismeteo использует устаревший прогноз

Environment

  • Home Assistant Core release with the issue:
  • This custom component release with the issue:
  • Last working this custom component release (if known):
  • Operating environment (Home Assistant/Supervisor/Docker/venv):

Describe the bug

Configuration.yaml

Add your configs here if any.

Steps to Reproduce

Expected behavior

Debug log


Add your logs here.

Additional context

не показывает погоду

  • Version of the Home Assistant: 0.117.5
  • Version of the custom component: 2.0.22

Configuration

homeassistant:
  name: Home Assistant
  latitude: 55.949571
  longitude: 37.924716
  elevation: 0
  unit_system: metric
  time_zone: Europe/Moscow

default_config:

tts:
  - platform: google_translate

group: !include groups.yaml
automation: !include automations.yaml
script: !include scripts.yaml
scene: !include scenes.yaml

weather:
  - platform: gismeteo

Describe the bug
Я установил пакет hass.io с центра пакетов Synology.
Потом в /hass.io/homeassistant/custom_components/gismeteo скопировал все файлы из \ha-gismeteo-master\custom_components\gismeteo

Но в списке интеграций gismeteo не появилась и добавить панель погоды не могу.
ha

Debug log
в разделе /config/logs я вижу такие ошибки

Logger: custom_components.gismeteo
Source: custom_components/gismeteo/__init__.py:165
Integration: Gismeteo (documentation)
First occurred: 20:59:05 (1 occurrences)
Last logged: 20:59:05
Can't detect nearest city! 


Logger: homeassistant.loader
Source: loader.py:463
First occurred: 20:59:00 (1 occurrences)
Last logged: 20:59:00
You are using a custom integration for gismeteo which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant. 

Gismeteo Map Icons 360 degrees out of position.

Environment

  • Home Assistant Core release with the issue: 2022.6.6
  • This custom component release with the issue: 2.3.4
  • Last working this custom component release (if known):
  • Operating environment (Home Assistant/Supervisor/Docker/venv): Home Assistant OS 8.2

Describe the bug

The Icons placed on the map by Gismeteo are in the right place bug wrapped around the globe from everything else, so the map as to be shown twice. Had to explain, see screen shot in additional info.

Configuration.yaml

Add your configs here if any.

Steps to Reproduce

Expected behavior
Icons from Gismeteo and other map locations in the same area.

Debug log

2022-06-21 22:25:56 INFO (MainThread) [homeassistant.bootstrap] Setting up stage 2: {'counter', 'ezviz', 'automation', 'system_health', 'zone', 'trace', 'input_datetime', 'logbook', 'timer', 'flux_led', 'my', 'default_config', 'google', 'media_source', 'history', 'weather', 'map', 'mobile_app', 'persistent_notification', 'lutron_caseta', 'plex', 'sensor', 'energy', 'scene', 'application_credentials', 'input_text', 'nws', 'input_boolean', 'cast', 'input_select', 'tag', 'input_number', 'samsungtv', 'sun', 'alexa_media', 'input_button', 'notify', 'tts', 'ffmpeg', 'hacs', 'unifi', 'blueprint', 'hubitat', 'script', 'group', 'gismeteo'}
2022-06-21 22:25:56 INFO (MainThread) [homeassistant.setup] Setting up gismeteo
2022-06-21 22:25:56 INFO (MainThread) [custom_components.gismeteo] 
-------------------------------------------------------------------
Gismeteo
Version: 2.3.4
This is a custom integration!
If you have ANY issues with this you need to open an issue here:
https://github.com/Limych/ha-gismeteo/issues
-------------------------------------------------------------------

2022-06-21 22:25:56 INFO (MainThread) [homeassistant.setup] Setup of domain gismeteo took 0.0 seconds
2022-06-21 22:25:56 DEBUG (MainThread) [custom_components.gismeteo.api] Place coordinates: 47.87151190828796, -86.25637524127962
2022-06-21 22:25:56 DEBUG (MainThread) [custom_components.gismeteo.api] Forecast mode: hourly
2022-06-21 22:25:56 DEBUG (MainThread) [custom_components.gismeteo.cache] Initializing cache
2022-06-21 22:25:56 DEBUG (MainThread) [custom_components.gismeteo.api] Requesting URL https://services.gismeteo.ru/inform-service/inf_chrome/cities/?lat=47.87151190828796&lng=-86.25637524127962&count=1&lang=en
2022-06-21 22:25:58 DEBUG (MainThread) [custom_components.gismeteo.api] Data retrieved from https://services.gismeteo.ru/inform-service/inf_chrome/cities/?lat=47.87151190828796&lng=-86.25637524127962&count=1&lang=en, status: 200
2022-06-21 22:25:58 DEBUG (MainThread) [custom_components.gismeteo.cache] Store cache file /config/.storage/location_47.87151190828796_-86.25637524127962.xml
2022-06-21 22:25:58 DEBUG (MainThread) [custom_components.gismeteo.api] Requesting URL https://services.gismeteo.ru/inform-service/inf_chrome/forecast/?city=8444&lang=en
2022-06-21 22:25:58 DEBUG (MainThread) [custom_components.gismeteo.api] Cached response used
2022-06-21 22:25:58 DEBUG (MainThread) [custom_components.gismeteo.cache] Read cache file /config/.storage/forecast_8444.xml
2022-06-21 22:25:58 DEBUG (MainThread) [custom_components.gismeteo] Finished fetching gismeteo data in 0.001 seconds (success: True)
2022-06-21 22:25:58 INFO (MainThread) [homeassistant.components.sensor] Setting up sensor.gismeteo
2022-06-21 22:25:58 INFO (MainThread) [homeassistant.components.weather] Setting up weather.gismeteo
2022-06-21 22:25:58 WARNING (MainThread) [homeassistant.helpers.entity] Temperature sensor sensor.home_temperature (<class 'custom_components.gismeteo.sensor.GismeteoSensor'>) does not inherit SensorEntity, this will be unsupported in Home Assistant Core 2022.7.Please report it to the custom component author.
2022-06-21 22:25:58 WARNING (MainThread) [homeassistant.helpers.entity] Temperature sensor sensor.home_temperature_feels_like (<class 'custom_components.gismeteo.sensor.GismeteoSensor'>) does not inherit SensorEntity, this will be unsupported in Home Assistant Core 2022.7.Please report it to the custom component author.
2022-06-21 22:25:58 WARNING (MainThread) [homeassistant.helpers.entity] Temperature sensor sensor.home_water_temperature (<class 'custom_components.gismeteo.sensor.GismeteoSensor'>) does not inherit SensorEntity, this will be unsupported in Home Assistant Core 2022.7.Please report it to the custom component author.


Add your logs here.

Additional context
image

Bug in changing Forecast Mode.

Environment

Home Assistant OS 5.12 stable
supervisor-2021.04.0
core-2021.4.6

Describe the bug

On change Forecast Mode - second set of entities appears:
image

Configuration.yaml

Add your configs here if any.

Steps to Reproduce

Change Forecast Mode in Integration Options.

Expected behavior

Same entities must be re-used with no doubt.

Debug log


Add your logs here.

Additional context

Cannot register a bug here

Checklist

  • I have filled out the template to the best of my ability.
  • This only contains 1 feature request (if you have multiple feature requests, open one feature request for each feature request).
  • This issue is not a duplicate feature request of previous feature requests.

Is your feature request related to a problem? Please describe.

The "issues" section only contains a "Feature request" button:

image

Describe the solution you'd like

A possibility to register a bug.

Describe alternatives you've considered

none

Additional context

none

The component stopped working

Versions

  • Version of the Home Assistant: 2021.2.3
  • Version of the custom component: 2.0.22

Configuration

- platform: gismeteo
  forecast: true
  monitored_conditions:
    - rain
    - snow
    - storm
    - geomagnetic

Describe the bug

Errors in HA log:

Logger: homeassistant.components.weather
Source: custom_components/gismeteo/__init__.py:336
Integration: Weather (documentation, issues)
First occurred: 15:24:20 (1 occurrences)
Last logged: 15:24:20

gismeteo: Error on device update!
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 358, in _async_add_entity
    await entity.async_device_update(warning=False)
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 466, in async_device_update
    await task
  File "/usr/local/lib/python3.8/concurrent/futures/thread.py", line 57, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/config/custom_components/gismeteo/weather.py", line 85, in update
    self._wd.update()
  File "/usr/src/homeassistant/homeassistant/util/__init__.py", line 285, in wrapper
    result = method(*args, **kwargs)
  File "/config/custom_components/gismeteo/__init__.py", line 336, in update
    xml = etree.fromstring(response)
  File "/usr/local/lib/python3.8/xml/etree/ElementTree.py", line 1320, in XML
    parser.feed(text)
  File "<string>", line None
xml.etree.ElementTree.ParseError: mismatched tag: line 6, column 2

To Reproduce

Restart HA

Expected behavior

Screenshots

image

Setup failed for Gismetio

Environment

  • Home Assistant Core release with the issue:
    core-2021.12.0
    core-2021.12.1
    Доступная версия
    core-2021.12.1
  • This custom component release with the issue:
    release v.2.3.3
  • Last working this custom component release (if known):
  • Operating environment (Home Assistant/Supervisor/Docker/venv):
    Supervisor
    Describe the bug

Configuration.yaml

weather:
  - platform: gismeteo
    mode: daily

Steps to Reproduce

Expected behavior

Debug log

Logger: homeassistant.setup
Source: setup.py:153
First occurred: 07:15:56 (1 occurrences)
Last logged: 07:15:56

Setup failed for gismeteo: Unable to import component: cannot import name 'HTTP_OK' from 'homeassistant.const' (/usr/src/homeassistant/homeassistant/const.py)

Additional context

there was no error before the upgrade to the version
core-2021.12.0

Integration unavailable after a while

Environment

  • Home Assistant Core release with the issue: core-2021.12.9
  • This custom component release with the issue: 2.3.4 (2.3.5-beta affected as well)
  • Last working this custom component release (if known):
  • Operating environment (Home Assistant/Supervisor/Docker/venv): Home Assistant Supervised

Describe the bug

After HA starts, integration works fine.
But became unavailable after a while due to it failed to retrive location data.

Traceback (most recent call last):
  File "/config/custom_components/gismeteo/api.py", line 198, in async_get_location
    xml = etree.fromstring(response)
  File "/usr/local/lib/python3.9/xml/etree/ElementTree.py", line 1347, in XML
    parser.feed(text)
xml.etree.ElementTree.ParseError: mismatched tag: line 6, column 2

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 313, in async_setup
    result = await component.async_setup_entry(hass, self)  # type: ignore
  File "/config/custom_components/gismeteo/__init__.py", line 116, in async_setup_entry
    coordinator = await _async_get_coordinator(hass, config_entry.entry_id, config)
  File "/config/custom_components/gismeteo/__init__.py", line 77, in _async_get_coordinator
    await gismeteo.async_get_location()
  File "/config/custom_components/gismeteo/api.py", line 207, in async_get_location
    raise ApiError(
custom_components.gismeteo.api.ApiError: Can't retrieve location data! Invalid server response.

Configuration.yaml
No manual yaml configuration.
Configured via integrations UI.

Steps to Reproduce

Expected behavior

Do not fail integration in case location is not available for a short period of time.

Debug log


Add your logs here.

Additional context

Прогноз сдвинут по времени

Данные о прогнозе сдвинуты назад по времени.

В home assistant показывает что в 15:00 будет –14
Снимок экрана 2022-12-16 в 16 09 39

А на сайте показано что –14 будет в 18:00
Снимок экрана 2022-12-16 в 16 09 56

GISMETEO in Home Assistant will stop work with version 2024.3.0

Checklist

  • I have filled out the template to the best of my ability.
  • This only contains 1 feature request (if you have multiple feature requests, open one feature request for each feature request).
  • This issue is not a duplicate feature request of previous feature requests.

Is your feature request related to a problem? Please describe.

Gismeteo Integration Uses Deprecated Forecasting This stops working in version 2024.3.0.
Fix the issue before upgrading.
The gismeteo integration uses the deprecated forecast attribute.
Please report it to the custom integration author..

Describe the solution you'd like

update

Describe alternatives you've considered

other integration

Additional context

image

Can not install integration

Version of the Home Assistant:

Home Assistant 2021.2.3

Gismeteo ha-gismeteo 2.1.0

Dont install. Give error:

2021-03-02 14:14:19 ERROR (MainThread) [aiohttp.server] Error handling request
Traceback (most recent call last):
File "/usr/local/lib/python3.8/site-packages/aiohttp/web_protocol.py", line 422, in _handle_request
resp = await self._request_handler(request)
File "/usr/local/lib/python3.8/site-packages/aiohttp/web_app.py", line 499, in _handle
resp = await handler(request)
File "/usr/local/lib/python3.8/site-packages/aiohttp/web_middlewares.py", line 118, in impl
return await handler(request)
File "/usr/src/homeassistant/homeassistant/components/http/security_filter.py", line 56, in security_filter_middleware
return await handler(request)
File "/usr/src/homeassistant/homeassistant/components/http/request_context.py", line 18, in request_context_middleware
return await handler(request)
File "/usr/src/homeassistant/homeassistant/components/http/ban.py", line 72, in ban_middleware
return await handler(request)
File "/usr/src/homeassistant/homeassistant/components/http/auth.py", line 127, in auth_middleware
return await handler(request)
File "/usr/src/homeassistant/homeassistant/components/http/view.py", line 129, in handle
result = await result
File "/usr/src/homeassistant/homeassistant/components/config/config_entries.py", line 136, in post
return await super().post(request)
File "/usr/src/homeassistant/homeassistant/components/http/data_validator.py", line 60, in wrapper
result = await method(view, request, *args, **kwargs)
File "/usr/src/homeassistant/homeassistant/helpers/data_entry_flow.py", line 69, in post
result = await self._flow_mgr.async_init(
File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 130, in async_init
result = await self._async_handle_step(
File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 213, in _async_handle_step
result: Dict = await getattr(flow, method)(user_input)
File "/config/custom_components/gismeteo/config_flow.py", line 95, in async_step_user
default=self.hass.config.get(CONF_FORECAST, False),
AttributeError: 'Config' object has no attribute 'get'

Error while setting up platform gismeteo

2019-09-06 23:20:17 ERROR (MainThread) [homeassistant.components.weather] Error while setting up platform gismeteo
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 150, in _async_setup_platform
    await asyncio.wait_for(asyncio.shield(task), SLOW_SETUP_MAX_WAIT)
  File "/usr/local/lib/python3.7/asyncio/tasks.py", line 442, in wait_for
    return fut.result()
  File "/usr/local/lib/python3.7/concurrent/futures/thread.py", line 57, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/config/custom_components/gismeteo/weather.py", line 57, in setup_platform
    'cache_time': MIN_TIME_BETWEEN_UPDATES.total_seconds(),
  File "/config/custom_components/gismeteo/gismeteo.py", line 132, in __init__
    self._city_id = self._get_city_id(latitude, longitude)
  File "/config/custom_components/gismeteo/gismeteo.py", line 167, in _get_city_id
    response = self._http_request(url, cache_fname)
  File "/config/custom_components/gismeteo/gismeteo.py", line 157, in _http_request
    self._cache.save_cache(cache_fname, response)
  File "/config/custom_components/gismeteo/gismeteo.py", line 108, in save_cache
    os.makedirs(self._cache_dir)
  File "/usr/local/lib/python3.7/os.py", line 221, in makedirs
    mkdir(name, mode)
FileExistsError: [Errno 17] File exists: '/tmp/gismeteo'

Support RU-ru language

Добрый день.

Gismeteo умеет отдавать прогноз на русском и других языках через параметр lang=ru в запросе.
Есть ли возможность добавить поодержку языков, ну хотя бы русского? :)
Спасибо.

Погода работает через раз, в логе сплошные ошибки

Home Assistant 2021.2.3
Компонент последней версии

2021-02-15 11:39:32 ERROR (MainThread) [homeassistant.helpers.entity] Update for weather.gismeteo fails
Traceback (most recent call last):
File "/opt/homeassistant/lib/python3.9/site-packages/homeassistant/helpers/entity.py", line 278, in async_update_ha_state
await self.async_device_update()
File "/opt/homeassistant/lib/python3.9/site-packages/homeassistant/helpers/entity.py", line 474, in async_device_update
raise exc
File "/usr/local/lib/python3.9/concurrent/futures/thread.py", line 52, in run
result = self.fn(*self.args, **self.kwargs)
File "/opt/homeassistant/config/custom_components/gismeteo/weather.py", line 85, in update
self._wd.update()
File "/opt/homeassistant/lib/python3.9/site-packages/homeassistant/util/init.py", line 285, in wrapper
result = method(*args, **kwargs)
File "/opt/homeassistant/config/custom_components/gismeteo/init.py", line 336, in update
xml = etree.fromstring(response)
File "/usr/local/lib/python3.9/xml/etree/ElementTree.py", line 1347, in XML
parser.feed(text)
File "", line None

Cannot setup on 2021.12 ( Unable to import component: cannot import name 'HTTP_OK' ...)

Environment

  • Home Assistant Core release with the issue: 2021.12.0
  • This custom component release with the issue: 2.3.3
  • Last working this custom component release (if known): 2.3.3
  • Operating environment (Home Assistant/Supervisor/Docker/venv): HA in Docker

Describe the bug

The integration cannot setup on HA startup.
There is an error in the log:

Setup failed for gismeteo: Unable to import component: cannot import name 'HTTP_OK' from 'homeassistant.const' (/usr/src/homeassistant/homeassistant/const.py)

Configuration.yaml
The integration is setup via UI.

Steps to Reproduce

Upgrade HA to 2021.12

Expected behavior

The integration is loaded on HA startup.

Debug log


Add your logs here.

Additional context

Error doing job

Checklist

  • I have filled out the template to the best of my ability.
  • This only contains 1 feature request (if you have multiple feature requests, open one feature request for each feature request).
  • This issue is not a duplicate feature request of previous feature requests.

Is your feature request related to a problem? Please describe.

1

Describe the solution you'd like

Регистратор: homeassistant
Источник: components/sensor/init.py:670
Первое сообщение: 09:25:27 (4 сообщений)
Последнее сообщение: 09:40:33

Error doing job: Task exception was never retrieved
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/sensor/init.py", line 663, in state
numerical_value = int(value)
^^^^^^^^^^
ValueError: invalid literal for int() with base 10: 'unknown'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/sensor/init.py", line 666, in state
numerical_value = float(value)
^^^^^^^^^^^^
ValueError: could not convert string to float: 'unknown'

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 261, in _handle_refresh_interval
await self._async_refresh(log_failures=True, scheduled=True)
File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 417, in _async_refresh
self.async_update_listeners()
File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 183, in async_update_listeners
update_callback()
File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 497, in _handle_coordinator_update
self.async_write_ha_state()
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 992, in async_write_ha_state
self._async_write_ha_state()
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1113, in _async_write_ha_state
state, attr, capabilities, shadowed_attr = self.__async_calculate_state()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1050, in __async_calculate_state
state = self._stringify_state(available)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 998, in _stringify_state
if (state := self.state) is None:
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/sensor/init.py", line 670, in state
raise ValueError(
ValueError: Sensor sensor.gismeteo_wind_bearing has device class 'None', state class 'None' unit '°' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-numeric value: 'unknown' (<class 'str'>)

Describe alternatives you've considered

1

Additional context

1

3h forecast looks useless

Environment

  • Home Assistant Core release with the issue: 2022.8.6
  • This custom component release with the issue: 2.5.0
  • Last working this custom component release (if known): n/a
  • Operating environment (Home Assistant/Supervisor/Docker/venv): HAOS

Describe the bug

At 09:47 : 3h forecast is for 12:47 if I understood correctly.
How forecast for 12:47 can be clear-night ???
Ans sunny for 03:00...

image

Configuration.yaml

n/a

UI configured:
image

Steps to Reproduce

Expected behavior

Debug log


Add your logs here.

Additional context

Good day. I really wanted to see the temperature of water in this integration

Is your feature request related to a problem? Please describe.

A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]

Describe the solution you'd like

A clear and concise description of what you want to happen.

Describe alternatives you've considered

A clear and concise description of any alternative solutions or features you've considered.

Additional context

Add any other context or screenshots about the feature request here.

The method for providing platform translations has changed in Home Assistant Core

Checklist

  • I have filled out the template to the best of my ability.
  • This only contains 1 feature request (if you have multiple feature requests, open one feature request for each feature request).
  • This issue is not a duplicate feature request of previous feature requests.

Is your feature request related to a problem? Please describe.

The method for providing platform translations has changed in Home Assistant Core, and this integration needs to be updated.

Describe the solution you'd like

Implement the new method

Describe alternatives you've considered

Drop translations

Additional context

Details can be found in https://developers.home-assistant.io/blog/2024/03/05/platform_entity_translations_deprecation

2024.1 warnings in Log (deprecated constants)

Checklist

  • I have filled out the template to the best of my ability.
  • This only contains 1 feature request (if you have multiple feature requests, open one feature request for each feature request).
  • This issue is not a duplicate feature request of previous feature requests.

Is your feature request related to a problem? Please describe.

Cannot register a bug.
Since reporting about the issue here as a "Feature request".

2024.1. log contains these warnings:

2024-01-04 02:04:23.266 WARNING (MainThread) [homeassistant.const] DEVICE_CLASS_HUMIDITY was used from gismeteo, this is a deprecated constant which will be removed in HA Core 2025.1. Use SensorDeviceClass.HUMIDITY instead, please create a bug report at https://github.com/Limych/ha-gismeteo/issues
2024-01-04 02:04:23.269 WARNING (MainThread) [homeassistant.const] DEVICE_CLASS_PRESSURE was used from gismeteo, this is a deprecated constant which will be removed in HA Core 2025.1. Use SensorDeviceClass.PRESSURE instead, please create a bug report at https://github.com/Limych/ha-gismeteo/issues
2024-01-04 02:04:23.273 WARNING (MainThread) [homeassistant.const] DEVICE_CLASS_TEMPERATURE was used from gismeteo, this is a deprecated constant which will be removed in HA Core 2025.1. Use SensorDeviceClass.TEMPERATURE instead, please create a bug report at https://github.com/Limych/ha-gismeteo/issues
2024-01-04 02:04:23.278 WARNING (MainThread) [homeassistant.const] LENGTH_MILLIMETERS was used from gismeteo, this is a deprecated constant which will be removed in HA Core 2025.1. Use UnitOfLength.MILLIMETERS instead, please create a bug report at https://github.com/Limych/ha-gismeteo/issues
2024-01-04 02:04:23.281 WARNING (MainThread) [homeassistant.const] PRESSURE_HPA was used from gismeteo, this is a deprecated constant which will be removed in HA Core 2025.1. Use UnitOfPressure.HPA instead, please create a bug report at https://github.com/Limych/ha-gismeteo/issues
2024-01-04 02:04:23.286 WARNING (MainThread) [homeassistant.const] SPEED_METERS_PER_SECOND was used from gismeteo, this is a deprecated constant which will be removed in HA Core 2025.1. Use UnitOfSpeed.METERS_PER_SECOND instead, please create a bug report at https://github.com/Limych/ha-gismeteo/issues
2024-01-04 02:04:23.289 WARNING (MainThread) [homeassistant.const] TEMP_CELSIUS was used from gismeteo, this is a deprecated constant which will be removed in HA Core 2025.1. Use UnitOfTemperature.CELSIUS instead, please create a bug report at https://github.com/Limych/ha-gismeteo/issues
2024-01-04 02:04:23.920 WARNING (MainThread) [homeassistant.const] PRESSURE_MMHG was used from gismeteo, this is a deprecated constant which will be removed in HA Core 2025.1. Use UnitOfPressure.MMHG instead, please create a bug report at https://github.com/Limych/ha-gismeteo/issues
2024-01-04 02:04:23.930 WARNING (MainThread) [homeassistant.const] SPEED_KILOMETERS_PER_HOUR was used from gismeteo, this is a deprecated constant which will be removed in HA Core 2025.1. Use UnitOfSpeed.KILOMETERS_PER_HOUR instead, please create a bug report at https://github.com/Limych/ha-gismeteo/issues
2024-01-04 02:04:23.945 WARNING (MainThread) [homeassistant.const] TEMP_CELSIUS was used from gismeteo, this is a deprecated constant which will be removed in HA Core 2025.1. Use UnitOfTemperature.CELSIUS instead, please create a bug report at https://github.com/Limych/ha-gismeteo/issues

Describe the solution you'd like

none

Describe alternatives you've considered

none

Additional context

none

GismeteoWeather is overriding deprecated methods

Environment

  • Home Assistant Core release with the issue:
  • This custom component release with the issue:
  • Last working this custom component release (if known):
  • Operating environment (Home Assistant/Supervisor/Docker/venv):

Home Assistant 2022.7.3
Supervisor 2022.07.0
Operating System 7.6
Frontend 20220707.0 - latest

Describe the bug

Configuration.yaml

Add your configs here if any.

Steps to Reproduce

Expected behavior

Debug log

Logger: homeassistant.components.weather
Source: components/weather/__init__.py:308
Integration: Weather ([documentation](https://www.home-assistant.io/integrations/weather), [issues](https://github.com/home-assistant/home-assistant/issues?q=is%3Aissue+is%3Aopen+label%3A%22integration%3A+weather%22))
First occurred: 12:55:25 (1 occurrences)
Last logged: 12:55:25

custom_components.gismeteo.weather::GismeteoWeather is overriding deprecated methods on an instance of WeatherEntity, this is not valid and will be unsupported from Home Assistant 2023.1. Please report it to the custom component author.

Additional context

Sensor showing up in “home” zone

Is there any way I can prevent an entity from showing up on the map page?
or how to exclude an attribute(latitude, longitude) from an object,
the next customize_glob dosn't work for me
customize_glob:
"sensor.gismeteo_*":
latitude: 12.0784
longitude: 12.0035

After update 2024.1.6 got error

Checklist

  • I have filled out the template to the best of my ability.
  • This only contains 1 feature request (if you have multiple feature requests, open one feature request for each feature request).
  • This issue is not a duplicate feature request of previous feature requests.

Is your feature request related to a problem? Please describe.

After update 2024.1.6 got error:
Logger: homeassistant.config_entries
Source: config_entries.py:406
First occurred: 10:36:28 (1 occurrences)
Last logged: 10:36:28

Error setting up entry configuration.yaml for gismeteo
Traceback (most recent call last):
File "/config/custom_components/gismeteo/api.py", line 226, in async_get_location
xml = etree.fromstring(response)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/xml/etree/ElementTree.py", line 1338, in XML
parser.feed(text)
xml.etree.ElementTree.ParseError: mismatched tag: line 6, column 2

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/config_entries.py", line 406, in async_setup
result = await component.async_setup_entry(hass, self)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/gismeteo/init.py", line 98, in async_setup_entry
coordinator = await _async_get_coordinator(hass, uid, cfg)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/gismeteo/init.py", line 77, in _async_get_coordinator
await gismeteo.async_get_location()
File "/config/custom_components/gismeteo/api.py", line 236, in async_get_location
raise ApiError(
custom_components.gismeteo.api.ApiError: Can't retrieve location data! Invalid server response.

Describe the solution you'd like

Get a working integration, such as updates.

Describe alternatives you've considered

Get a working integration, such as updates.

Additional context

Get a working integration, such as updates.

Not loaded

Checklist

  • I have filled out the template to the best of my ability.
  • This only contains 1 feature request (if you have multiple feature requests, open one feature request for each feature request).
  • This issue is not a duplicate feature request of previous feature requests.

Is your feature request related to a problem? Please describe.

Not loaded 2024.4.4
изображение_2024-04-24_234847631
изображение_2024-04-24_234924439

Settings -> Repairs -> Integration startup time is shown as negative

System Health details

System Information

version core-2024.5.3
installation_type Home Assistant Container
dev false
hassio false
docker true
user root
virtualenv false
python_version 3.12.2
os_name Linux
os_version 5.10.0-16-amd64
arch x86_64
timezone Europe/Moscow
config_dir /config
Home Assistant Cloud
logged_in false
can_reach_cert_server ok
can_reach_cloud_auth ok
can_reach_cloud ok
Dashboards
error failed to load: timeout

Checklist

  • I have enabled debug logging for my installation.
  • I have filled out the issue template to the best of my ability.
  • This issue only contains 1 issue (if you have multiple issues, open one issue for each issue).
  • This issue is not a duplicate issue of any previous issues..

Describe the issue

First I believed that this is a HA core issue & created home-assistant/core#117530
There I was told that it could be a Gismeteo integration issue - that is why I made this issue here.

The issue:
go to Settings -> Repairs -> Integration startup time,
a negative value is shown:

изображение

Quote from a Dev:

It wouldn’t make sense to try to work out the timings for a component that doesn’t await its platform setups since it has a much larger problem that it could get reloaded while its platforms are being setup. Once the component fixes that the timings will be correct.Since the custom component runs at the same privilege level as HA, there is nothing we can do to prevent a custom component from loading platforms without awaiting their setup. IMHO, it’s a good thing that it returns a nonsensical result since it makes it obvious there is a problem with the custom component that needs to be fixed as otherwise it would have probably gone unnoticed

Reproduction steps

go to Settings -> Repairs -> Integration startup time

Debug logs

2024-05-17 03:47:34.241 WARNING (SyncWorker_1) [homeassistant.loader] We found a custom integration gismeteo which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-05-17 03:47:37.929 INFO (MainThread) [homeassistant.bootstrap] Setting up stage 2: {'cover', 'energy', 'counter', 'homeassistant_alerts', 'systemmonitor', 'asuswrt', 'weather', 'ffmpeg', 'template', 'fan', 'mobile_app', 'conversation', 'history', 'application_credentials', 'iphonedetect', 'command_line', 'input_button', 'input_boolean', 'composite', 'system_health', 'device_tracker', 'timer', 'python_script', 'zone', 'tts', 'config', 'scene', 'switch', 'group', 'person', 'image_upload', 'assist_pipeline', 'traccar_server', 'schedule', 'custom_templates', 'lock', 'analytics', 'hacs', 'file_upload', 'diagnostics', 'backup', 'season', 'simpleicons', 'gismeteo', 'input_datetime', 'met', 'logbook', 'device_automation', 'version', 'onboarding', 'ping', 'input_text', 'media_source', 'light', 'stt', 'sensor', 'sun', 'persistent_notification', 'search', 'input_number', 'notify', 'kodi', 'openweathermap', 'intent', 'map', 'starline', 'stream', 'automation', 'filesize', 'input_select', 'trace', 'lovelace', 'fontawesome', 'blueprint', 'wake_word', 'tag', 'uptime', 'places', 'script', 'telegram_bot', 'default_config', 'virtual', 'hardware', 'my', 'narodmon', 'waze_travel_time'}
2024-05-17 03:47:40.150 INFO (MainThread) [homeassistant.setup] Setting up gismeteo
2024-05-17 03:47:40.151 INFO (MainThread) [custom_components.gismeteo]
Gismeteo
https://github.com/Limych/ha-gismeteo/issues
2024-05-17 03:47:40.151 INFO (MainThread) [homeassistant.setup] Setup of domain gismeteo took 0.00 seconds
2024-05-17 03:47:40.151 DEBUG (MainThread) [custom_components.gismeteo.api] Place coordinates: xxxxxxxxxx, xxxxxxxxxx
2024-05-17 03:47:40.151 DEBUG (MainThread) [custom_components.gismeteo.api] Forecast mode: hourly
2024-05-17 03:47:40.151 DEBUG (MainThread) [custom_components.gismeteo.cache] Initializing cache
2024-05-17 03:47:40.151 DEBUG (MainThread) [custom_components.gismeteo.api] Requesting URL https://services.gismeteo.ru/inform-service/inf_chrome/cities/?lat=xxxxxxxxxx&lng=xxxxxxxxxx&count=1&lang=en
2024-05-17 03:47:40.151 DEBUG (MainThread) [custom_components.gismeteo.cache] Read cache file /config/.storage/location_xxxxxxxxxx_xxxxxxxxxx.xml
2024-05-17 03:47:40.157 DEBUG (MainThread) [custom_components.gismeteo.api] Cached response used
2024-05-17 03:47:40.158 DEBUG (MainThread) [custom_components.gismeteo.api] Requesting URL https://services.gismeteo.ru/inform-service/inf_chrome/forecast/?city=xxxxxxxxxx&lang=en
2024-05-17 03:47:40.158 DEBUG (MainThread) [custom_components.gismeteo.cache] Read cache file /config/.storage/forecast_xxxxxxxxxx.xml
2024-05-17 03:47:40.159 DEBUG (MainThread) [custom_components.gismeteo.api] Cached response used
2024-05-17 03:47:40.160 DEBUG (MainThread) [custom_components.gismeteo] Finished fetching gismeteo data in 0.002 seconds (success: True)
2024-05-17 03:47:53.911 INFO (MainThread) [homeassistant.components.weather] Setting up gismeteo.weather
2024-05-17 03:47:54.786 INFO (MainThread) [homeassistant.components.sensor] Setting up gismeteo.sensor
2024-05-17 03:52:53.449 DEBUG (MainThread) [custom_components.gismeteo.api] Requesting URL https://services.gismeteo.ru/inform-service/inf_chrome/forecast/?city=xxxxxxxxxx&lang=en
2024-05-17 03:52:53.450 DEBUG (MainThread) [custom_components.gismeteo.cache] Read cache file /config/.storage/forecast_xxxxxxxxxx.xml
2024-05-17 03:52:53.491 DEBUG (MainThread) [custom_components.gismeteo.api] Data retrieved from https://services.gismeteo.ru/inform-service/inf_chrome/forecast/?city=xxxxxxxxxx&lang=en, status: 200
2024-05-17 03:52:53.492 DEBUG (MainThread) [custom_components.gismeteo.cache] Store cache file /config/.storage/forecast_xxxxxxxxxx.xml
2024-05-17 03:52:53.493 DEBUG (MainThread) [custom_components.gismeteo] Finished fetching gismeteo data in 0.044 seconds (success: True)

Diagnostics dump

No response

Wrong forecast dates

Checklist

  • I have filled out the template to the best of my ability.
  • This only contains 1 feature request (if you have multiple feature requests, open one feature request for each feature request).
  • This issue is not a duplicate feature request of previous feature requests.

Is your feature request related to a problem? Please describe.

The weather forecast has been shifted by a 24 hours, relative to the original on Gismeteo
IMG_5843
IMG_5844

Describe the solution you'd like

Remove 24 hours forecast shift from integration

Describe alternatives you've considered

n/a

Additional context

n/a

RuntimeError: dictionary changed size during iteration

Versions

  • Version of the Home Assistant: core-2021.3.4
  • Version of the custom component: 2.1.1

Configuration

weather:
  - platform: gismeteo
  - platform: gismeteo
    name: "Gismeteo Daily"
    mode: daily


sensor:
  - platform: gismeteo
    forecast: true
    monitored_conditions:
      - weather
      - temperature
      - wind_speed
      - wind_bearing
      - humidity
      - pressure
      - clouds
      - rain
      - snow
      - storm
      - geomagnetic

  - platform: template
    sensors:
      gismeteo_pressure_mmhg:
        device_class: pressure
        unit_of_measurement: 'mmHg'
        friendly_name: "Gismeteo Pressure"
        value_template: "{{ (states('sensor.gismeteo_pressure') | float / 1.33322) | round(1) }}"
        availability_template: "{{ states.sensor.gismeteo_pressure != None }}"

Describe the bug
После обновления до последних версий не стартует компонент.

Debug log


Logger: homeassistant.config_entries
Source: custom_components/gismeteo/__init__.py:95
First occurred: 18:47:23 (1 occurrences)
Last logged: 18:47:23

Error setting up entry configuration.yaml for gismeteo
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 248, in async_setup
    result = await component.async_setup_entry(hass, self)  # type: ignore
  File "/config/custom_components/gismeteo/__init__.py", line 95, in async_setup_entry
    for uid, cfg in hass.data[DOMAIN][CONF_YAML].items():
RuntimeError: dictionary changed size during iteration

allergy. pollen

Is your feature request related to a problem? Please describe.

no

Describe the solution you'd like

I would like to see pollen sensors for birch with a 10-day forecast

Describe alternatives you've considered

Pollen.com and IQWIA. This untegrations supported only USA and GB. Russia do not supported

Additional context

example from website gismeteo.ru
image

How to remove Gismeteo icon from map?

Environment

  • Home Assistant Core release with the issue: Home Assistant 2022.7.6
  • This custom component release with the issue:
  • Last working this custom component release (if known):
  • Operating environment (Home Assistant/Supervisor/Docker/venv):
  • Supervisor 2022.07.0
  • Operating System 8.2
  • Frontend 20220707.1 - latest

Describe the bug

How to remove Gismeteo icon from map?

Configuration.yaml

Not using config file, only UI

Steps to Reproduce

Expected behavior

Debug log


Nothing in a log file

Additional context

ImportError: cannot import name 'PERCENTAGE' from 'homeassistant.const'

В Homeassistant 0.115 отвалились homeassistant.const.PERCENTAGE, а вы их использовали с 2.0.18.
Очень много custom_components на этом полегло.

Поэтому теперь имеем:

Уровень: ERROR
Logger: homeassistant.config
Source: custom_components/gismeteo/const.py:16
First occurred: 8:14:36 (1 occurrences)
Last logged: 8:14:36

Platform error: weather
Traceback (most recent call last):
  File "/srv/homeassistant/lib64/python3.8/site-packages/homeassistant/config.py", line 804, in async_process_component_config
    platform = p_integration.get_platform(domain)
  File "/srv/homeassistant/lib64/python3.8/site-packages/homeassistant/loader.py", line 389, in get_platform
    cache[full_name] = importlib.import_module(
  File "/usr/lib64/python3.8/importlib/__init__.py", line 127, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
  File "<frozen importlib._bootstrap>", line 1014, in _gcd_import
  File "<frozen importlib._bootstrap>", line 991, in _find_and_load
  File "<frozen importlib._bootstrap>", line 961, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
  File "<frozen importlib._bootstrap>", line 1014, in _gcd_import
  File "<frozen importlib._bootstrap>", line 991, in _find_and_load
  File "<frozen importlib._bootstrap>", line 975, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 671, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 783, in exec_module
  File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
  File "/home/homeassistant/.homeassistant/custom_components/gismeteo/__init__.py", line 37, in <module>
    from .const import (
  File "/home/homeassistant/.homeassistant/custom_components/gismeteo/const.py", line 16, in <module>
    from homeassistant.const import (
ImportError: cannot import name 'PERCENTAGE' from 'homeassistant.const' (/srv/homeassistant/lib64/python3.8/site-packages/homeassistant/const.py)

Update for weather.gismeteo fails

2019-08-24 20:44:57 ERROR (MainThread) [homeassistant.helpers.entity] Update for weather.gismeteo fails
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 249, in async_update_ha_state
    await self.async_device_update()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 419, in async_device_update
    await self.hass.async_add_executor_job(self.update)
  File "/usr/local/lib/python3.7/concurrent/futures/thread.py", line 57, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/config/custom_components/gismeteo/weather.py", line 73, in update
    self._wd.update()
  File "/usr/src/homeassistant/homeassistant/util/__init__.py", line 240, in wrapper
    result = method(*args, **kwargs)
  File "/config/custom_components/gismeteo/gismeteo.py", line 352, in update
    xml = etree.fromstring(response)
  File "/usr/local/lib/python3.7/xml/etree/ElementTree.py", line 1315, in XML
    parser.feed(text)
  File "", line None
xml.etree.ElementTree.ParseError: mismatched tag: line 6, column 2

Sensors for current temperature and current humidity are not created as promised in Docs

System Health details

System Information

version core-2024.5.3
installation_type Home Assistant Container
dev false
hassio false
docker true
user root
virtualenv false
python_version 3.12.2
os_name Linux
os_version 5.10.0-16-amd64
arch x86_64
timezone Europe/Moscow
config_dir /config
Home Assistant Community Store
GitHub API ok
GitHub Content ok
GitHub Web ok
GitHub API Calls Remaining 5000
Installed Version 1.34.0
Stage running
Available Repositories 1414
Downloaded Repositories 54
HACS Data pending
Home Assistant Cloud
logged_in false
can_reach_cert_server ok
can_reach_cloud_auth pending
can_reach_cloud ok
Dashboards
dashboards 16
resources 39
views 469
mode storage
Recorder
oldest_recorder_run May 11, 2024 at 21:38
current_recorder_run May 18, 2024 at 04:17
estimated_db_size 578.91 MiB
database_engine sqlite
database_version 3.44.2

Checklist

  • I have enabled debug logging for my installation.
  • I have filled out the issue template to the best of my ability.
  • This issue only contains 1 issue (if you have multiple issues, open one issue for each issue).
  • This issue is not a duplicate issue of any previous issues..

Describe the issue

According to Docs:

изображение

But with this config:

gismeteo:
  home_gismeteo:
    sensors: {}

only a weather entity is created:

изображение

Reproduction steps

see above

Debug logs

2024-05-18 04:17:19.507 WARNING (SyncWorker_1) [homeassistant.loader] We found a custom integration gismeteo which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-05-18 04:17:21.657 INFO (MainThread) [homeassistant.bootstrap] Setting up stage 2: {'narodmon', 'stt', 'iphonedetect', 'energy', 'template', 'search', 'input_boolean', 'system_health', 'input_number', 'input_datetime', 'input_button', 'places', 'season', 'history', 'hardware', 'image_upload', 'default_config', 'tag', 'openweathermap', 'custom_templates', 'diagnostics', 'version', 'media_source', 'notify', 'command_line', 'lock', 'counter', 'switch', 'zone', 'timer', 'application_credentials', 'file_upload', 'weather', 'persistent_notification', 'light', 'met', 'input_select', 'systemmonitor', 'analytics', 'schedule', 'intent', 'person', 'fontawesome', 'onboarding', 'script', 'backup', 'asuswrt', 'python_script', 'logbook', 'traccar_server', 'trace', 'mobile_app', 'map', 'hacs', 'group', 'input_text', 'composite', 'blueprint', 'filesize', 'uptime', 'lovelace', 'scene', 'ffmpeg', 'tts', 'device_automation', 'cover', 'gismeteo', 'ping', 'homeassistant_alerts', 'automation', 'fan', 'wake_word', 'starline', 'virtual', 'assist_pipeline', 'device_tracker', 'waze_travel_time', 'kodi', 'sun', 'sensor', 'stream', 'conversation', 'telegram_bot', 'config', 'my', 'simpleicons'}
2024-05-18 04:17:21.812 INFO (MainThread) [homeassistant.setup] Setting up gismeteo
2024-05-18 04:17:21.812 INFO (MainThread) [custom_components.gismeteo]
Gismeteo
https://github.com/Limych/ha-gismeteo/issues
2024-05-18 04:17:21.812 INFO (MainThread) [homeassistant.setup] Setup of domain gismeteo took 0.00 seconds
2024-05-18 04:17:22.430 DEBUG (MainThread) [custom_components.gismeteo.cache] Initializing cache
2024-05-18 04:17:22.430 DEBUG (MainThread) [custom_components.gismeteo.api] Place coordinates: xxx, xxx
2024-05-18 04:17:22.430 DEBUG (MainThread) [custom_components.gismeteo.api] Requesting URL https://services.gismeteo.ru/inform-service/inf_chrome/cities/?lat=xxx&lng=xxx&count=1&lang=en
2024-05-18 04:17:45.600 DEBUG (MainThread) [custom_components.gismeteo.api] Data retrieved from https://services.gismeteo.ru/inform-service/inf_chrome/cities/?lat=xxx&lng=xxx&count=1&lang=en, status: 200
2024-05-18 04:17:45.601 DEBUG (MainThread) [custom_components.gismeteo.cache] Store cache file /config/.storage/gismeteo.location_xxx_xxx.xml
2024-05-18 04:17:45.602 DEBUG (MainThread) [custom_components.gismeteo.api] Requesting URL https://services.gismeteo.ru/inform-service/inf_chrome/forecast/?city=xxxxx&lang=en
2024-05-18 04:17:48.819 DEBUG (MainThread) [custom_components.gismeteo.api] Data retrieved from https://services.gismeteo.ru/inform-service/inf_chrome/forecast/?city=xxxxx&lang=en, status: 200
2024-05-18 04:17:48.820 DEBUG (MainThread) [custom_components.gismeteo.cache] Store cache file /config/.storage/gismeteo.forecast_xxxxx.xml
2024-05-18 04:17:48.822 DEBUG (MainThread) [custom_components.gismeteo.api] Requesting URL https://services.gismeteo.ru/inform-service/inf_chrome/forecast/?city=xxxxx&lang=en
2024-05-18 04:17:48.823 DEBUG (MainThread) [custom_components.gismeteo.api] Cached response used
2024-05-18 04:17:48.823 DEBUG (MainThread) [custom_components.gismeteo.cache] Read cache file /config/.storage/gismeteo.forecast_xxxxx.xml
2024-05-18 04:17:48.825 DEBUG (MainThread) [custom_components.gismeteo.api] Requesting URL https://www.gismeteo.ru/weather-yyyyy-xxxxx/10-days/
2024-05-18 04:17:51.206 DEBUG (MainThread) [custom_components.gismeteo.api] Data retrieved from https://www.gismeteo.ru/weather-yyyyy-xxxxx/10-days/, status: 200
2024-05-18 04:17:51.213 DEBUG (MainThread) [custom_components.gismeteo.cache] Store cache file /config/.storage/gismeteo.forecast_parsed_xxxxx.xml
2024-05-18 04:17:51.323 DEBUG (MainThread) [custom_components.gismeteo] Finished fetching gismeteo data in 5.721 seconds (success: True)
2024-05-18 04:17:51.392 INFO (MainThread) [homeassistant.components.sensor] Setting up gismeteo.sensor
2024-05-18 04:17:51.392 INFO (MainThread) [homeassistant.components.weather] Setting up gismeteo.weather
2024-05-18 04:17:51.392 INFO (MainThread) [homeassistant.helpers.entity_registry] Registered new weather.gismeteo entity: weather.home_gismeteo
2024-05-18 04:19:58.840 WARNING (MainThread) [homeassistant.core] Something is blocking Home Assistant from wrapping up the start up phase. We're going to continue anyway. Please report the following info at https://github.com/home-assistant/core/issues: season.sensor, homeassistant.scene, systemmonitor.binary_sensor, repairs, stt, kodi.media_player, api, template, search, template.binary_sensor, template.switch, system_health, xiaomi_miio_airpurifier.fan, cloud.tts, iphonedetect.device_tracker, ssdp, input_button, snmp.sensor, auth, recorder, hardware, bluetooth, tag, openweathermap.sensor, openweathermap, diagnostics, custom_templates, version, media_source, systemmonitor.sensor, default_config, command_line, counter, switch, weather, file_upload, zeroconf, mobile_app.notify, met.weather, persistent_notification, starline.button, intent, person, system_log, backup, starline.sensor, starline.switch, netdata.sensor, openhardwaremonitor.sensor, python_script, version.binary_sensor, mobile_app.binary_sensor, traccar_server, template.fan, mobile_app, hacs, webhook, virtual.fan, starline.device_tracker, filesize, lovelace, virtual.lock, ping.device_tracker, device_automation, logger, gismeteo, cover, ping.binary_sensor, gismeteo.weather, virtual.light, wake_word, fan, history_stats.sensor, ping.sensor, starline, filesize.sensor, network, websocket_api, virtual, waze_travel_time, template.cover, sun.sensor, derivative.sensor, kodi, http, virtual.device_tracker, sensor, config, telegram_bot, my, simpleicons, google_translate.tts, command_line.sensor, binary_sensor, template.sensor, narodmon, iphonedetect, energy, input_boolean, input_number, uptime.sensor, telegram.notify, input_datetime, media_player, places, season, history, image_upload, usb, composite.device_tracker, notify, lock, zone, timer, application_credentials, websocket_api.sensor, light, met, input_select, systemmonitor, update, hacs.update, clear_grass.sensor, analytics, schedule, fontawesome, onboarding, mobile_app.device_tracker, script, asuswrt, logbook, trace, energy.sensor, map, integration.sensor, starline.lock, gismeteo.sensor, group, input_text, composite, homeassistant, blueprint, mobile_app.sensor, uptime, version.sensor, scene, ffmpeg, tts, homeassistant_alerts, ping, cloud, starline.binary_sensor, automation, hacs.sensor, button, dhcp, frontend, assist_pipeline, device_tracker, composite.sensor, sun, image, waze_travel_time.sensor, stream, conversation, openweathermap.weather, template.image, places.sensor The system is waiting for tasks: {<Task pending name='Task-3293' coro=<HacsBase.startup_tasks() running at /config/custom_components/hacs/base.py:687> wait_for=<_GatheringFuture pending cb=[Task.task_wakeup()]> cb=[set.remove()]>}
2024-05-18 04:22:51.141 DEBUG (MainThread) [custom_components.gismeteo.api] Requesting URL https://services.gismeteo.ru/inform-service/inf_chrome/forecast/?city=xxxxx&lang=en
2024-05-18 04:22:51.451 DEBUG (MainThread) [custom_components.gismeteo.api] Data retrieved from https://services.gismeteo.ru/inform-service/inf_chrome/forecast/?city=xxxxx&lang=en, status: 200
2024-05-18 04:22:51.452 DEBUG (MainThread) [custom_components.gismeteo.cache] Store cache file /config/.storage/gismeteo.forecast_xxxxx.xml
2024-05-18 04:22:51.454 DEBUG (MainThread) [custom_components.gismeteo] Finished fetching gismeteo data in 0.313 seconds (success: True)

Diagnostics dump

No response

Weather stopped updating 2 weeks ago

Version of the custom_component

Configuration

Add your configs here.

Describe the bug

A clear and concise description of what the bug is.

Debug log


Add your logs here.

unit ° thus indicating it has a numeric value; however, it has the non-numeric value: unknown

Environment

  • Home Assistant Core release with the issue: Home Assistant 2023.3.3 Supervisor 2023.03.1 Frontend 20230309.0 - latest
  • This custom component release with the issue: 2.5.1
  • Last working this custom component release (if known):
  • Operating environment (Home Assistant/Supervisor/Docker/venv):

Describe the bug

Configuration.yaml

weather:
  - platform: gismeteo

Steps to Reproduce

Expected behavior

Debug log


Add your logs here.

Logger: homeassistant.components.sensor
Source: components/sensor/__init__.py:597
Integration: Sensor ([documentation](https://www.home-assistant.io/integrations/sensor), [issues](https://github.com/home-assistant/home-assistant/issues?q=is%3Aissue+is%3Aopen+label%3A%22integration%3A+sensor%22))
First occurred: 8:16:41 AM (1 occurrences)
Last logged: 8:16:41 AM
Sensor sensor.my_smart_home_wind_bearing has device class None, state class None and unit ° thus indicating it has a numeric value; however, it has the non-numeric value: unknown (<class 'str'>); Please update your configuration if your entity is manually configured, otherwise report it to the custom integration author.

**Additional context**
<!--
  Add any other context about the problem here.
-->

Error sensor.gismeteo_rain

Environment

  • Home Assistant Core release with the issue: core-2021.12.3
  • This custom component release with the issue: 2.3.3
  • Last working this custom component release (if known):
  • Operating environment (Home Assistant/Supervisor/Docker/venv): Home Assistant Docker Container

Describe the bug
Logger: homeassistant.helpers.entity
Source: helpers/entity.py:549
First occurred: 16:18:20 (10 occurrences)
Last logged: 16:18:20

Entity sensor.gismeteo_rain (<class 'custom_components.gismeteo.sensor.GismeteoSensor'>) implements device_state_attributes. Please report it to the custom component author.
Entity sensor.gismeteo_snow (<class 'custom_components.gismeteo.sensor.GismeteoSensor'>) implements device_state_attributes. Please report it to the custom component author.
Entity sensor.gismeteo_storm (<class 'custom_components.gismeteo.sensor.GismeteoSensor'>) implements device_state_attributes. Please report it to the custom component author.
Entity sensor.gismeteo_temperature (<class 'custom_components.gismeteo.sensor.GismeteoSensor'>) implements device_state_attributes. Please report it to the custom component author.
Entity sensor.gismeteo_wind_speed (<class 'custom_components.gismeteo.sensor.GismeteoSensor'>) implements device_state_attributes. Please report it to the custom component author.

Configuration.yaml

weather:
  - platform: gismeteo

Steps to Reproduce

Expected behavior
No errors or warnings.

Debug log


Add your logs here.

Additional context

Sunrise and sunset

Thank you very much for your excellent job!
Could you add sunrise and sunset information to the add-on?
image

ERROR (SyncWorker_0) [custom_components.gismeteo] Can't detect nearest city!

Home Assistant 0.116.2
Компонент последней версии.
Настройки конфигурации:

weather:
  - platform: gismeteo
    mode: daily

Ошибка в логах: ERROR (SyncWorker_0) [custom_components.gismeteo] Can't detect nearest city!
Перестала отображаться карточка : Lovelace animated weather card
с надпись: "Entity not available: weather.gismeteo"

p.s.
при загрузке сервиса такие ошибки:
File "/opt/homeassistant/lib/python3.9/site-packages/homeassistant/helpers/entity.py", line 296, in async_write_ha_state
self._async_write_ha_state()
File "/opt/homeassistant/lib/python3.9/site-packages/homeassistant/helpers/entity.py", line 322, in _async_write_ha_state
attr.update(self.state_attributes or {})
File "/opt/homeassistant/lib/python3.9/site-packages/homeassistant/components/weather/init.py", line 145, in state_attributes
data[ATTR_WEATHER_TEMPERATURE] = show_temp(
File "/opt/homeassistant/lib/python3.9/site-packages/homeassistant/helpers/temperature.py", line 23, in display_temp
raise TypeError(f"Temperature is not a number: {temperature}")
TypeError: Temperature is not a number: unknown

Gismeteo не работает через службу weather.get_forecasts

Checklist

  • I have filled out the template to the best of my ability.
  • This only contains 1 feature request (if you have multiple feature requests, open one feature request for each feature request).
  • This issue is not a duplicate feature request of previous feature requests.

Is your feature request related to a problem? Please describe.

При попытке вызвать службу данных о погоде weather.get_forecasts - gismeteo не отображается в списке доступных. Соответственно, прогноз gismeteo не отображается в кастомной карте Weather Chart Card (https://github.com/mlamberts78/weather-chart-card/issues).

IMG_4513

Также в журнале сервера есть предупреждения об устаревших атрибутах:

IMG_4515
IMG_4516

Describe the solution you'd like

Было бы супер, если бы gismeteo обновился до версии 3, с новыми изменениями, которые позволят полноценно использовать эту интеграцию

Describe alternatives you've considered

Xxx

Additional context

Xxx

After last update HA Gismeteo component not working

Environment

  • Home Assistant Core release with the issue: core-2022.5.1
  • This custom component release with the issue: 2.3.4
  • Last working this custom component release (if known):
  • Operating environment (Home Assistant/Supervisor/Docker/venv): Supervisor

Describe the bug
After last update HA Gismeteo component not working

Configuration.yaml

weather:
- platform: gismeteo
  name: Home (Gismeteo)
  mode: daily
  latitude: 59.94
  longitude: 30.32

sensor:
  - platform: gismeteo
    monitored_conditions:
      - condition
      - temperature
      - temperature_feels_like
      - humidity
      - pressure
      - wind_speed
      - wind_bearing
      - clouds
      - rain
      - snow
      - storm
      - geomagnetic

Add your configs here if any.

Steps to Reproduce

Expected behavior

Debug log


Logger: homeassistant.config_entries
Source: custom_components/gismeteo/api.py:207
Integration: Gismeteo ([documentation](https://github.com/Limych/ha-gismeteo), [issues](https://github.com/Limych/ha-gismeteo/issues))
First occurred: 17:00:18 (1 occurrences)
Last logged: 17:00:18

Error setting up entry configuration.yaml for gismeteo
Traceback (most recent call last):
  File "/config/custom_components/gismeteo/api.py", line 198, in async_get_location
    xml = etree.fromstring(response)
  File "/usr/local/lib/python3.9/xml/etree/ElementTree.py", line 1347, in XML
    parser.feed(text)
xml.etree.ElementTree.ParseError: mismatched tag: line 6, column 2

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 335, in async_setup
    result = await component.async_setup_entry(hass, self)
  File "/config/custom_components/gismeteo/__init__.py", line 98, in async_setup_entry
    coordinator = await _async_get_coordinator(hass, uid, cfg)
  File "/config/custom_components/gismeteo/__init__.py", line 77, in _async_get_coordinator
    await gismeteo.async_get_location()
  File "/config/custom_components/gismeteo/api.py", line 207, in async_get_location
    raise ApiError(
custom_components.gismeteo.api.ApiError: Can't retrieve location data! Invalid server response.

Additional context

Frequently become Unavailable

Environment

System Health

version core-2021.7.3
installation_type Home Assistant OS
dev false
hassio true
docker true
virtualenv false
python_version 3.9.5
os_name Linux
os_version 5.10.17-v8
arch aarch64
timezone Europe/Riga
Home Assistant Community Store
GitHub API ok
Github API Calls Remaining 4876
Installed Version 1.13.2
Stage running
Available Repositories 912
Installed Repositories 20
Home Assistant Cloud
logged_in false
can_reach_cert_server ok
can_reach_cloud_auth ok
can_reach_cloud pending
Home Assistant Supervisor
host_os Home Assistant OS 6.1
update_channel stable
supervisor_version supervisor-2021.06.8
docker_version 20.10.6
disk_total 54.3 GB
disk_used 13.5 GB
healthy true
supported true
board rpi4-64
supervisor_api ok
version_api ok
installed_addons Samba Backup (4.5.0), SSH & Web Terminal (9.0.0), File editor (5.3.3), Mosquitto broker (5.1.1), Z-Wave JS to MQTT (0.23.2), Zigbee2mqtt (1.18.2-1), MariaDB (2.4.0), phpMyAdmin (0.4.3), Samba share (9.5.0)
Lovelace
dashboards 8
resources 8
views 29
mode storage

Describe the bug

As far as I noticed - after core upgrade to 2021.7.x Gismeteo intergration entities frequently (several times par day) become unavailable. But not sure this (HA core version) is a reason.

Configuration.yaml

Add your configs here if any.

Steps to Reproduce

Expected behavior

Debug log


2021-07-27 15:50:20 ERROR (MainThread) [custom_components.gismeteo] Error fetching gismeteo data: Can't update weather data! Invalid server response.

Additional context

After integration restart it starts to show data.

The custom integration gismeteo implements the forecast property or sets self._attr_forecast in a subclass of WeatherEntity.

Checklist

  • I have filled out the template to the best of my ability.
  • This only contains 1 feature request (if you have multiple feature requests, open one feature request for each feature request).
  • This issue is not a duplicate feature request of previous feature requests.

Is your feature request related to a problem? Please describe.

Это приведет к неисправностям в версии 2024.3.0. Пожалуйста, устраните эту проблему перед обновлением.

The custom integration gismeteo implements the forecast property or sets self._attr_forecast in a subclass of WeatherEntity.

Please create a bug report at https://github.com/Limych/ha-gismeteo/issues.

Once an updated version of gismeteo is available, install it and restart Home Assistant to fix this issue.

Describe the solution you'd like

fix the the forecast property , WeatherEntity

Describe alternatives you've considered

No idea

Additional context

No context

After updating Home Assistant 2023.9.0, there was a change of weather entities, an integration correction is needed.

Environment

  • Home Assistant Core release with the issue: Home Assistant 2023.9.0 Supervisor 2023.08.3 Frontend 20230309.0 - latest
  • This custom component release with the issue: 2.5.1
  • Last working this custom component release (if known): 2.5.1
  • Operating environment (Home Assistant/Supervisor/Docker/venv): Home Assistant/Supervisor/Docker

Describe the bug

After updating Home Assistant 2023.9.0, there was a change of weather entities, an integration correction is needed. I receive a message :

gismeteo integration uses an outdated forecast attribute.

Please report it to the custom integration author..

This will cause malfunctions in version 2024.3.0. Please fix this problem before updating.

Configuration.yaml

Add your configs here if any.

Steps to Reproduce

Install Home Assistant 2023.9.0 - latest

Expected behavior

Debug log


Add your logs here.

Additional context

Yesterday weather

Environment

  • Home Assistant Core release with the issue: 2021-6-0
  • This custom component release with the issue: 2.3.3
  • Last working this custom component release (if known): 2.3.3
  • Operating environment (Home Assistant/Supervisor/Docker/venv): Supervisor

Describe the bug
The component returns to HA yesterday among forecast days.
Looks in UI
image
Now Thursday and 6/3 but not 6/2

Gismeteo API respond for https://services.gismeteo.ru/inform-service/inf_chrome/forecast/?city=229845&lang=en
image

Configuration.yaml

  - name: gismeteo
    platform: gismeteo
    mode: daily
  - name: gismeteo_h
    platform: gismeteo
    mode: hourly

Steps to Reproduce

Expected behavior
Before 6/1 (apx) the component returned correct dates today, tomorrow...

Debug log
There're no any errors in logs
2021-06-03 20:32:30 DEBUG (MainThread) [custom_components.gismeteo.api] Data retrieved from https://services.gismeteo.ru/inform-service/inf_chrome/cities/?lat=54.1941381&lng=37.6877873&count=1&lang=en, status: 200 2021-06-03 20:32:30 DEBUG (MainThread) [custom_components.gismeteo.cache] Store cache file /config/.storage/location_54.1941381_37.6877873.xml 2021-06-03 20:32:30 DEBUG (MainThread) [custom_components.gismeteo.api] Requesting URL https://services.gismeteo.ru/inform-service/inf_chrome/forecast/?city=229845&lang=en 2021-06-03 20:32:30 DEBUG (MainThread) [custom_components.gismeteo.api] Cached response used 2021-06-03 20:32:30 DEBUG (MainThread) [custom_components.gismeteo.cache] Read cache file /config/.storage/forecast_229845.xml 2021-06-03 20:32:30 DEBUG (MainThread) [custom_components.gismeteo] Finished fetching gismeteo data in 0.067 seconds 2021-06-03 20:32:30 DEBUG (MainThread) [custom_components.gismeteo.api] Place coordinates: 54.1941381, 37.6877873 2021-06-03 20:32:30 DEBUG (MainThread) [custom_components.gismeteo.api] Forecast mode: hourly 2021-06-03 20:32:30 DEBUG (MainThread) [custom_components.gismeteo.cache] Initializing cache 2021-06-03 20:32:30 DEBUG (MainThread) [custom_components.gismeteo.api] Requesting URL https://services.gismeteo.ru/inform-service/inf_chrome/cities/?lat=54.1941381&lng=37.6877873&count=1&lang=en 2021-06-03 20:32:30 DEBUG (MainThread) [custom_components.gismeteo.api] Cached response used 2021-06-03 20:32:30 DEBUG (MainThread) [custom_components.gismeteo.cache] Read cache file /config/.storage/location_54.1941381_37.6877873.xml 2021-06-03 20:32:30 DEBUG (MainThread) [custom_components.gismeteo.api] Requesting URL https://services.gismeteo.ru/inform-service/inf_chrome/forecast/?city=229845&lang=en 2021-06-03 20:32:30 DEBUG (MainThread) [custom_components.gismeteo.api] Cached response used 2021-06-03 20:32:30 DEBUG (MainThread) [custom_components.gismeteo.cache] Read cache file /config/.storage/forecast_229845.xml 2021-06-03 20:32:30 DEBUG (MainThread) [custom_components.gismeteo] Finished fetching gismeteo data in 0.089 seconds

Stopped working after restart

Versions

  • Version of the Home Assistant: 116.2
  • Version of the custom component: latest

Describe the bug

Component suddenly Stopped working after НА restart


2020-10-15 18:58:20 ERROR (MainThread) [homeassistant.components.weather] gismeteo: Error on device update!
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 346, in _async_add_entity
    await entity.async_device_update(warning=False)
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 471, in async_device_update
    await self.hass.async_add_executor_job(self.update)  # type: ignore
  File "/usr/local/lib/python3.8/concurrent/futures/thread.py", line 57, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/config/custom_components/gismeteo/weather.py", line 85, in update
    self._wd.update()
  File "/usr/src/homeassistant/homeassistant/util/__init__.py", line 239, in wrapper
    result = method(*args, **kwargs)
  File "/config/custom_components/gismeteo/__init__.py", line 347, in update
    ATTR_WEATHER_PHENOMENON: int(current_v.get("ph")),
ValueError: invalid literal for int() with base 10: 'Array'

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.