[arch-commits] Commit in home-assistant/trunk (3 files)

Maxime Gauduin alucryd at archlinux.org
Wed Apr 14 16:49:48 UTC 2021


    Date: Wednesday, April 14, 2021 @ 16:49:48
  Author: alucryd
Revision: 918479

upgpkg: home-assistant 2021.4.4-1

Added:
  home-assistant/trunk/home-assistant-dhcp-component.patch
Modified:
  home-assistant/trunk/PKGBUILD
  home-assistant/trunk/home-assistant-astral2.2.patch

-------------------------------------+
 PKGBUILD                            |   17 ++----
 home-assistant-astral2.2.patch      |   90 +++++++++++++++++-----------------
 home-assistant-dhcp-component.patch |   67 +++++++++++++++++++++++++
 3 files changed, 119 insertions(+), 55 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2021-04-14 16:34:10 UTC (rev 918478)
+++ PKGBUILD	2021-04-14 16:49:48 UTC (rev 918479)
@@ -6,8 +6,8 @@
 
 pkgname=home-assistant
 pkgdesc='Open source home automation that puts local control and privacy first'
-pkgver=2021.1.5
-pkgrel=2
+pkgver=2021.4.4
+pkgrel=1
 arch=(any)
 url=https://home-assistant.io/
 license=(APACHE)
@@ -50,27 +50,27 @@
   'python-dtlssocket: Ikea Tradfri integration'
   'python-lxml: Meteo France integration'
 )
-_tag=6715eae3d7f7d20a37c2c2aa85be6566c4e43939
+_tag=b5548c57fbab553ca72c224391b473f6228e928a
 source=(
   git+https://github.com/home-assistant/home-assistant.git#tag=${_tag}
   home-assistant.service
   home-assistant-astral2.2.patch
+  home-assistant-dhcp-component.patch
 )
 b2sums=('SKIP'
         '0df7bbfdac09e37294ac27567e677855c72d13be3aefbd23e0a8f101cf2148302affbe9b6b586b893f77fc990f665d7b95f4916583680c06abd8f74b5cdf3da9'
-        'b21f1e662c242a10b0fdd8727dfb25a293e13ca3f431d49c2f7ef5b5427ad5b89ce6e7fe399a8bbad986c4e128c94be571227f67778764cf5441bf1f8dc00eaf')
+        '4458692cb10e0832c1b321b96d74d7dd7e5e0e9e9b23d420efec9e27e5b0f34ef33f64789b05fbc5ec49337002ad26b026079b939741bbf16869c52c9316ef34'
+        '17f86a3bf06e0aaafee8609fae5e5f8a4d54e75232fcc8af949f0d574be5d9f29b13040d5a3665d717380fd0d71125e1c9e0277ffaab142d9beaf122dd59df60')
 
 pkgver() {
   cd home-assistant
-
   git describe --tags
 }
 
 prepare() {
   cd home-assistant
-
   patch -Np1 -i ../home-assistant-astral2.2.patch
-
+  patch -Np1 -i ../home-assistant-dhcp-component.patch
   # lift hard dep constraints, we'll deal with breaking changes ourselves
   sed 's/==/>=/g' -i requirements.txt setup.py homeassistant/package_constraints.txt
   # allow pip >= 20.3 to be used
@@ -79,15 +79,12 @@
 
 build() {
   cd home-assistant
-
   python setup.py build
 }
 
 package() {
   cd home-assistant
-
   python setup.py install --root="${pkgdir}" --prefix=/usr --optimize=1 --skip-build
-
   install -Dm 644 ../home-assistant.service -t "${pkgdir}"/usr/lib/systemd/system/
 }
 

Modified: home-assistant-astral2.2.patch
===================================================================
--- home-assistant-astral2.2.patch	2021-04-14 16:34:10 UTC (rev 918478)
+++ home-assistant-astral2.2.patch	2021-04-14 16:49:48 UTC (rev 918479)
@@ -1,19 +1,19 @@
-From 3acb6a4f847db45426328768c0ca874f361efaf2 Mon Sep 17 00:00:00 2001
-From: Maxime Gauduin <alucryd at archlinux.org>
-Date: Thu, 27 Feb 2020 17:27:37 +0100
+From a96a731fb1a2814f88e574a266b051f401d8a262 Mon Sep 17 00:00:00 2001
+From: Maxime Gauduin <alucryd at gmail.com>
+Date: Wed, 14 Apr 2021 08:40:16 +0200
 Subject: [PATCH] bump astral to 2.2
 
 ---
  homeassistant/components/moon/sensor.py  |  5 +--
  homeassistant/components/sun/__init__.py | 20 +++++-----
- homeassistant/helpers/sun.py             | 51 ++++++++++++++----------
+ homeassistant/helpers/sun.py             | 50 +++++++++++++++---------
  homeassistant/package_constraints.txt    |  2 +-
  requirements.txt                         |  2 +-
  setup.py                                 |  2 +-
- 6 files changed, 47 insertions(+), 35 deletions(-)
+ 6 files changed, 47 insertions(+), 34 deletions(-)
 
 diff --git a/homeassistant/components/moon/sensor.py b/homeassistant/components/moon/sensor.py
-index 9e0f8ef51d..9b29b071ee 100644
+index 4b373469cc..6213e218d2 100644
 --- a/homeassistant/components/moon/sensor.py
 +++ b/homeassistant/components/moon/sensor.py
 @@ -1,5 +1,5 @@
@@ -22,8 +22,8 @@
 +from astral import moon
  import voluptuous as vol
  
- from homeassistant.components.sensor import PLATFORM_SCHEMA
-@@ -49,7 +49,6 @@ class MoonSensor(Entity):
+ from homeassistant.components.sensor import PLATFORM_SCHEMA, SensorEntity
+@@ -48,7 +48,6 @@ class MoonSensor(SensorEntity):
          """Initialize the moon sensor."""
          self._name = name
          self._state = None
@@ -31,7 +31,7 @@
  
      @property
      def name(self):
-@@ -88,4 +87,4 @@ class MoonSensor(Entity):
+@@ -87,4 +86,4 @@ class MoonSensor(SensorEntity):
      async def async_update(self):
          """Get the time and updates the states."""
          today = dt_util.as_local(dt_util.utcnow()).date()
@@ -38,7 +38,7 @@
 -        self._state = self._astral.moon_phase(today)
 +        self._state = moon.phase(today)
 diff --git a/homeassistant/components/sun/__init__.py b/homeassistant/components/sun/__init__.py
-index 2d921da4a4..ec8f4b325a 100644
+index dfe3b15c11..489eab6b5b 100644
 --- a/homeassistant/components/sun/__init__.py
 +++ b/homeassistant/components/sun/__init__.py
 @@ -92,6 +92,7 @@ class Sun(Entity):
@@ -115,18 +115,19 @@
  
          _LOGGER.debug(
 diff --git a/homeassistant/helpers/sun.py b/homeassistant/helpers/sun.py
-index 818010c341..f1f7ee1f19 100644
+index b3a37d238f..b5bac8d71b 100644
 --- a/homeassistant/helpers/sun.py
 +++ b/homeassistant/helpers/sun.py
-@@ -1,6 +1,6 @@
- """Helpers for sun events."""
+@@ -2,7 +2,7 @@
+ from __future__ import annotations
+ 
  import datetime
--from typing import TYPE_CHECKING, Optional, Union
+-from typing import TYPE_CHECKING
 +from typing import TYPE_CHECKING, Optional, Tuple, Union
  
  from homeassistant.const import SUN_EVENT_SUNRISE, SUN_EVENT_SUNSET
- from homeassistant.core import callback
-@@ -14,28 +14,32 @@ if TYPE_CHECKING:
+ from homeassistant.core import HomeAssistant, callback
+@@ -14,27 +14,32 @@ if TYPE_CHECKING:
  
  DATA_LOCATION_CACHE = "astral_location_cache"
  
@@ -135,16 +136,15 @@
  
  @callback
  @bind_hass
--def get_astral_location(hass: HomeAssistantType) -> "astral.Location":
+-def get_astral_location(hass: HomeAssistant) -> astral.Location:
 +def get_astral_location(
-+    hass: HomeAssistantType,
++    hass: HomeAssistant,
 +) -> Tuple["astral.location.Location", "astral.Elevation"]:
      """Get an astral location for the current Home Assistant configuration."""
+-    from astral import Location  # pylint: disable=import-outside-toplevel
 +    from astral import LocationInfo # pylint: disable=import-outside-toplevel
 +    from astral.location import Location # pylint: disable=import-outside-toplevel
  
--    from astral import Location  # pylint: disable=import-outside-toplevel
--
 +    timezone = str(hass.config.time_zone)
      latitude = hass.config.latitude
      longitude = hass.config.longitude
@@ -166,8 +166,8 @@
  
  
  @callback
-@@ -47,26 +51,31 @@ def get_astral_event_next(
-     offset: Optional[datetime.timedelta] = None,
+@@ -46,26 +51,31 @@ def get_astral_event_next(
+     offset: datetime.timedelta | None = None,
  ) -> datetime.datetime:
      """Calculate the next specified solar event."""
 -    location = get_astral_location(hass)
@@ -180,12 +180,12 @@
  
  @callback
  def get_location_astral_event_next(
--    location: "astral.Location",
+-    location: astral.Location,
 +    location: "astral.location.Location",
 +    elevation: "astral.Elevation",
      event: str,
-     utc_point_in_time: Optional[datetime.datetime] = None,
-     offset: Optional[datetime.timedelta] = None,
+     utc_point_in_time: datetime.datetime | None = None,
+     offset: datetime.timedelta | None = None,
  ) -> datetime.datetime:
      """Calculate the next specified solar event."""
 -    from astral import AstralError  # pylint: disable=import-outside-toplevel
@@ -203,7 +203,7 @@
      mod = -1
      while True:
          try:
-@@ -74,13 +83,13 @@ def get_location_astral_event_next(
+@@ -73,13 +83,13 @@ def get_location_astral_event_next(
                  getattr(location, event)(
                      dt_util.as_local(utc_point_in_time).date()
                      + datetime.timedelta(days=mod),
@@ -219,9 +219,9 @@
              pass
          mod += 1
  
-@@ -93,9 +102,7 @@ def get_astral_event_date(
-     date: Union[datetime.date, datetime.datetime, None] = None,
- ) -> Optional[datetime.datetime]:
+@@ -92,9 +102,7 @@ def get_astral_event_date(
+     date: datetime.date | datetime.datetime | None = None,
+ ) -> datetime.datetime | None:
      """Calculate the astral event time for the specified date."""
 -    from astral import AstralError  # pylint: disable=import-outside-toplevel
 -
@@ -230,7 +230,7 @@
  
      if date is None:
          date = dt_util.now().date()
-@@ -103,9 +110,13 @@ def get_astral_event_date(
+@@ -102,9 +110,13 @@ def get_astral_event_date(
      if isinstance(date, datetime.datetime):
          date = dt_util.as_local(date).date()
  
@@ -247,44 +247,44 @@
          return None
  
 diff --git a/homeassistant/package_constraints.txt b/homeassistant/package_constraints.txt
-index fa9a1ed564..5e6589bda5 100644
+index c5f0ccde05..449c0602df 100644
 --- a/homeassistant/package_constraints.txt
 +++ b/homeassistant/package_constraints.txt
-@@ -2,7 +2,7 @@ PyJWT==1.7.1
- PyNaCl==1.3.0
- aiohttp==3.7.3
+@@ -3,7 +3,7 @@ PyNaCl==1.3.0
+ aiodiscover==1.3.3
+ aiohttp==3.7.4.post0
  aiohttp_cors==0.7.0
 -astral==1.10.1
 +astral==2.2
+ async-upnp-client==0.16.0
  async_timeout==3.0.1
- attrs==19.3.0
- bcrypt==3.1.7
+ attrs==20.3.0
 diff --git a/requirements.txt b/requirements.txt
-index ece5a5a370..0b5d6622fd 100644
+index 5f633eaeb6..a3facbe5ab 100644
 --- a/requirements.txt
 +++ b/requirements.txt
 @@ -2,7 +2,7 @@
  
  # Home Assistant Core
- aiohttp==3.7.3
+ aiohttp==3.7.4.post0
 -astral==1.10.1
 +astral==2.2
  async_timeout==3.0.1
- attrs==19.3.0
- bcrypt==3.1.7
+ attrs==20.3.0
+ awesomeversion==21.2.3
 diff --git a/setup.py b/setup.py
-index 096e376b1a..f2034408f0 100755
+index 56e5639148..f74a913cb8 100755
 --- a/setup.py
 +++ b/setup.py
 @@ -33,7 +33,7 @@ PACKAGES = find_packages(exclude=["tests", "tests.*"])
  
  REQUIRES = [
-     "aiohttp==3.7.3",
+     "aiohttp==3.7.4.post0",
 -    "astral==1.10.1",
 +    "astral==2.2",
      "async_timeout==3.0.1",
-     "attrs==19.3.0",
-     "bcrypt==3.1.7",
+     "attrs==20.3.0",
+     "awesomeversion==21.2.3",
 -- 
-2.30.0
+2.31.1
 

Added: home-assistant-dhcp-component.patch
===================================================================
--- home-assistant-dhcp-component.patch	                        (rev 0)
+++ home-assistant-dhcp-component.patch	2021-04-14 16:49:48 UTC (rev 918479)
@@ -0,0 +1,67 @@
+From d3b9bc1d50ab485106850f672ae885c2a3d5c161 Mon Sep 17 00:00:00 2001
+From: Maxime Gauduin <alucryd at archlinux.org>
+Date: Wed, 14 Apr 2021 18:41:03 +0200
+Subject: [PATCH] bugfix: dhcp component
+
+---
+ homeassistant/components/dhcp/manifest.json | 2 +-
+ homeassistant/package_constraints.txt       | 2 +-
+ requirements_all.txt                        | 2 +-
+ requirements_test_all.txt                   | 2 +-
+ 4 files changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/homeassistant/components/dhcp/manifest.json b/homeassistant/components/dhcp/manifest.json
+index 80cc6b116c..af072d276f 100644
+--- a/homeassistant/components/dhcp/manifest.json
++++ b/homeassistant/components/dhcp/manifest.json
+@@ -3,7 +3,7 @@
+   "name": "DHCP Discovery",
+   "documentation": "https://www.home-assistant.io/integrations/dhcp",
+   "requirements": [
+-    "scapy==2.4.4", "aiodiscover==1.3.3"
++    "scapy==2.4.5rc1", "aiodiscover==1.3.3"
+   ],
+   "codeowners": [
+     "@bdraco"
+diff --git a/homeassistant/package_constraints.txt b/homeassistant/package_constraints.txt
+index 449c0602df..5a0f07e64f 100644
+--- a/homeassistant/package_constraints.txt
++++ b/homeassistant/package_constraints.txt
+@@ -28,7 +28,7 @@ pytz>=2021.1
+ pyyaml==5.4.1
+ requests==2.25.1
+ ruamel.yaml==0.15.100
+-scapy==2.4.4
++scapy==2.4.5rc1
+ sqlalchemy==1.3.23
+ voluptuous-serialize==2.4.0
+ voluptuous==0.12.1
+diff --git a/requirements_all.txt b/requirements_all.txt
+index 4831b310f8..53e49c9bfc 100644
+--- a/requirements_all.txt
++++ b/requirements_all.txt
+@@ -2006,7 +2006,7 @@ samsungtvws==1.6.0
+ satel_integra==0.3.4
+ 
+ # homeassistant.components.dhcp
+-scapy==2.4.4
++scapy==2.4.5rc1
+ 
+ # homeassistant.components.deutsche_bahn
+ schiene==0.23
+diff --git a/requirements_test_all.txt b/requirements_test_all.txt
+index 33ef9a95aa..169d6d089b 100644
+--- a/requirements_test_all.txt
++++ b/requirements_test_all.txt
+@@ -1046,7 +1046,7 @@ samsungctl[websocket]==0.7.1
+ samsungtvws==1.6.0
+ 
+ # homeassistant.components.dhcp
+-scapy==2.4.4
++scapy==2.4.5rc1
+ 
+ # homeassistant.components.screenlogic
+ screenlogicpy==0.2.1
+-- 
+2.31.1
+



More information about the arch-commits mailing list