Bluetooth causes Node Red to crash

Hi,

I'm trying to use Node Red to control a bathroom fan via bluetooth using the native Bluetooth of a Raspberry Pi 4.
In Node Red I've installed the node-red-contrib-generic-ble nodes and added Node Red to the Bluetooth group.
I'm able to start scanning, finding the fan, and add it in new Generic BLE config node.
A few seconds later Node Red will crash and try to restart in a repetitive cycle until I turn of Bluetooth on the Raspberry Pi. I've recently reinstalled OS and software on the Raspberry Pi with latest versions.

Log from restart to crash:

Starting as a systemd service.
22 Dec 15:22:40 - [info]
Welcome to Node-RED
===================
22 Dec 15:22:40 - [info] Node-RED version: v4.0.8
22 Dec 15:22:40 - [info] Node.js  version: v20.18.1
22 Dec 15:22:40 - [info] Linux 6.6.62+rpt-rpi-v8 arm64 LE
22 Dec 15:22:41 - [info] Loading palette nodes
22 Dec 15:22:48 - [info] Dashboard version 3.6.5 started at /ui
22 Dec 15:22:50 - [info] Settings file  : /home/ty/.node-red/settings.js
22 Dec 15:22:50 - [info] Context store  : 'default' [module=memory]
22 Dec 15:22:50 - [info] Context store  : 'file' [module=localfilesystem]
22 Dec 15:22:50 - [info] User directory : /home/ty/.node-red
22 Dec 15:22:50 - [warn] Projects disabled : editorTheme.projects.enabled=false
22 Dec 15:22:50 - [info] Flows file     : /home/ty/.node-red/flows.json
22 Dec 15:22:50 - [info] +-----------------------------------------------------
22 Dec 15:22:50 - [info] | uibuilder v7.0.4 initialised đź“—
22 Dec 15:22:50 - [info] | root folder: /home/ty/.node-red/uibuilder
22 Dec 15:22:50 - [info] | Using Node-RED's webserver at:
22 Dec 15:22:50 - [info] |   http://0.0.0.0:1880/
22 Dec 15:22:50 - [info] | Installed packages:
22 Dec 15:22:50 - [info] +-----------------------------------------------------
22 Dec 15:22:50 - [info] Server now running at http://127.0.0.1:1880/
22 Dec 15:22:50 - [info] Starting flows
22 Dec 15:22:50 - [info] [ui-base:UI Test 1] Node-RED Dashboard 2.0 (v1.21.0) started at /dashboard
22 Dec 15:22:50 - [info] [ui-base:UI Test 1] Created socket.io server bound to Node-RED port at path /dashboard/socket.io
22 Dec 15:22:52 - [info] Started flows
22 Dec 15:22:52 - [info] [mqtt-broker:d81ed6f490175c4f] Connected to broker: mqtt://localhost:1883
22 Dec 15:23:38 - [info] [GenericBLE] Start BLE scanning
22 Dec 15:24:44 - [red] Uncaught Exception:
22 Dec 15:24:44 - [error] TypeError: this._discoveredPeripheralUUids.indexOf is not a function
    at PeripheralRemovableNoble.onMiss (/home/ty/.node-red/node_modules/node-red-contrib-generic-ble/dist/noble/noble/index.js:61:72)
    at BluezBindings.emit (node:events:518:28)
    at BluezBindings.onDeviceMissed (/home/ty/.node-red/node_modules/node-red-contrib-generic-ble/dist/noble/lib/bluez/noble/lib/bluez/bindings.js:716:10)
    at BluezBindings.onDevicesServicesCharacteristicsMissed (/home/ty/.node-red/node_modules/node-red-contrib-generic-ble/dist/noble/lib/bluez/noble/lib/bluez/bindings.js:710:12)
    at ProxyInterface.emit (node:events:518:28)
    at EventEmitter.$listeners.<computed> (/home/ty/.node-red/node_modules/dbus-next/lib/client/proxy-interface.js:108:17)
    at EventEmitter.emit (node:events:518:28)
    at handleMessage (/home/ty/.node-red/node_modules/dbus-next/lib/bus.js:118:23)
    at EventEmitter.<anonymous> (/home/ty/.node-red/node_modules/dbus-next/lib/bus.js:147:9)
    at EventEmitter.emit (node:events:518:28)
nodered.service: Main process exited, code=exited, status=1/FAILURE
nodered.service: Failed with result 'exit-code'.

Anyone has ideas on how to make this work?

Hi @Switchblade2

Add to this cause.

Its for the author to address - But good luck, looks like its not being answered to

Thanks, I've added my case to the list. Not much activity though as you mentioned

There are a few other BT libraries - have you tried any of them?

https://flows.nodered.org/search?term=bluetooth&type=node