После обновления nodejs до 20 версии перестал запускаться zigbee2mqtt 1.38.0

Прилетели обновления и опять поломался zigbee2mqtt.

Start-Date: 2025-06-12  18:10:51
Commandline: apt upgrade
Install: wb-homeui-backend:armhf (2.115.12-wb103, automatic), wb-modbus-ext-scanner:armhf (1.3.0, automatic), libserialport0:armhf (0.1.1-4, automatic), mmc-utils:armhf (0+git20180327.b4fe0c8c-1+wb1, automatic)
Upgrade: python3-mqttrpc:armhf (1.2.5, 1.3.1), wb-mqtt-confed:armhf (1.15.1, 1.16.2), libcurl4:armhf (7.74.0-1.3+deb11u14, 7.74.0-1.3+deb11u15), libgssapi-krb5-2:armhf (1.18.3-6+deb11u6, 1.18.3-6+deb11u7), libcurl3-gnutls:armhf (7.74.0-1.3+deb11u14, 7.74.0-1.3+deb11u15), wb-mqtt-homeui:armhf (2.107.7-wb101, 2.115.12-wb103), wb-mqtt-db:armhf (2.8.17, 2.9.1), wb-mqtt-w1:armhf (2.2.14, 2.2.15), wb-configs:armhf (3.35.0, 3.38.3), wb-update-manager:armhf (1.3.5, 1.3.6), python3-wb-update-manager:armhf (1.3.5, 1.3.6), wb-mqtt-serial:armhf (2.153.3-wb102, 2.160.3-wb100), libateccssl1.1:armhf (0.2.5, 0.2.6), wb-device-manager:armhf (1.16.2, 1.18.2), wb-mqtt-opcua:armhf (1.1.11, 1.1.12), wb-hwconf-manager:armhf (1.66.0, 1.67.1), wireless-regdb:armhf (2022.04.08-2~deb11u1, 2025.02.20-1~deb11u1), libkrb5support0:armhf (1.18.3-6+deb11u6, 1.18.3-6+deb11u7), frpc:armhf (0.52.3, 0.52.3-3-gb5d7d14e-wb2), mqtt-tools:armhf (1.4.4, 1.4.5), python3-pkg-resources:armhf (52.0.0-4+deb11u1, 52.0.0-4+deb11u2), wb-cloud-agent:armhf (1.5.12, 1.5.14), wb-knxd-config:armhf (1.1.5, 1.1.6), libc6:armhf (2.31-13+deb11u12, 2.31-13+deb11u13), locales:armhf (2.31-13+deb11u12, 2.31-13+deb11u13), libkrb5-3:armhf (1.18.3-6+deb11u6, 1.18.3-6+deb11u7), modbus-utils-rpc:armhf (1.2.4, 1.2.5), wb-essential:armhf (1.19.0, 1.19.6), net-tools:armhf (1.60+git20181103.0eebece-1+deb11u1, 1.60+git20181103.0eebece-1+deb11u2), network-manager:armhf (1.42.4-1~bpo11+1-wb102, 1.42.4-1~bpo11+1-wb103), libk5crypto3:armhf (1.18.3-6+deb11u6, 1.18.3-6+deb11u7), wb-utils:armhf (4.25.3, 4.25.5), wb-diag-collect:armhf (1.9.0-wb100, 1.9.2), zigbee2mqtt:armhf (1.42.0-5-gbc6eccf-wb101, 2.1.1-wb101), wb-mqtt-iec104:armhf (1.1.13, 1.1.14), modbus-utils:armhf (1.3.0, 1.3.1), libc-dev-bin:armhf (2.31-13+deb11u12, 2.31-13+deb11u13), wb-release-info:armhf (1.0-stable~wb7+bullseye~20250428203430, 1.0-stable~wb7+bullseye~20250611114953), wb-rules:armhf (2.25.1, 2.29.0), libssl1.1:armhf (1.1.1w-0+deb11u2, 1.1.1w-0+deb11u3), libc-l10n:armhf (2.31-13+deb11u12, 2.31-13+deb11u13), wb-suite:armhf (1.19.0, 1.19.6), wb-mqtt-db-cli:armhf (1.4.6, 1.4.7), libwbmqtt1-5:armhf (5.3.3, 5.3.4), libc-bin:armhf (2.31-13+deb11u12, 2.31-13+deb11u13), libc-devtools:armhf (2.31-13+deb11u12, 2.31-13+deb11u13), wb-mqtt-mbgate:armhf (1.8.4, 1.8.6), wb-mqtt-logs:armhf (1.4.8, 1.5.3), libc6-dev:armhf (2.31-13+deb11u12, 2.31-13+deb11u13), wb-mcu-fw-updater:armhf (1.11.6, 1.12.1), serial-tool:armhf (1.2.1, 1.2.2), python3-paho-socket:armhf (0.0.3-2, 0.0.3-3), python3-wb-mcu-fw-updater:armhf (1.11.6, 1.12.1), curl:armhf (7.74.0-1.3+deb11u14, 7.74.0-1.3+deb11u15), wb-mqtt-gpio:armhf (2.15.2, 2.16.2), libnm0:armhf (1.42.4-1~bpo11+1-wb102, 1.42.4-1~bpo11+1-wb103), wb-mqtt-dac:armhf (1.2.5, 1.2.6), wb-mcu-fw-flasher:armhf (1.4.1, 1.4.2), wb-rules-system:armhf (1.12.3, 1.12.5), wb-mqtt-knx:armhf (1.13.3, 1.13.4), openssl:armhf (1.1.1w-0+deb11u2, 1.1.1w-0+deb11u3)
End-Date: 2025-06-12  18:21:58

Start-Date: 2025-06-12  18:23:08
Commandline: apt autoremove
Remove: python3-lib2to3:armhf (3.9.2-1), python3-all:armhf (3.9.2-3), python3-distutils:armhf (3.9.2-1)

Вовремя заметил опять дефолтный конфиг в пакете, отменил его установку. У меня стик на USB.
configuration.yaml.dpkg-dist

homeassistant: false
permit_join: false
mqtt:
  base_topic: zigbee2mqtt
  server: 'mqtt://localhost'
serial:
  port: /dev/ttyMOD4
  adapter: zstack
advanced:
  rtscts: false
  last_seen: epoch
  pan_id: GENERATE
  network_key: GENERATE
#frontend:
#  port: 8081
#  host: 0.0.0.0

В процесс обновления перекачивались какие-то npm пакеты. Версия NodeJS старая.

# apt policy nodejs
nodejs:
  Installed: 20.5.1-deb-1nodesource1
  Candidate: 20.5.1-deb-1nodesource1
  Version table:
 *** 20.5.1-deb-1nodesource1 990
        990 http://deb.wirenboard.com/wb7/bullseye stable/main armhf Packages
        100 /var/lib/dpkg/status
     12.22.12~dfsg-1~deb11u7 500
        500 http://debian-mirror.wirenboard.com/debian-security bullseye-security/main armhf Packages
     12.22.12~dfsg-1~deb11u4 500
        500 http://debian-mirror.wirenboard.com/debian bullseye/main armhf Packages
Jun 12 19:02:40 wirenboard-AVZTYW4Z npm[32542]: > zigbee2mqtt@2.1.1 start
Jun 12 19:02:40 wirenboard-AVZTYW4Z npm[32542]: > node index.js
Jun 12 19:02:43 wirenboard-AVZTYW4Z npm[32621]: Starting Zigbee2MQTT without watchdog.
Jun 12 19:02:47 wirenboard-AVZTYW4Z npm[32621]: /mnt/data/root/zigbee2mqtt/node_modules/.pnpm/js-yaml@4.1.0/node_modules/js-yaml/lib/loader.js:183
Jun 12 19:02:47 wirenboard-AVZTYW4Z npm[32621]:   return new YAMLException(message, mark);
Jun 12 19:02:47 wirenboard-AVZTYW4Z npm[32621]:          ^
Jun 12 19:02:47 wirenboard-AVZTYW4Z npm[32621]: YAMLException: duplicated mapping key (11:3)
Jun 12 19:02:47 wirenboard-AVZTYW4Z npm[32621]:   8 | serial:
Jun 12 19:02:47 wirenboard-AVZTYW4Z npm[32621]:   9 |   port: /dev/ttyUSB0
Jun 12 19:02:47 wirenboard-AVZTYW4Z npm[32621]:  10 |   adapter: auto
Jun 12 19:02:47 wirenboard-AVZTYW4Z npm[32621]:  11 |   adapter: zstack
Jun 12 19:02:47 wirenboard-AVZTYW4Z npm[32621]: --------^
Jun 12 19:02:47 wirenboard-AVZTYW4Z npm[32621]:  12 | frontend:
Jun 12 19:02:47 wirenboard-AVZTYW4Z npm[32621]:  13 |   port: 8081
Jun 12 19:02:47 wirenboard-AVZTYW4Z npm[32621]:     at generateError (/mnt/data/root/zigbee2mqtt/node_modules/.pnpm/js-yaml@4.1.0/node_modules/js-yaml/lib/loader.js:183:10)
Jun 12 19:02:47 wirenboard-AVZTYW4Z npm[32621]:     at throwError (/mnt/data/root/zigbee2mqtt/node_modules/.pnpm/js-yaml@4.1.0/node_modules/js-yaml/lib/loader.js:187:9)
Jun 12 19:02:47 wirenboard-AVZTYW4Z npm[32621]:     at storeMappingPair (/mnt/data/root/zigbee2mqtt/node_modules/.pnpm/js-yaml@4.1.0/node_modules/js-yaml/lib/loader.js:358:7)
Jun 12 19:02:47 wirenboard-AVZTYW4Z npm[32621]:     at readBlockMapping (/mnt/data/root/zigbee2mqtt/node_modules/.pnpm/js-yaml@4.1.0/node_modules/js-yaml/lib/loader.js:1173:9)
Jun 12 19:02:47 wirenboard-AVZTYW4Z npm[32621]:     at composeNode (/mnt/data/root/zigbee2mqtt/node_modules/.pnpm/js-yaml@4.1.0/node_modules/js-yaml/lib/loader.js:1441:12)
Jun 12 19:02:47 wirenboard-AVZTYW4Z npm[32621]:     at readBlockMapping (/mnt/data/root/zigbee2mqtt/node_modules/.pnpm/js-yaml@4.1.0/node_modules/js-yaml/lib/loader.js:1164:11)
Jun 12 19:02:47 wirenboard-AVZTYW4Z npm[32621]:     at composeNode (/mnt/data/root/zigbee2mqtt/node_modules/.pnpm/js-yaml@4.1.0/node_modules/js-yaml/lib/loader.js:1441:12)
Jun 12 19:02:47 wirenboard-AVZTYW4Z npm[32621]:     at readDocument (/mnt/data/root/zigbee2mqtt/node_modules/.pnpm/js-yaml@4.1.0/node_modules/js-yaml/lib/loader.js:1625:3)
Jun 12 19:02:47 wirenboard-AVZTYW4Z npm[32621]:     at loadDocuments (/mnt/data/root/zigbee2mqtt/node_modules/.pnpm/js-yaml@4.1.0/node_modules/js-yaml/lib/loader.js:1688:5)
Jun 12 19:02:47 wirenboard-AVZTYW4Z npm[32621]:     at Object.load (/mnt/data/root/zigbee2mqtt/node_modules/.pnpm/js-yaml@4.1.0/node_modules/js-yaml/lib/loader.js:1714:19)
Jun 12 19:02:48 wirenboard-AVZTYW4Z systemd[1]: zigbee2mqtt.service: Main process exited, code=exited, status=1/FAILURE

После удаления adapter: auto и указания порта в виде port: /dev/serial/by-id/XXX поднялось, хоть и не сразу. В процессе обновило конфиги на новый формат.

Здравствуйте.

Вам следует прописать порт /dev/ttyMOD4 в configuration.yaml

Также прошу уточнить работает ли zigbee2mqtt после перезаписи порта?