Unverified Commit 9ce2e1a4 authored by Martin Weinelt's avatar Martin Weinelt
Browse files

python310Packages.homeassistant-stubs: Relax home-assistant version

Pin the home-assistant version constraint to the year and month of a
release, to allow easier upgrades within a month, where the number of
typing changes is probably lower.
parent 4e04af68
Loading
Loading
Loading
Loading
+8 −0
Original line number Diff line number Diff line
@@ -25,6 +25,14 @@ buildPythonPackage rec {
    home-assistant
  ];

  postPatch = ''
    # Relax constraint to year and month
    substituteInPlace pyproject.toml --replace \
      'homeassistant = "${version}"' \
      'homeassistant = "~${lib.versions.majorMinor home-assistant.version}"'
    cat pyproject.toml
  '';

  pythonImportsCheck = [
    "homeassistant-stubs"
  ];