2 Commits fd53801cf2 ... ac7bdb6426

Author SHA1 Message Date
  Joachim M. Giæver ac7bdb6426 Remove local resolver 10 months ago
  Joachim M. Giæver 74dcd337a8 Try to exclude the requirements_all to make HA smaller and install deps OD 10 months ago
2 changed files with 4 additions and 7 deletions
  1. 1 1
      snap/plugins/python_wot_plugin.py
  2. 3 6
      snap/snapcraft.yaml

+ 1 - 1
snap/plugins/python_wot_plugin.py

@@ -19,7 +19,7 @@ class PluginImpl(plugins.python.PythonPlugin):
         cmds = super().get_build_commands()
         for idx, cmd in enumerate(cmds):
             if cmd.strip().startswith('pip install -c') and "requirements_all" in cmd:
-                cmds[idx] = f"{cmd.strip()} --use-deprecated=legacy-resolver"
+                cmds[idx] = f"{cmd.strip()}" # --use-deprecated=legacy-resolver"
             elif "[ -f setup.py ]" in cmd:
                 # Use cfg instead of py
                 cmds[idx] = cmd.replace('[ -f setup.py ]', '"${SNAPCRAFT_PYTHON_INTERPRETER}" -m build')

+ 3 - 6
snap/snapcraft.yaml

@@ -235,19 +235,16 @@ parts:
     stage:
       - -lib/python3.11/site-packages/homeassistant/components/updater
       - -lib/python3.11/site-packages/aiogithubapi*
-      - -lib/python3.11/site-packages/icalendar
+      - -lib/python3.11/site-packages/icalendar*
     requirements:
       - requirements.txt
-      - requirements_all.txt
+      #- requirements_all.txt
     constraints:
       - homeassistant/package_constraints.txt
     override-build: |
       CWD="$(pwd)"
-      cd "${SNAPCRAFT_PART_BUILD}"
-      python3 -m script.translations develop --all
-      cd "${CWD}"
+      cd "${SNAPCRAFT_PART_BUILD}" && python3 -m script.translations develop --all && cd "${CWD}"
       snapcraftctl build
-      
     override-stage: |
       snapcraftctl stage
       find $SNAPCRAFT_STAGE/bin -type f -executable -exec sed -i 's/!\/usr\/bin\/env python3.11/!\/usr\/bin\/env python3/' {} \;