Skip to content

Fix DDF JSON format#8019

Merged
manup merged 4 commits into
dresden-elektronik:masterfrom
bluemoehre:fix-code-format
Nov 8, 2024
Merged

Fix DDF JSON format#8019
manup merged 4 commits into
dresden-elektronik:masterfrom
bluemoehre:fix-code-format

Conversation

@bluemoehre
Copy link
Copy Markdown
Contributor

Currently there are multiple code format issues in some DDF JSON files.
This causes lots of linter warnings, when dealing with the project. Also it may lead to unnecessary complex reviews when fixing format issues on the fly while changing code.

So I fixed:

  • line indentations
  • convert tabs to spaces
  • removed trailing spaces
  • property assignment spaces

I did NOT fix:

  • general code format
  • single line properties
  • order of props

… because this will cause line shifts and make the diff very hard to review. (I can place another PR when this one was merged.)

Note

No code contents were harmed in this PR 🐶

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Nov 4, 2024

Hey @bluemoehre, thanks for your pull request!

Tip

Modified bundles can be downloaded here.
Relative expire date

DDB changes

Modified

  • 3A-Nue/Lxn59-2s7lX1.0.json : 2 gang inline switch (ZW-EU-02) ✔️

  • neo/TS0012_Immax_smart_controller.json : Immax Smart controller (TS0012) ✔️

  • tuya/_TZ3000_TS0011_1gang_switch_module.json : 1 gang switch module (TS0011) ✔️

  • tuya/_TZ3000_gzvniqjb_din_rail_switch.json : DIN rail circuit breaker 63A (TO-Q-SY1-ZT) ✔️

  • tuya/_TZ3000_qewo8dlz_wired_switch_3gangs.json : Wired Switch 3 gangs (TS0013) ✔️

  • tuya/_TZ3000_jl7qyupf_2gangs_switch_locked.json : Wired switch 2 gangs (TS0012) ✔️

  • moes/Moes_ZM-105-M_1_gang_dimmer.json : Switch (TS0601) ✔️

  • tuya/_TZ3000_2channel_module.json : 2 output module (TS0002) ✔️

  • tuya/_TZ3000_wkr3jqmr_4channel_module.json : 4 output module (TS0004) ✔️

  • moes/Moes_TZ3000_TS0012_2_gang_switches.json : 2 gang switches (TS0012) ✔️

  • sunricher/zg2855-rgb_button.json : 3 in 1 zigbee push button remote (ZG2855-RGB) ✔️

  • tuya/_TZ3000_TS011F_PowerStrip.json : Powerstrip with USB (TS011F) ✔️

  • xiaomi/xiaomi_wxkg01lm_mini_switch.json : Wireless mini switch (WXKG01LM) ✔️

  • tuya/_TZ3000_TS0041_1gang_remote.json : 1-gang remote (TS0041) ✔️

  • tuya/_TZ3000_TS004F_switch.json : Scene switch (TS004F) ✔️

  • woox/woox_r7054_remote.json : 4 gang switch (R7054) ✔️

  • namron/4512765_hum_temp.json : Temperature and humidity sensor (4512765/S903TH-ZG) ✔️

  • sonoff/snzb-02-multisensor.json : Temperature And Humidity Sensor (SNZB-02) ✔️

  • third_reality/3RTHS24BZ_multi_sensor.json : Temperature and humidity sensor with digital LCD display (3RTHS24BZ) ✔️

  • tuya/_TYZB01_SM0201_temp_hum_sensor.json : Temperature and humidity sensor with LCD display (SM0201) ✔️

  • woox/woox_r7048_hum_temp_sensor.json : Temperature and Humidity Sensor (R7048) ✔️

  • woox/woox_r7052_ts0215a.json : Smart SOS button (R7052) ✔️

  • xiaomi/xiaomi_mho-c401n_temp_hum_sensor.json : Temperature and humidity sensor with display (MHO-C401N) ✔️

  • nedis/nedis_zbsm10wt_motion_sensor.json : Zigbee motion sensor (ZBSM10WT) ✔️

  • third_reality/3RWS18BZ_water_sensor.json : Water leak sensor (3RWS18BZ) ✔️

  • tuya/_TZ3000_TS0201_temp_hum_sensor.json : Temperature and humidity sensor (TS0201) ✔️

  • tuya/_TZE200_TS0601_mmWave_Radar.json : 2.4GHz mmWave radar with LED (TS0601) ✔️

  • xiaomi/xiaomi_wrs-r02_h1_switch.json : H1 dual rocker wireless remote switch (WRS-R02) ✔️

  • xiaomi/xiaomi_wxkg17lm_e1_switch.json : E1 dual rocker wireless switch (WXKG17LM) ✔️

  • tuya/_TZ3000_TS0203_door_sensor.json : Door window contact (TS0203) ✔️

  • tuya/_TZ3210_ncw88jfq_temp-hum-sensor.json : Temperature and humidity sensor ✔️

  • tuya/_TZ3210_dse8ogfy_fingerbot.json : Adaprox fingerbot (TS0001) ✔️

  • tuya/_TZE204_ac0fhfiq_energy_meter.json : BiDirectional zigbee energy meter (TS0601) ✔️

  • tuya/ts0202_presence_sensor.json : Presence sensor (TS0202) ✔️

  • xiaomi/xiaomi_qbkg04lm_switch.json : Single rocker switch (QBKG04LM) ✔️

  • dresden_elektronik/scene_switch.json : Multifunctional wireless switch (Scene switch) ✔️

  • xiaomi/xiaomi_mfkzq12lm_t1_pro_cube.json : T1 pro cube (MFKZQ12LM) ✔️

  • xiaomi/xiaomi_ssm-u02_t1_switch.json : T1 single rocker switch no neutral wire (SSM-U02) ✔️

  • xiaomi/xiaomi_ws-euk02_h1_switch.json : H1 dual rocker switch no neutral wire (WS-EUK02) ✔️

  • adeo/ldsenk08_door_vibration_sensor.json : Lexman door window sensor with vibration (LDSENK08) ✔️

  • moes/Moes_TZE200_ztvwu4nk_thermostat.json : Thermostat for Water/Gas Boiler (BHT-002) ✔️

  • wiser/fuga_socket_outlet.json : LK Fuga Wiser wireless socket outlet 16A (545D6115) ✔️

  • xiaomi/xiaomi_lumi.airrtc.agl001.json : Smart radiator thermostat E1 (SRTS-A01) ✔️

  • xiaomi/xiaomi_ws-euk01_h1_switch.json : H1 single rocker switch no neutral wire (WS-EUK01) ✔️

  • third_reality/3RSPE01044BZ_smart_plug.json : Smart plug ✔️

  • develco/splzb-131_smart_plug.json : Smart plug mini type F - Schuko (SPLZB-131) ✔️

  • elko/thermostat_16_a.json : Connected thermostat elko smart plus 16A (EKO07259) ✔️

  • stelpro/smt402ad.json : Thermostat (SMT402AD) ✔️

  • frient/kepzb-110_keypad.json : Wireless keypad (KEPZB-110) ✔️

  • xfinity/THK1_keypad.json : Security keypad ✔️

  • xiaomi/xiaomi_ws-euk04_h1_switch.json : H1 dual rocker switch neutral wire (WS-EUK04) ✔️

  • xiaomi/xiaomi_ws-euk03_h1_switch.json : H1 single rocker switch neutral wire (WS-EUK03) ✔️

  • xiaomi/xiaomi_ssm-u01_t1_switch.json : T1 single rocker switch with neutral wire (SSM-U01) ✔️

  • bosch/bmct-slz_shutter_light_control2.json : Light and shutter control II (BMCT-SLZ) ✔️

  • icasa/ICZB-IW21D.json : Zigbee Dimmer PRO ✔️

  • owon/PIR313-E_sensor_multi.json : Motion multi sensor (PIR313) ✔️

  • frient/moszb-153_motion_sensor.json : Motion sensor 2 - Pet (MOSZB-153) ✔️

  • mli/zbt-extendedcolor.json : Tint GU10 spot ✔️

  • danfoss/etrv0100_thermostat.json : Ally radiator thermostat (014G2461) ✔️

  • namron/4512737_thermostat.json : Thermostat touch zigbee 16A (4512737/4512738) ✔️

Validation

Tip

Everything is fine !

🕤 Updated for commit 31fda63

@bluemoehre bluemoehre changed the title Fix code format fix DDF code format Nov 4, 2024
@bluemoehre
Copy link
Copy Markdown
Contributor Author

Hey @manup , can you merge the cleanup by any chance on the fast lane, so we will have the same code format in all DDFs?

@manup manup changed the title fix DDF code format Fix DDF code format Nov 8, 2024
@manup manup changed the title Fix DDF code format Fix DDF JSON format Nov 8, 2024
@manup manup added the Fix label Nov 8, 2024
@manup
Copy link
Copy Markdown
Member

manup commented Nov 8, 2024

Wow that's a bunch, good work 👍
Guess it would be cool to incorporate the formatting as a PR merge step or GIT hook in future to stay consistent.

@manup manup merged commit c5cac4c into dresden-elektronik:master Nov 8, 2024
@manup manup added this to the v2.29.1-beta milestone Nov 8, 2024
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Nov 8, 2024

This pull request is now merged. The new DDB files have been uploaded to the store.

DDB Files

Modified

  • 3A-Nue/Lxn59-2s7lX1.0.json : 2 gang inline switch (ZW-EU-02) : with hash (1cc7c49c85)

  • neo/TS0012_Immax_smart_controller.json : Immax Smart controller (TS0012) : with hash (284a1dca5a)

  • tuya/_TZ3000_TS0011_1gang_switch_module.json : 1 gang switch module (TS0011) : with hash (c4bf155c4b)

  • tuya/_TZ3000_gzvniqjb_din_rail_switch.json : DIN rail circuit breaker 63A (TO-Q-SY1-ZT) : with hash (4ffe20e7f7)

  • tuya/_TZ3000_qewo8dlz_wired_switch_3gangs.json : Wired Switch 3 gangs (TS0013) : with hash (25e3ae4fa8)

  • tuya/_TZ3000_jl7qyupf_2gangs_switch_locked.json : Wired switch 2 gangs (TS0012) : with hash (d30bccfacd)

  • moes/Moes_ZM-105-M_1_gang_dimmer.json : Switch (TS0601) : with hash (2851cd7881)

  • tuya/_TZ3000_2channel_module.json : 2 output module (TS0002) : with hash (08f33c3877)

  • tuya/_TZ3000_wkr3jqmr_4channel_module.json : 4 output module (TS0004) : with hash (064a5a412d)

  • moes/Moes_TZ3000_TS0012_2_gang_switches.json : 2 gang switches (TS0012) : with hash (6c2ba18f00)

  • tuya/_TZ3000_TS011F_PowerStrip.json : Powerstrip with USB (TS011F) : with hash (226dcaf244)

  • sunricher/zg2855-rgb_button.json : 3 in 1 zigbee push button remote (ZG2855-RGB) : with hash (9846271245)

  • xiaomi/xiaomi_wxkg01lm_mini_switch.json : Wireless mini switch (WXKG01LM) : with hash (934e610803)

  • tuya/_TZ3000_TS0041_1gang_remote.json : 1-gang remote (TS0041) : with hash (586bace8c5)

  • tuya/_TZ3000_TS004F_switch.json : Scene switch (TS004F) : with hash (b45f32ebd0)

  • woox/woox_r7054_remote.json : 4 gang switch (R7054) : with hash (222f2f56b0)

  • namron/4512765_hum_temp.json : Temperature and humidity sensor (4512765/S903TH-ZG) : with hash (9455273557)

  • sonoff/snzb-02-multisensor.json : Temperature And Humidity Sensor (SNZB-02) : with hash (17319b133d)

  • third_reality/3RTHS24BZ_multi_sensor.json : Temperature and humidity sensor with digital LCD display (3RTHS24BZ) : with hash (854288c149)

  • tuya/_TYZB01_SM0201_temp_hum_sensor.json : Temperature and humidity sensor with LCD display (SM0201) : with hash (d498b3b525)

  • woox/woox_r7048_hum_temp_sensor.json : Temperature and Humidity Sensor (R7048) : with hash (4b8bfcc7b1)

  • woox/woox_r7052_ts0215a.json : Smart SOS button (R7052) : with hash (753d5a3ebb)

  • xiaomi/xiaomi_mho-c401n_temp_hum_sensor.json : Temperature and humidity sensor with display (MHO-C401N) : with hash (0aac2849e6)

  • nedis/nedis_zbsm10wt_motion_sensor.json : Zigbee motion sensor (ZBSM10WT) : with hash (7d2298050d)

  • third_reality/3RWS18BZ_water_sensor.json : Water leak sensor (3RWS18BZ) : with hash (b53efae801)

  • tuya/_TZ3000_TS0201_temp_hum_sensor.json : Temperature and humidity sensor (TS0201) : with hash (c894537181)

  • tuya/_TZE200_TS0601_mmWave_Radar.json : 2.4GHz mmWave radar with LED (TS0601) : with hash (9919c45d15)

  • xiaomi/xiaomi_wrs-r02_h1_switch.json : H1 dual rocker wireless remote switch (WRS-R02) : with hash (bbcdae3ed1)

  • xiaomi/xiaomi_wxkg17lm_e1_switch.json : E1 dual rocker wireless switch (WXKG17LM) : with hash (76124b4ec4)

  • tuya/_TZ3000_TS0203_door_sensor.json : Door window contact (TS0203) : with hash (6cea1b53e4)

  • tuya/_TZ3210_ncw88jfq_temp-hum-sensor.json : Temperature and humidity sensor : with hash (69ffba2f91)

  • tuya/_TZ3210_dse8ogfy_fingerbot.json : Adaprox fingerbot (TS0001) : with hash (7f26c51175)

  • tuya/_TZE204_ac0fhfiq_energy_meter.json : BiDirectional zigbee energy meter (TS0601) : with hash (28f27a0ff0)

  • tuya/ts0202_presence_sensor.json : Presence sensor (TS0202) : with hash (98284375c6)

  • xiaomi/xiaomi_qbkg04lm_switch.json : Single rocker switch (QBKG04LM) : with hash (f449564443)

  • dresden_elektronik/scene_switch.json : Multifunctional wireless switch (Scene switch) : with hash (ca6a4ee53d)

  • xiaomi/xiaomi_mfkzq12lm_t1_pro_cube.json : T1 pro cube (MFKZQ12LM) : with hash (c5969b589f)

  • xiaomi/xiaomi_ssm-u02_t1_switch.json : T1 single rocker switch no neutral wire (SSM-U02) : with hash (143b711002)

  • xiaomi/xiaomi_ws-euk02_h1_switch.json : H1 dual rocker switch no neutral wire (WS-EUK02) : with hash (f71b89523e)

  • adeo/ldsenk08_door_vibration_sensor.json : Lexman door window sensor with vibration (LDSENK08) : with hash (c8526ebee4)

  • moes/Moes_TZE200_ztvwu4nk_thermostat.json : Thermostat for Water/Gas Boiler (BHT-002) : with hash (f816c02de1)

  • third_reality/3RSPE01044BZ_smart_plug.json : Smart plug : with hash (b1083b8380)

  • wiser/fuga_socket_outlet.json : LK Fuga Wiser wireless socket outlet 16A (545D6115) : with hash (23a912b6d0)

  • xiaomi/xiaomi_lumi.airrtc.agl001.json : Smart radiator thermostat E1 (SRTS-A01) : with hash (08a15e27a4)

  • xiaomi/xiaomi_ws-euk01_h1_switch.json : H1 single rocker switch no neutral wire (WS-EUK01) : with hash (7c923e7943)

  • elko/thermostat_16_a.json : Connected thermostat elko smart plus 16A (EKO07259) : with hash (fa848aa95c)

  • develco/splzb-131_smart_plug.json : Smart plug mini type F - Schuko (SPLZB-131) : with hash (63aded2765)

  • stelpro/smt402ad.json : Thermostat (SMT402AD) : with hash (9d82fc20b4)

  • frient/kepzb-110_keypad.json : Wireless keypad (KEPZB-110) : with hash (2e020b77d7)

  • xfinity/THK1_keypad.json : Security keypad : with hash (51d2263234)

  • namron/4512737_thermostat.json : Thermostat touch zigbee 16A (4512737/4512738) : with hash (928a52e373)

  • xiaomi/xiaomi_ws-euk04_h1_switch.json : H1 dual rocker switch neutral wire (WS-EUK04) : with hash (0b4299cba2)

  • xiaomi/xiaomi_ws-euk03_h1_switch.json : H1 single rocker switch neutral wire (WS-EUK03) : with hash (f204bc0355)

  • xiaomi/xiaomi_ssm-u01_t1_switch.json : T1 single rocker switch with neutral wire (SSM-U01) : with hash (ede1d409c1)

  • bosch/bmct-slz_shutter_light_control2.json : Light and shutter control II (BMCT-SLZ) : with hash (7214230582)

  • icasa/ICZB-IW21D.json : Zigbee Dimmer PRO : with hash (5d3ffae67e)

  • owon/PIR313-E_sensor_multi.json : Motion multi sensor (PIR313) : with hash (8f88e3e360)

  • frient/moszb-153_motion_sensor.json : Motion sensor 2 - Pet (MOSZB-153) : with hash (25e8fe4411)

  • mli/zbt-extendedcolor.json : Tint GU10 spot : with hash (e5d4eb2ab0)

  • danfoss/etrv0100_thermostat.json : Ally radiator thermostat (014G2461) : with hash (c573147172)

🕖 Updated for commit c5cac4c

@bluemoehre
Copy link
Copy Markdown
Contributor Author

Wow that's a bunch, good work 👍 Guess it would be cool to incorporate the formatting as a PR merge step or GIT hook in future to stay consistent.

Exactly - but first we have to agree on a setup. Unfortunately, I never received any feedback on this question in Discord. So let's stick with the standard format for now. Not perfect for all cases, but having everything the same is a step in the right direction.

@bluemoehre bluemoehre deleted the fix-code-format branch November 8, 2024 14:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants