diff --git a/.github/workflows/verify.yml b/.github/workflows/verify.yml index 5be2d8114..f93f40beb 100644 --- a/.github/workflows/verify.yml +++ b/.github/workflows/verify.yml @@ -157,6 +157,11 @@ jobs: run: | . venv/bin/activate pre-commit run --show-diff-on-failure --color=always --all-files --hook-stage manual pylint + - name: Biome lint + run: | + . venv/bin/activate + mkdir -p ./tmp && curl -sL "https://github.com/biomejs/biome/releases/latest/download/biome-linux-x64" -o ./tmp/biome && chmod +x ./tmp/biome + pre-commit run --show-diff-on-failure --color=always --all-files --hook-stage manual biome - name: Lint markdown files run: | . venv/bin/activate diff --git a/.gitignore b/.gitignore index b966655c3..ffd6ab944 100644 --- a/.gitignore +++ b/.gitignore @@ -12,8 +12,6 @@ tests/__pycache__ .vscode venv *.sedbck -tmp .mypy_cache -node_modules/ -package-lock.json fixtures/updated/*/ +tmp diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index ea99081ce..5c908a7a0 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,7 +1,7 @@ ci: # Defer autoupdate to quarterly (there is no 'off' button) to have renovate pick up first autoupdate_schedule: quarterly - skip: [pylint, markdownlint, testing] + skip: [setup, setup_test, pylint, markdownlint, testing, biome] submodules: true default_language_version: @@ -67,6 +67,14 @@ repos: # pyenv and/or virtualenv activated; it may not have been e.g. if # committing from a GUI tool that was not launched from an activated # shell. + - id: setup + name: Setup python + entry: /usr/bin/env bash -c 'test -d ./venv || scripts/setup.sh' + language: script + - id: setup_test + name: Setup testing + entry: /usr/bin/env bash -c 'test -f ./tmp/biome || scripts/setup_test.sh pre-commit' + language: script - id: userdata name: userdata entry: scripts/pre-commit.sh @@ -92,12 +100,10 @@ repos: entry: /usr/bin/env bash -c 'exec env GITHUB_ACTIONS="1" scripts/tests_and_coverage.sh test_and_coverage' language: script pass_filenames: false - - repo: https://github.com/biomejs/pre-commit - rev: v0.5.0 - hooks: - - id: biome-lint - additional_dependencies: ["@biomejs/biome@1.8.3"] - name: "Verifying/updating code with biome (improved prettier)" + - id: biome + name: "Local Linting - Biome" + entry: ./tmp/biome lint --staged --files-ignore-unknown=true --no-errors-on-unmatched + language: script - repo: https://github.com/igorshubovych/markdownlint-cli rev: v0.41.0 hooks: diff --git a/CHANGELOG.md b/CHANGELOG.md index 33c814b1c..967f18b15 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,9 @@ # Changelog +## v1.4.1 + +- Prettying documents with Biome (CLI), fixture layout updated accordingly. + ## v1.4.0 - Improve model_id implementation, allow direct access to the gateway `smile_model_id`. diff --git a/fixtures/adam_heatpump_cooling/all_data.json b/fixtures/adam_heatpump_cooling/all_data.json index 60c8472a4..1951cdf67 100644 --- a/fixtures/adam_heatpump_cooling/all_data.json +++ b/fixtures/adam_heatpump_cooling/all_data.json @@ -60,7 +60,13 @@ "model": "Lisa", "model_id": "158-01", "name": "Thermostaat BK", - "preset_modes": ["no_frost", "vacation", "away", "home", "asleep"], + "preset_modes": [ + "no_frost", + "vacation", + "away", + "home", + "asleep" + ], "select_schedule": "off", "sensors": { "battery": 55, @@ -180,7 +186,13 @@ "model": "Lisa", "model_id": "158-01", "name": "Thermostaat DB", - "preset_modes": ["no_frost", "vacation", "away", "home", "asleep"], + "preset_modes": [ + "no_frost", + "vacation", + "away", + "home", + "asleep" + ], "select_schedule": "off", "sensors": { "setpoint": 18.0, @@ -227,7 +239,11 @@ }, "dev_class": "gateway", "firmware": "3.2.8", - "gateway_modes": ["away", "full", "vacation"], + "gateway_modes": [ + "away", + "full", + "vacation" + ], "hardware": "AME Smile 2.0 board", "location": "eedadcb297564f1483faa509179aebed", "mac_address": "012345670001", @@ -267,7 +283,13 @@ "model": "Lisa", "model_id": "158-01", "name": "Thermostaat JM", - "preset_modes": ["no_frost", "vacation", "away", "home", "asleep"], + "preset_modes": [ + "no_frost", + "vacation", + "away", + "home", + "asleep" + ], "select_schedule": "off", "sensors": { "setpoint": 18.0, @@ -406,7 +428,13 @@ "model": "Lisa", "model_id": "158-01", "name": "Thermostaat SQ", - "preset_modes": ["no_frost", "vacation", "away", "home", "asleep"], + "preset_modes": [ + "no_frost", + "vacation", + "away", + "home", + "asleep" + ], "select_schedule": "off", "sensors": { "setpoint": 18.5, @@ -445,7 +473,13 @@ "model": "Lisa", "model_id": "158-01", "name": "Thermostaat RB", - "preset_modes": ["no_frost", "vacation", "away", "home", "asleep"], + "preset_modes": [ + "no_frost", + "vacation", + "away", + "home", + "asleep" + ], "select_schedule": "off", "sensors": { "setpoint": 17.0, @@ -481,7 +515,13 @@ "model": "ThermoTouch", "model_id": "143.1", "name": "Thermostaat WK", - "preset_modes": ["no_frost", "vacation", "away", "home", "asleep"], + "preset_modes": [ + "no_frost", + "vacation", + "away", + "home", + "asleep" + ], "select_schedule": "Werkdag schema", "sensors": { "setpoint": 21.5, @@ -513,7 +553,13 @@ "model": "Lisa", "model_id": "158-01", "name": "Thermostaat SJ", - "preset_modes": ["no_frost", "vacation", "away", "home", "asleep"], + "preset_modes": [ + "no_frost", + "vacation", + "away", + "home", + "asleep" + ], "select_schedule": "off", "sensors": { "setpoint": 20.5, @@ -555,7 +601,13 @@ "model": "Lisa", "model_id": "158-01", "name": "Thermostaat KK", - "preset_modes": ["no_frost", "vacation", "away", "home", "asleep"], + "preset_modes": [ + "no_frost", + "vacation", + "away", + "home", + "asleep" + ], "select_schedule": "Werkdag schema", "sensors": { "battery": 53, @@ -595,7 +647,13 @@ "model": "Lisa", "model_id": "158-01", "name": "Thermostaat BK1", - "preset_modes": ["no_frost", "vacation", "away", "home", "asleep"], + "preset_modes": [ + "no_frost", + "vacation", + "away", + "home", + "asleep" + ], "select_schedule": "Werkdag schema", "sensors": { "setpoint": 20.5, @@ -634,7 +692,13 @@ "model": "Lisa", "model_id": "158-01", "name": "Thermostaat BK2", - "preset_modes": ["no_frost", "vacation", "away", "home", "asleep"], + "preset_modes": [ + "no_frost", + "vacation", + "away", + "home", + "asleep" + ], "select_schedule": "Werkdag schema", "sensors": { "setpoint": 20.5, diff --git a/fixtures/adam_jip/all_data.json b/fixtures/adam_jip/all_data.json index bb0f73481..c3f0efa87 100644 --- a/fixtures/adam_jip/all_data.json +++ b/fixtures/adam_jip/all_data.json @@ -15,7 +15,13 @@ "model": "Lisa", "model_id": "158-01", "name": "Slaapkamer", - "preset_modes": ["home", "asleep", "away", "vacation", "no_frost"], + "preset_modes": [ + "home", + "asleep", + "away", + "vacation", + "no_frost" + ], "sensors": { "battery": 92, "setpoint": 13.0, @@ -116,7 +122,13 @@ "model": "Lisa", "model_id": "158-01", "name": "Kinderkamer", - "preset_modes": ["home", "asleep", "away", "vacation", "no_frost"], + "preset_modes": [ + "home", + "asleep", + "away", + "vacation", + "no_frost" + ], "sensors": { "battery": 79, "setpoint": 13.0, @@ -176,7 +188,13 @@ "model": "Lisa", "model_id": "158-01", "name": "Logeerkamer", - "preset_modes": ["home", "asleep", "away", "vacation", "no_frost"], + "preset_modes": [ + "home", + "asleep", + "away", + "vacation", + "no_frost" + ], "sensors": { "battery": 80, "setpoint": 13.0, @@ -203,14 +221,23 @@ }, "dev_class": "gateway", "firmware": "3.2.8", - "gateway_modes": ["away", "full", "vacation"], + "gateway_modes": [ + "away", + "full", + "vacation" + ], "hardware": "AME Smile 2.0 board", "location": "9e4433a9d69f40b3aefd15e74395eaec", "mac_address": "012345670001", "model": "Gateway", "model_id": "smile_open_therm", "name": "Adam", - "regulation_modes": ["heating", "off", "bleeding_cold", "bleeding_hot"], + "regulation_modes": [ + "heating", + "off", + "bleeding_cold", + "bleeding_hot" + ], "select_gateway_mode": "full", "select_regulation_mode": "heating", "sensors": { @@ -294,7 +321,13 @@ "model": "Jip", "model_id": "168-01", "name": "Woonkamer", - "preset_modes": ["home", "asleep", "away", "vacation", "no_frost"], + "preset_modes": [ + "home", + "asleep", + "away", + "vacation", + "no_frost" + ], "sensors": { "battery": 100, "humidity": 56.2, diff --git a/fixtures/adam_multiple_devices_per_zone/all_data.json b/fixtures/adam_multiple_devices_per_zone/all_data.json index 374c75ee3..a5459f9e3 100644 --- a/fixtures/adam_multiple_devices_per_zone/all_data.json +++ b/fixtures/adam_multiple_devices_per_zone/all_data.json @@ -134,7 +134,13 @@ "model": "Lisa", "model_id": "158-01", "name": "Zone Thermostat Jessie", - "preset_modes": ["home", "asleep", "away", "vacation", "no_frost"], + "preset_modes": [ + "home", + "asleep", + "away", + "vacation", + "no_frost" + ], "select_schedule": "CV Jessie", "sensors": { "battery": 37, @@ -285,7 +291,13 @@ "model": "Lisa", "model_id": "158-01", "name": "Zone Lisa WK", - "preset_modes": ["home", "asleep", "away", "vacation", "no_frost"], + "preset_modes": [ + "home", + "asleep", + "away", + "vacation", + "no_frost" + ], "select_schedule": "GF7 Woonkamer", "sensors": { "battery": 34, @@ -378,7 +390,13 @@ "model": "Lisa", "model_id": "158-01", "name": "Zone Lisa Bios", - "preset_modes": ["home", "asleep", "away", "vacation", "no_frost"], + "preset_modes": [ + "home", + "asleep", + "away", + "vacation", + "no_frost" + ], "select_schedule": "off", "sensors": { "battery": 67, @@ -422,7 +440,13 @@ "model": "Tom/Floor", "model_id": "106-03", "name": "CV Kraan Garage", - "preset_modes": ["home", "asleep", "away", "vacation", "no_frost"], + "preset_modes": [ + "home", + "asleep", + "away", + "vacation", + "no_frost" + ], "select_schedule": "off", "sensors": { "battery": 68, @@ -468,7 +492,13 @@ "model": "Lisa", "model_id": "158-01", "name": "Zone Thermostat Badkamer", - "preset_modes": ["home", "asleep", "away", "vacation", "no_frost"], + "preset_modes": [ + "home", + "asleep", + "away", + "vacation", + "no_frost" + ], "select_schedule": "Badkamer Schema", "sensors": { "battery": 92, diff --git a/fixtures/adam_onoff_cooling_fake_firmware/all_data.json b/fixtures/adam_onoff_cooling_fake_firmware/all_data.json index c9893ceee..dff86bd92 100644 --- a/fixtures/adam_onoff_cooling_fake_firmware/all_data.json +++ b/fixtures/adam_onoff_cooling_fake_firmware/all_data.json @@ -42,7 +42,11 @@ }, "dev_class": "gateway", "firmware": "3.2.8", - "gateway_modes": ["away", "full", "vacation"], + "gateway_modes": [ + "away", + "full", + "vacation" + ], "hardware": "AME Smile 2.0 board", "location": "eedadcb297564f1483faa509179aebed", "mac_address": "012345670001", @@ -79,7 +83,13 @@ "model": "ThermoTouch", "model_id": "143.1", "name": "Thermostaat WK", - "preset_modes": ["no_frost", "vacation", "away", "home", "asleep"], + "preset_modes": [ + "no_frost", + "vacation", + "away", + "home", + "asleep" + ], "select_schedule": "Werkdag schema", "sensors": { "setpoint": 21.5, diff --git a/fixtures/adam_plus_anna/all_data.json b/fixtures/adam_plus_anna/all_data.json index 3af34a6a3..419c766ea 100644 --- a/fixtures/adam_plus_anna/all_data.json +++ b/fixtures/adam_plus_anna/all_data.json @@ -67,14 +67,23 @@ }, "ee62cad889f94e8ca3d09021f03a660b": { "active_preset": "home", - "available_schedules": ["Weekschema", "off"], + "available_schedules": [ + "Weekschema", + "off" + ], "dev_class": "thermostat", "location": "009490cc2f674ce6b576863fbb64f867", "mode": "auto", "model": "ThermoTouch", "model_id": "143.1", "name": "Anna", - "preset_modes": ["home", "asleep", "away", "vacation", "no_frost"], + "preset_modes": [ + "home", + "asleep", + "away", + "vacation", + "no_frost" + ], "select_schedule": "Weekschema", "sensors": { "setpoint": 20.5, diff --git a/fixtures/adam_plus_anna_new/all_data.json b/fixtures/adam_plus_anna_new/all_data.json index 52a6cbcc4..b99105ba3 100644 --- a/fixtures/adam_plus_anna_new/all_data.json +++ b/fixtures/adam_plus_anna_new/all_data.json @@ -148,7 +148,13 @@ "model": "ThermoTouch", "model_id": "143.1", "name": "Anna", - "preset_modes": ["no_frost", "asleep", "vacation", "home", "away"], + "preset_modes": [ + "no_frost", + "asleep", + "vacation", + "home", + "away" + ], "select_schedule": "Weekschema", "sensors": { "setpoint": 18.5, @@ -168,14 +174,23 @@ }, "dev_class": "gateway", "firmware": "3.7.8", - "gateway_modes": ["away", "full", "vacation"], + "gateway_modes": [ + "away", + "full", + "vacation" + ], "hardware": "AME Smile 2.0 board", "location": "bc93488efab249e5bc54fd7e175a6f91", "mac_address": "012345679891", "model": "Gateway", "model_id": "smile_open_therm", "name": "Adam", - "regulation_modes": ["bleeding_hot", "bleeding_cold", "off", "heating"], + "regulation_modes": [ + "bleeding_hot", + "bleeding_cold", + "off", + "heating" + ], "select_gateway_mode": "full", "select_regulation_mode": "heating", "sensors": { @@ -206,7 +221,13 @@ "model": "Lisa", "model_id": "158-01", "name": "Lisa Badkamer", - "preset_modes": ["no_frost", "asleep", "vacation", "home", "away"], + "preset_modes": [ + "no_frost", + "asleep", + "vacation", + "home", + "away" + ], "select_schedule": "Badkamer", "sensors": { "battery": 14, diff --git a/fixtures/adam_zone_per_device/all_data.json b/fixtures/adam_zone_per_device/all_data.json index a886aabc5..1a9c2de4a 100644 --- a/fixtures/adam_zone_per_device/all_data.json +++ b/fixtures/adam_zone_per_device/all_data.json @@ -134,7 +134,13 @@ "model": "Lisa", "model_id": "158-01", "name": "Zone Thermostat Jessie", - "preset_modes": ["home", "asleep", "away", "vacation", "no_frost"], + "preset_modes": [ + "home", + "asleep", + "away", + "vacation", + "no_frost" + ], "select_schedule": "CV Jessie", "sensors": { "battery": 37, @@ -285,7 +291,13 @@ "model": "Lisa", "model_id": "158-01", "name": "Zone Lisa WK", - "preset_modes": ["home", "asleep", "away", "vacation", "no_frost"], + "preset_modes": [ + "home", + "asleep", + "away", + "vacation", + "no_frost" + ], "select_schedule": "GF7 Woonkamer", "sensors": { "battery": 34, @@ -378,7 +390,13 @@ "model": "Lisa", "model_id": "158-01", "name": "Zone Lisa Bios", - "preset_modes": ["home", "asleep", "away", "vacation", "no_frost"], + "preset_modes": [ + "home", + "asleep", + "away", + "vacation", + "no_frost" + ], "select_schedule": "off", "sensors": { "battery": 67, @@ -422,7 +440,13 @@ "model": "Tom/Floor", "model_id": "106-03", "name": "CV Kraan Garage", - "preset_modes": ["home", "asleep", "away", "vacation", "no_frost"], + "preset_modes": [ + "home", + "asleep", + "away", + "vacation", + "no_frost" + ], "select_schedule": "off", "sensors": { "battery": 68, @@ -468,7 +492,13 @@ "model": "Lisa", "model_id": "158-01", "name": "Zone Thermostat Badkamer", - "preset_modes": ["home", "asleep", "away", "vacation", "no_frost"], + "preset_modes": [ + "home", + "asleep", + "away", + "vacation", + "no_frost" + ], "select_schedule": "Badkamer Schema", "sensors": { "battery": 92, diff --git a/fixtures/anna_elga_2/all_data.json b/fixtures/anna_elga_2/all_data.json index b19e9288d..cd386586d 100644 --- a/fixtures/anna_elga_2/all_data.json +++ b/fixtures/anna_elga_2/all_data.json @@ -37,7 +37,10 @@ }, "ebd90df1ab334565b5895f37590ccff4": { "active_preset": "home", - "available_schedules": ["Thermostat schedule", "off"], + "available_schedules": [ + "Thermostat schedule", + "off" + ], "dev_class": "thermostat", "firmware": "2018-02-08T11:15:53+01:00", "hardware": "6539-1301-5002", @@ -45,7 +48,13 @@ "mode": "auto", "model": "ThermoTouch", "name": "Anna", - "preset_modes": ["away", "no_frost", "vacation", "home", "asleep"], + "preset_modes": [ + "away", + "no_frost", + "vacation", + "home", + "asleep" + ], "select_schedule": "Thermostat schedule", "sensors": { "cooling_activation_outdoor_temperature": 26.0, diff --git a/fixtures/anna_elga_2_cooling/all_data.json b/fixtures/anna_elga_2_cooling/all_data.json index 3228601b2..95ccaab60 100644 --- a/fixtures/anna_elga_2_cooling/all_data.json +++ b/fixtures/anna_elga_2_cooling/all_data.json @@ -37,7 +37,10 @@ }, "ebd90df1ab334565b5895f37590ccff4": { "active_preset": "home", - "available_schedules": ["Thermostat schedule", "off"], + "available_schedules": [ + "Thermostat schedule", + "off" + ], "dev_class": "thermostat", "firmware": "2018-02-08T11:15:53+01:00", "hardware": "6539-1301-5002", @@ -45,7 +48,13 @@ "mode": "auto", "model": "ThermoTouch", "name": "Anna", - "preset_modes": ["away", "no_frost", "vacation", "home", "asleep"], + "preset_modes": [ + "away", + "no_frost", + "vacation", + "home", + "asleep" + ], "select_schedule": "Thermostat schedule", "sensors": { "cooling_activation_outdoor_temperature": 26.0, diff --git a/fixtures/anna_elga_2_schedule_off/all_data.json b/fixtures/anna_elga_2_schedule_off/all_data.json index 2dbb46934..a528c79b6 100644 --- a/fixtures/anna_elga_2_schedule_off/all_data.json +++ b/fixtures/anna_elga_2_schedule_off/all_data.json @@ -37,7 +37,10 @@ }, "ebd90df1ab334565b5895f37590ccff4": { "active_preset": "home", - "available_schedules": ["Thermostat schedule", "off"], + "available_schedules": [ + "Thermostat schedule", + "off" + ], "dev_class": "thermostat", "firmware": "2018-02-08T11:15:53+01:00", "hardware": "6539-1301-5002", @@ -45,7 +48,13 @@ "mode": "heat_cool", "model": "ThermoTouch", "name": "Anna", - "preset_modes": ["away", "no_frost", "vacation", "home", "asleep"], + "preset_modes": [ + "away", + "no_frost", + "vacation", + "home", + "asleep" + ], "select_schedule": "off", "sensors": { "cooling_activation_outdoor_temperature": 26.0, diff --git a/fixtures/anna_elga_no_cooling/all_data.json b/fixtures/anna_elga_no_cooling/all_data.json index f54334c2a..34e6c6135 100644 --- a/fixtures/anna_elga_no_cooling/all_data.json +++ b/fixtures/anna_elga_no_cooling/all_data.json @@ -58,7 +58,10 @@ }, "3cb70739631c4d17a86b8b12e8a5161b": { "active_preset": "home", - "available_schedules": ["standaard", "off"], + "available_schedules": [ + "standaard", + "off" + ], "dev_class": "thermostat", "firmware": "2018-02-08T11:15:53+01:00", "hardware": "6539-1301-5002", @@ -66,7 +69,13 @@ "mode": "auto", "model": "ThermoTouch", "name": "Anna", - "preset_modes": ["no_frost", "home", "away", "asleep", "vacation"], + "preset_modes": [ + "no_frost", + "home", + "away", + "asleep", + "vacation" + ], "select_schedule": "standaard", "sensors": { "cooling_activation_outdoor_temperature": 21.0, diff --git a/fixtures/anna_heatpump_cooling/all_data.json b/fixtures/anna_heatpump_cooling/all_data.json index 92c138769..59c8ecbf3 100644 --- a/fixtures/anna_heatpump_cooling/all_data.json +++ b/fixtures/anna_heatpump_cooling/all_data.json @@ -55,7 +55,10 @@ }, "3cb70739631c4d17a86b8b12e8a5161b": { "active_preset": "home", - "available_schedules": ["standaard", "off"], + "available_schedules": [ + "standaard", + "off" + ], "dev_class": "thermostat", "firmware": "2018-02-08T11:15:53+01:00", "hardware": "6539-1301-5002", @@ -63,7 +66,13 @@ "mode": "heat_cool", "model": "ThermoTouch", "name": "Anna", - "preset_modes": ["no_frost", "home", "away", "asleep", "vacation"], + "preset_modes": [ + "no_frost", + "home", + "away", + "asleep", + "vacation" + ], "select_schedule": "off", "sensors": { "cooling_activation_outdoor_temperature": 21.0, diff --git a/fixtures/anna_heatpump_cooling_fake_firmware/all_data.json b/fixtures/anna_heatpump_cooling_fake_firmware/all_data.json index cfaedcb10..0cd7aa012 100644 --- a/fixtures/anna_heatpump_cooling_fake_firmware/all_data.json +++ b/fixtures/anna_heatpump_cooling_fake_firmware/all_data.json @@ -55,7 +55,10 @@ }, "3cb70739631c4d17a86b8b12e8a5161b": { "active_preset": "home", - "available_schedules": ["standaard", "off"], + "available_schedules": [ + "standaard", + "off" + ], "dev_class": "thermostat", "firmware": "2018-02-08T11:15:53+01:00", "hardware": "6539-1301-5002", @@ -63,7 +66,13 @@ "mode": "heat_cool", "model": "ThermoTouch", "name": "Anna", - "preset_modes": ["no_frost", "home", "away", "asleep", "vacation"], + "preset_modes": [ + "no_frost", + "home", + "away", + "asleep", + "vacation" + ], "select_schedule": "off", "sensors": { "cooling_activation_outdoor_temperature": 21.0, diff --git a/fixtures/anna_heatpump_heating/all_data.json b/fixtures/anna_heatpump_heating/all_data.json index b767f5531..b324a99e7 100644 --- a/fixtures/anna_heatpump_heating/all_data.json +++ b/fixtures/anna_heatpump_heating/all_data.json @@ -60,7 +60,10 @@ }, "3cb70739631c4d17a86b8b12e8a5161b": { "active_preset": "home", - "available_schedules": ["standaard", "off"], + "available_schedules": [ + "standaard", + "off" + ], "dev_class": "thermostat", "firmware": "2018-02-08T11:15:53+01:00", "hardware": "6539-1301-5002", @@ -68,7 +71,13 @@ "mode": "auto", "model": "ThermoTouch", "name": "Anna", - "preset_modes": ["no_frost", "home", "away", "asleep", "vacation"], + "preset_modes": [ + "no_frost", + "home", + "away", + "asleep", + "vacation" + ], "select_schedule": "standaard", "sensors": { "cooling_activation_outdoor_temperature": 21.0, diff --git a/fixtures/anna_loria_cooling_active/all_data.json b/fixtures/anna_loria_cooling_active/all_data.json index 24fc4f679..24f0e68d1 100644 --- a/fixtures/anna_loria_cooling_active/all_data.json +++ b/fixtures/anna_loria_cooling_active/all_data.json @@ -2,7 +2,11 @@ "devices": { "582dfbdace4d4aeb832923ce7d1ddda0": { "active_preset": "home", - "available_schedules": ["Winter", "Test ", "off"], + "available_schedules": [ + "Winter", + "Test ", + "off" + ], "dev_class": "thermostat", "firmware": "2018-02-08T11:15:53+01:00", "hardware": "6539-1301-5002", @@ -10,7 +14,13 @@ "mode": "auto", "model": "ThermoTouch", "name": "Anna", - "preset_modes": ["away", "vacation", "no_frost", "home", "asleep"], + "preset_modes": [ + "away", + "vacation", + "no_frost", + "home", + "asleep" + ], "select_schedule": "Winter", "sensors": { "illuminance": 45.0, @@ -60,7 +70,13 @@ "heating_state": false }, "dev_class": "heater_central", - "dhw_modes": ["off", "auto", "boost", "eco", "comfort"], + "dhw_modes": [ + "off", + "auto", + "boost", + "eco", + "comfort" + ], "location": "674b657c138a41a291d315d7471deb06", "max_dhw_temperature": { "lower_bound": 35.0, diff --git a/fixtures/anna_loria_driessens/all_data.json b/fixtures/anna_loria_driessens/all_data.json index c07381ac0..cf43d4374 100644 --- a/fixtures/anna_loria_driessens/all_data.json +++ b/fixtures/anna_loria_driessens/all_data.json @@ -33,7 +33,13 @@ "mode": "auto", "model": "ThermoTouch", "name": "Anna", - "preset_modes": ["no_frost", "asleep", "vacation", "away", "home"], + "preset_modes": [ + "no_frost", + "asleep", + "vacation", + "away", + "home" + ], "select_schedule": "Verwarmen@9-23u", "sensors": { "illuminance": 5.5, @@ -66,7 +72,13 @@ "heating_state": false }, "dev_class": "heater_central", - "dhw_modes": ["comfort", "eco", "off", "boost", "auto"], + "dhw_modes": [ + "comfort", + "eco", + "off", + "boost", + "auto" + ], "location": "82c15f65c9bf44c592d69e16139355e3", "max_dhw_temperature": { "lower_bound": 35.0, diff --git a/fixtures/anna_loria_heating_idle/all_data.json b/fixtures/anna_loria_heating_idle/all_data.json index 9e553d33c..37cbe5ccc 100644 --- a/fixtures/anna_loria_heating_idle/all_data.json +++ b/fixtures/anna_loria_heating_idle/all_data.json @@ -2,7 +2,11 @@ "devices": { "582dfbdace4d4aeb832923ce7d1ddda0": { "active_preset": "home", - "available_schedules": ["Winter", "Test ", "off"], + "available_schedules": [ + "Winter", + "Test ", + "off" + ], "dev_class": "thermostat", "firmware": "2018-02-08T11:15:53+01:00", "hardware": "6539-1301-5002", @@ -10,7 +14,13 @@ "mode": "auto", "model": "ThermoTouch", "name": "Anna", - "preset_modes": ["away", "vacation", "no_frost", "home", "asleep"], + "preset_modes": [ + "away", + "vacation", + "no_frost", + "home", + "asleep" + ], "select_schedule": "Winter", "sensors": { "illuminance": 45.0, @@ -60,7 +70,13 @@ "heating_state": false }, "dev_class": "heater_central", - "dhw_modes": ["off", "auto", "boost", "eco", "comfort"], + "dhw_modes": [ + "off", + "auto", + "boost", + "eco", + "comfort" + ], "location": "674b657c138a41a291d315d7471deb06", "max_dhw_temperature": { "lower_bound": 35.0, diff --git a/fixtures/anna_v4/all_data.json b/fixtures/anna_v4/all_data.json index 3e379bc3d..e8b7ccd04 100644 --- a/fixtures/anna_v4/all_data.json +++ b/fixtures/anna_v4/all_data.json @@ -2,7 +2,11 @@ "devices": { "01b85360fdd243d0aaad4d6ac2a5ba7e": { "active_preset": "home", - "available_schedules": ["Standaard", "Thuiswerken", "off"], + "available_schedules": [ + "Standaard", + "Thuiswerken", + "off" + ], "dev_class": "thermostat", "firmware": "2018-02-08T11:15:53+01:00", "hardware": "6539-1301-5002", @@ -10,7 +14,13 @@ "mode": "heat", "model": "ThermoTouch", "name": "Anna", - "preset_modes": ["vacation", "no_frost", "away", "asleep", "home"], + "preset_modes": [ + "vacation", + "no_frost", + "away", + "asleep", + "home" + ], "select_schedule": "off", "sensors": { "illuminance": 60.0, diff --git a/fixtures/anna_v4_dhw/all_data.json b/fixtures/anna_v4_dhw/all_data.json index 3df9ad3d4..8713a66fa 100644 --- a/fixtures/anna_v4_dhw/all_data.json +++ b/fixtures/anna_v4_dhw/all_data.json @@ -2,7 +2,11 @@ "devices": { "01b85360fdd243d0aaad4d6ac2a5ba7e": { "active_preset": "home", - "available_schedules": ["Standaard", "Thuiswerken", "off"], + "available_schedules": [ + "Standaard", + "Thuiswerken", + "off" + ], "dev_class": "thermostat", "firmware": "2018-02-08T11:15:53+01:00", "hardware": "6539-1301-5002", @@ -10,7 +14,13 @@ "mode": "heat", "model": "ThermoTouch", "name": "Anna", - "preset_modes": ["vacation", "no_frost", "away", "asleep", "home"], + "preset_modes": [ + "vacation", + "no_frost", + "away", + "asleep", + "home" + ], "select_schedule": "off", "sensors": { "illuminance": 60.0, diff --git a/fixtures/anna_v4_no_tag/all_data.json b/fixtures/anna_v4_no_tag/all_data.json index 43e725209..242b48c4c 100644 --- a/fixtures/anna_v4_no_tag/all_data.json +++ b/fixtures/anna_v4_no_tag/all_data.json @@ -2,7 +2,11 @@ "devices": { "01b85360fdd243d0aaad4d6ac2a5ba7e": { "active_preset": "home", - "available_schedules": ["Standaard", "Thuiswerken", "off"], + "available_schedules": [ + "Standaard", + "Thuiswerken", + "off" + ], "dev_class": "thermostat", "firmware": "2018-02-08T11:15:53+01:00", "hardware": "6539-1301-5002", @@ -10,7 +14,13 @@ "mode": "auto", "model": "ThermoTouch", "name": "Anna", - "preset_modes": ["vacation", "no_frost", "away", "asleep", "home"], + "preset_modes": [ + "vacation", + "no_frost", + "away", + "asleep", + "home" + ], "select_schedule": "Thuiswerken", "sensors": { "illuminance": 60.0, diff --git a/fixtures/anna_without_boiler_fw441/all_data.json b/fixtures/anna_without_boiler_fw441/all_data.json index 639907a67..0317bb6c1 100644 --- a/fixtures/anna_without_boiler_fw441/all_data.json +++ b/fixtures/anna_without_boiler_fw441/all_data.json @@ -2,7 +2,11 @@ "devices": { "7ffbb3ab4b6c4ab2915d7510f7bf8fe9": { "active_preset": "home", - "available_schedules": ["Test", "Normaal", "off"], + "available_schedules": [ + "Test", + "Normaal", + "off" + ], "dev_class": "thermostat", "firmware": "2018-02-08T11:15:53+01:00", "hardware": "6539-1301-5002", @@ -10,7 +14,13 @@ "mode": "auto", "model": "ThermoTouch", "name": "Anna", - "preset_modes": ["no_frost", "asleep", "away", "vacation", "home"], + "preset_modes": [ + "no_frost", + "asleep", + "away", + "vacation", + "home" + ], "select_schedule": "Normaal", "sensors": { "illuminance": 0.25, diff --git a/fixtures/legacy_anna/all_data.json b/fixtures/legacy_anna/all_data.json index 1eca4e285..71452119e 100644 --- a/fixtures/legacy_anna/all_data.json +++ b/fixtures/legacy_anna/all_data.json @@ -43,7 +43,13 @@ "mode": "heat", "model": "ThermoTouch", "name": "Anna", - "preset_modes": ["away", "vacation", "asleep", "home", "no_frost"], + "preset_modes": [ + "away", + "vacation", + "asleep", + "home", + "no_frost" + ], "sensors": { "illuminance": 151, "setpoint": 20.5, diff --git a/fixtures/legacy_anna_2/all_data.json b/fixtures/legacy_anna_2/all_data.json index 9e7443924..bd708efd2 100644 --- a/fixtures/legacy_anna_2/all_data.json +++ b/fixtures/legacy_anna_2/all_data.json @@ -2,7 +2,10 @@ "devices": { "9e7377867dc24e51b8098a5ba02bd89d": { "active_preset": null, - "available_schedules": ["Thermostat schedule", "off"], + "available_schedules": [ + "Thermostat schedule", + "off" + ], "dev_class": "thermostat", "firmware": "2017-03-13T11:54:58+01:00", "hardware": "6539-1301-5002", @@ -10,7 +13,13 @@ "mode": "heat", "model": "ThermoTouch", "name": "Anna", - "preset_modes": ["vacation", "away", "no_frost", "home", "asleep"], + "preset_modes": [ + "vacation", + "away", + "no_frost", + "home", + "asleep" + ], "select_schedule": "off", "sensors": { "illuminance": 19.5, diff --git a/fixtures/m_adam_cooling/all_data.json b/fixtures/m_adam_cooling/all_data.json index 166b13b84..1a829d236 100644 --- a/fixtures/m_adam_cooling/all_data.json +++ b/fixtures/m_adam_cooling/all_data.json @@ -70,7 +70,13 @@ "model": "ThermoTouch", "model_id": "143.1", "name": "Anna", - "preset_modes": ["no_frost", "asleep", "vacation", "home", "away"], + "preset_modes": [ + "no_frost", + "asleep", + "vacation", + "home", + "away" + ], "select_schedule": "off", "sensors": { "setpoint": 23.5, @@ -90,7 +96,11 @@ }, "dev_class": "gateway", "firmware": "3.7.8", - "gateway_modes": ["away", "full", "vacation"], + "gateway_modes": [ + "away", + "full", + "vacation" + ], "hardware": "AME Smile 2.0 board", "location": "bc93488efab249e5bc54fd7e175a6f91", "mac_address": "012345679891", @@ -134,7 +144,13 @@ "model": "Lisa", "model_id": "158-01", "name": "Lisa Badkamer", - "preset_modes": ["no_frost", "asleep", "vacation", "home", "away"], + "preset_modes": [ + "no_frost", + "asleep", + "vacation", + "home", + "away" + ], "select_schedule": "Badkamer", "sensors": { "battery": 14, diff --git a/fixtures/m_adam_heating/all_data.json b/fixtures/m_adam_heating/all_data.json index 61935f130..066661217 100644 --- a/fixtures/m_adam_heating/all_data.json +++ b/fixtures/m_adam_heating/all_data.json @@ -75,7 +75,13 @@ "model": "ThermoTouch", "model_id": "143.1", "name": "Anna", - "preset_modes": ["no_frost", "asleep", "vacation", "home", "away"], + "preset_modes": [ + "no_frost", + "asleep", + "vacation", + "home", + "away" + ], "select_schedule": "off", "sensors": { "setpoint": 20.0, @@ -95,14 +101,23 @@ }, "dev_class": "gateway", "firmware": "3.7.8", - "gateway_modes": ["away", "full", "vacation"], + "gateway_modes": [ + "away", + "full", + "vacation" + ], "hardware": "AME Smile 2.0 board", "location": "bc93488efab249e5bc54fd7e175a6f91", "mac_address": "012345679891", "model": "Gateway", "model_id": "smile_open_therm", "name": "Adam", - "regulation_modes": ["bleeding_hot", "bleeding_cold", "off", "heating"], + "regulation_modes": [ + "bleeding_hot", + "bleeding_cold", + "off", + "heating" + ], "select_gateway_mode": "full", "select_regulation_mode": "heating", "sensors": { @@ -133,7 +148,13 @@ "model": "Lisa", "model_id": "158-01", "name": "Lisa Badkamer", - "preset_modes": ["no_frost", "asleep", "vacation", "home", "away"], + "preset_modes": [ + "no_frost", + "asleep", + "vacation", + "home", + "away" + ], "select_schedule": "Badkamer", "sensors": { "battery": 14, diff --git a/fixtures/m_adam_jip/all_data.json b/fixtures/m_adam_jip/all_data.json index 50c3fa5a7..e65992e52 100644 --- a/fixtures/m_adam_jip/all_data.json +++ b/fixtures/m_adam_jip/all_data.json @@ -15,7 +15,13 @@ "model": "Lisa", "model_id": "158-01", "name": "Slaapkamer", - "preset_modes": ["home", "asleep", "away", "vacation", "no_frost"], + "preset_modes": [ + "home", + "asleep", + "away", + "vacation", + "no_frost" + ], "sensors": { "battery": 92, "setpoint": 13.0, @@ -116,7 +122,13 @@ "model": "Lisa", "model_id": "158-01", "name": "Kinderkamer", - "preset_modes": ["home", "asleep", "away", "vacation", "no_frost"], + "preset_modes": [ + "home", + "asleep", + "away", + "vacation", + "no_frost" + ], "sensors": { "battery": 79, "setpoint": 13.0, @@ -176,7 +188,13 @@ "model": "Lisa", "model_id": "158-01", "name": "Logeerkamer", - "preset_modes": ["home", "asleep", "away", "vacation", "no_frost"], + "preset_modes": [ + "home", + "asleep", + "away", + "vacation", + "no_frost" + ], "sensors": { "battery": 80, "setpoint": 13.0, @@ -203,14 +221,23 @@ }, "dev_class": "gateway", "firmware": "3.2.8", - "gateway_modes": ["away", "full", "vacation"], + "gateway_modes": [ + "away", + "full", + "vacation" + ], "hardware": "AME Smile 2.0 board", "location": "9e4433a9d69f40b3aefd15e74395eaec", "mac_address": "012345670001", "model": "Gateway", "model_id": "smile_open_therm", "name": "Adam", - "regulation_modes": ["heating", "off", "bleeding_cold", "bleeding_hot"], + "regulation_modes": [ + "heating", + "off", + "bleeding_cold", + "bleeding_hot" + ], "select_gateway_mode": "full", "select_regulation_mode": "heating", "sensors": { @@ -294,7 +321,13 @@ "model": "Jip", "model_id": "168-01", "name": "Woonkamer", - "preset_modes": ["home", "asleep", "away", "vacation", "no_frost"], + "preset_modes": [ + "home", + "asleep", + "away", + "vacation", + "no_frost" + ], "sensors": { "battery": 100, "humidity": 56.2, diff --git a/fixtures/m_adam_multiple_devices_per_zone/all_data.json b/fixtures/m_adam_multiple_devices_per_zone/all_data.json index 7a61bf106..816fa5c1d 100644 --- a/fixtures/m_adam_multiple_devices_per_zone/all_data.json +++ b/fixtures/m_adam_multiple_devices_per_zone/all_data.json @@ -134,7 +134,13 @@ "model": "Lisa", "model_id": "158-01", "name": "Zone Thermostat Jessie", - "preset_modes": ["home", "asleep", "away", "vacation", "no_frost"], + "preset_modes": [ + "home", + "asleep", + "away", + "vacation", + "no_frost" + ], "select_schedule": "CV Jessie", "sensors": { "battery": 37, @@ -285,7 +291,13 @@ "model": "Lisa", "model_id": "158-01", "name": "Zone Lisa WK", - "preset_modes": ["home", "asleep", "away", "vacation", "no_frost"], + "preset_modes": [ + "home", + "asleep", + "away", + "vacation", + "no_frost" + ], "select_schedule": "GF7 Woonkamer", "sensors": { "battery": 34, @@ -378,7 +390,13 @@ "model": "Lisa", "model_id": "158-01", "name": "Zone Lisa Bios", - "preset_modes": ["home", "asleep", "away", "vacation", "no_frost"], + "preset_modes": [ + "home", + "asleep", + "away", + "vacation", + "no_frost" + ], "select_schedule": "off", "sensors": { "battery": 67, @@ -414,7 +432,13 @@ "model": "Tom/Floor", "model_id": "106-03", "name": "CV Kraan Garage", - "preset_modes": ["home", "asleep", "away", "vacation", "no_frost"], + "preset_modes": [ + "home", + "asleep", + "away", + "vacation", + "no_frost" + ], "sensors": { "battery": 68, "setpoint": 5.5, @@ -459,7 +483,13 @@ "model": "Lisa", "model_id": "158-01", "name": "Zone Thermostat Badkamer", - "preset_modes": ["home", "asleep", "away", "vacation", "no_frost"], + "preset_modes": [ + "home", + "asleep", + "away", + "vacation", + "no_frost" + ], "select_schedule": "Badkamer Schema", "sensors": { "battery": 92, diff --git a/fixtures/m_anna_heatpump_cooling/all_data.json b/fixtures/m_anna_heatpump_cooling/all_data.json index 05f5e0ffa..455190f90 100644 --- a/fixtures/m_anna_heatpump_cooling/all_data.json +++ b/fixtures/m_anna_heatpump_cooling/all_data.json @@ -60,7 +60,10 @@ }, "3cb70739631c4d17a86b8b12e8a5161b": { "active_preset": "home", - "available_schedules": ["standaard", "off"], + "available_schedules": [ + "standaard", + "off" + ], "dev_class": "thermostat", "firmware": "2018-02-08T11:15:53+01:00", "hardware": "6539-1301-5002", @@ -68,7 +71,13 @@ "mode": "auto", "model": "ThermoTouch", "name": "Anna", - "preset_modes": ["no_frost", "home", "away", "asleep", "vacation"], + "preset_modes": [ + "no_frost", + "home", + "away", + "asleep", + "vacation" + ], "select_schedule": "standaard", "sensors": { "cooling_activation_outdoor_temperature": 21.0, diff --git a/fixtures/m_anna_heatpump_idle/all_data.json b/fixtures/m_anna_heatpump_idle/all_data.json index 327a87f94..95fe17eb4 100644 --- a/fixtures/m_anna_heatpump_idle/all_data.json +++ b/fixtures/m_anna_heatpump_idle/all_data.json @@ -60,7 +60,10 @@ }, "3cb70739631c4d17a86b8b12e8a5161b": { "active_preset": "home", - "available_schedules": ["standaard", "off"], + "available_schedules": [ + "standaard", + "off" + ], "dev_class": "thermostat", "firmware": "2018-02-08T11:15:53+01:00", "hardware": "6539-1301-5002", @@ -68,7 +71,13 @@ "mode": "auto", "model": "ThermoTouch", "name": "Anna", - "preset_modes": ["no_frost", "home", "away", "asleep", "vacation"], + "preset_modes": [ + "no_frost", + "home", + "away", + "asleep", + "vacation" + ], "select_schedule": "standaard", "sensors": { "cooling_activation_outdoor_temperature": 25.0, diff --git a/fixtures/stretch_v23/all_data.json b/fixtures/stretch_v23/all_data.json index 27142c711..f8937f488 100644 --- a/fixtures/stretch_v23/all_data.json +++ b/fixtures/stretch_v23/all_data.json @@ -305,7 +305,9 @@ }, "f7b145c8492f4dd7a4de760456fdef3e": { "dev_class": "switching", - "members": ["407aa1c1099d463c9137a3a9eda787fd"], + "members": [ + "407aa1c1099d463c9137a3a9eda787fd" + ], "model": "Switchgroup", "name": "Test", "switches": { diff --git a/pyproject.toml b/pyproject.toml index 01653a360..e0cb4a5af 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta" [project] name = "plugwise" -version = "1.4.0" +version = "1.4.1" license = {file = "LICENSE"} description = "Plugwise Smile (Adam/Anna/P1) and Stretch module for Python 3." readme = "README.md" diff --git a/scripts/python-venv.sh b/scripts/python-venv.sh index a6cd2c588..3cf811bba 100755 --- a/scripts/python-venv.sh +++ b/scripts/python-venv.sh @@ -6,7 +6,7 @@ my_path=$(git rev-parse --show-toplevel) my_venv=${my_path}/venv # Ensures a python virtualenv is available at the highest available python3 version -for pv in "${pyversions[@]};"; do +for pv in "${pyversions[@]}"; do if [ "$(which "python$pv")" ]; then # If not (yet) available instantiate python virtualenv if [ ! -d "${my_venv}" ]; then diff --git a/scripts/setup.sh b/scripts/setup.sh index 932f755ab..add58c35b 100755 --- a/scripts/setup.sh +++ b/scripts/setup.sh @@ -13,13 +13,10 @@ if [ -f "${my_venv}/bin/activate" ]; then . "${my_venv}/bin/activate" set -o nounset # Install commit requirements - pip install wheel - pip install --upgrade -e . -r requirements_commit.txt -c https://raw.githubusercontent.com/home-assistant/core/dev/homeassistant/package_constraints.txt -r https://raw.githubusercontent.com/home-assistant/core/dev/requirements_test_pre_commit.txt + pip install wheel uv + uv pip install --upgrade -e . -r requirements_commit.txt -c https://raw.githubusercontent.com/home-assistant/core/dev/homeassistant/package_constraints.txt -r https://raw.githubusercontent.com/home-assistant/core/dev/requirements_test_pre_commit.txt # Install pre-commit hook "${my_venv}/bin/pre-commit" install - # Prepare node virtualenv and prettier - nodeenv -p # Use node with existing python-virtual env - npm install prettier else echo "Virtualenv available, bailing out" exit 2 diff --git a/scripts/setup_test.sh b/scripts/setup_test.sh index 48b9f46d4..a117c7011 100755 --- a/scripts/setup_test.sh +++ b/scripts/setup_test.sh @@ -11,11 +11,28 @@ if [ -f "${my_venv}/bin/activate" ]; then set +o nounset # Workaround https://github.com/pypa/virtualenv/issues/150 for nodeenv # shellcheck disable=SC1091 . "${my_venv}/bin/activate" + mkdir -p ./tmp set -o nounset # Install test requirements - pip install --upgrade -e . -r requirements_test.txt -c https://raw.githubusercontent.com/home-assistant/core/dev/homeassistant/package_constraints.txt -r https://raw.githubusercontent.com/home-assistant/core/dev/requirements_test.txt -r https://raw.githubusercontent.com/home-assistant/core/dev/requirements_test_pre_commit.txt - # Install pre-commit hook - "${my_venv}/bin/pre-commit" install + uv pip install --upgrade -e . -r requirements_test.txt -c https://raw.githubusercontent.com/home-assistant/core/dev/homeassistant/package_constraints.txt -r https://raw.githubusercontent.com/home-assistant/core/dev/requirements_test.txt -r https://raw.githubusercontent.com/home-assistant/core/dev/requirements_test_pre_commit.txt + # Prepare biomejs + echo "Fetching/updating biome cli" + if uname -a | grep -q arm64; then + curl -sL "https://github.com/biomejs/biome/releases/latest/download/biome-darwin-arm64" -o "${my_path}/tmp/biome" + elif uname -a | grep -q x86_64; then + curl -sL "https://github.com/biomejs/biome/releases/latest/download/biome-linux-x64" -o "${my_path}/tmp/biome" + else + echo "Unable to determine processor and as such to install packaged biome cli version, bailing out" + exit 2 + fi + + # Make biome executable (if necessary) + chmod +x "${my_path}/tmp/biome" + + # Install pre-commit hook unless running from within pre-commit + if [ "$#" -eq 0 ]; then + "${my_venv}/bin/pre-commit" install + fi else echo "Virtualenv available, bailing out" exit 2 diff --git a/scripts/tests_and_coverage.sh b/scripts/tests_and_coverage.sh index 44d07a354..580482c44 100755 --- a/scripts/tests_and_coverage.sh +++ b/scripts/tests_and_coverage.sh @@ -43,15 +43,12 @@ if [ -z "${GITHUB_ACTIONS}" ] || [ "$1" == "linting" ] ; then pylint plugwise/ tests/ fi -# As to not generated fixtures, leaving prettier to re-do them +# As to not generated fixtures, leaving biome to re-do them # so no auto-generation during github run of testing # Creating todo #313 to 'gracefully' do this on merge on github action if [ -z "${GITHUB_ACTIONS}" ] || [ "$1" == "fixtures" ] ; then echo "... crafting manual fixtures ..." PYTHONPATH=$(pwd) python3 scripts/manual_fixtures.py - echo "... prettier-ing (fixtures and testdata) ..." - npx prettier --write --list-different --ignore-unknown --log-level silent fixtures/ tests/data -else - echo "... prettier-ing (fixtures and testdata) ..." - npx prettier --write --list-different --ignore-unknown --log-level silent fixtures/ tests/data fi +echo "... biome-ing (fixtures and testdata) ..." +./tmp/biome lint --staged --files-ignore-unknown=true --no-errors-on-unmatched