I'm on HomeAssistant Green with OS 12.3, HA 2024.6.1 and SkyConnect.
I've cre…ated 2 quirks v2:
```
find /config/custom_zha_quirks/
/config/custom_zha_quirks/
/config/custom_zha_quirks/__pycache__
/config/custom_zha_quirks/__pycache__/zg-204zs.cpython-312.pyc
/config/custom_zha_quirks/__pycache__/zg-204zm.cpython-312.pyc
/config/custom_zha_quirks/zg-204zs.py
/config/custom_zha_quirks/zg-204zm.py
```
Source: [zg-204zs.py](https://gist.github.com/vinzent/2194a8ef531d8e8ec3bc17ea17eab0e9), [zg-204zm](https://gist.github.com/vinzent/2cd645b848fd3b6a0c3e5762956ec89f).
After adding one of the custom quirks, I can't reload the ZHA integration anymore. More or less instantly after reloading (ZHA integration -> 3dots -> Reload) it fails:
![grafik](https://github.com/zigpy/zigpy/assets/296297/a75c709c-76fe-418d-851e-7138c91902fd)
From `/homeassistant/home-assistant.log`:
```
2024-06-09 18:33:47.327 WARNING (ImportExecutor_0) [zhaquirks] Loaded custom quirks. Please contribute them to https://github.com/zigpy/zha-device-handlers
2024-06-09 18:33:47.504 ERROR (MainThread) [homeassistant.config_entries] Error setting up entry Home Assistant SkyConnect for zha
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/config_entries.py", line 594, in async_setup
result = await component.async_setup_entry(hass, self)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/zha/__init__.py", line 134, in async_setup_entry
async with radio_mgr.connect_zigpy_app() as app:
File "/usr/local/lib/python3.12/contextlib.py", line 210, in __aenter__
return await anext(self.gen)
^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/zha/radio_manager.py", line 182, in connect_zigpy_app
app = await self.radio_type.controller.new(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/zigpy/application.py", line 252, in new
await app._load_db()
File "/usr/local/lib/python3.12/site-packages/zigpy/application.py", line 108, in _load_db
await self._dblistener.load()
File "/usr/local/lib/python3.12/site-packages/zigpy/appdb.py", line 675, in load
device = zigpy.quirks.get_device(device)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/zigpy/quirks/__init__.py", line 41, in get_device
return _DEVICE_REGISTRY.get_device(device)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/zigpy/quirks/registry.py", line 96, in get_device
raise MultipleQuirksMatchException(
zigpy.exceptions.MultipleQuirksMatchException: Multiple matches found for device <Device model='TS0601' manuf='_TZE200_3towulqd' nwk=0x409E ieee=a4:c1:38:8d:03:11:b4:5e is_initialized=True>: [QuirksV2RegistryEntry(registry=<zigpy.quirks.registry.DeviceRegistry object at 0xffff686bacf0>, quirk_location='file[/config/custom_zha_quirks/zg-204zs.py]-line:146', filters=[], custom_device_class=None, device_node_descriptor=None, skip_device_configuration=True, adds_metadata=[AddsMetadata(cluster=<class 'zg-204zs.LuminanceMotionManufCluster'>, endpoint_id=1, cluster_type=<ClusterType.Server: 0>, constant_attributes={}), AddsMetadata(cluster=<class 'zg-204zs.TuyaOccupancySensing'>, endpoint_id=1, cluster_type=<ClusterType.Server: 0>, constant_attributes={})], removes_metadata=[RemovesMetadata(cluster_id=1280, endpoint_id=1, cluster_type=<ClusterType.Server: 0>), RemovesMetadata(cluster_id=3, endpoint_id=1, cluster_type=<ClusterType.Server: 0>)], replaces_metadata=[ReplacesMetadata(remove=RemovesMetadata(cluster_id=1, endpoint_id=1, cluster_type=<ClusterType.Server: 0>), add=AddsMetadata(cluster=<class 'zhaquirks.tuya.TuyaPowerConfigurationCluster2AAA'>, endpoint_id=1, cluster_type=<ClusterType.Server: 0>, constant_attributes={})), ReplacesMetadata(remove=RemovesMetadata(cluster_id=1024, endpoint_id=1, cluster_type=<ClusterType.Server: 0>), add=AddsMetadata(cluster=<class 'zg-204zs.TuyaIlluminanceMeasurement'>, endpoint_id=1, cluster_type=<ClusterType.Server: 0>, constant_attributes={}))], entity_metadata=[ZCLEnumMetadata(entity_platform=<EntityPlatform.SELECT: 'select'>, entity_type=<EntityType.CONFIG: 'config'>, cluster_id=61184, endpoint_id=1, cluster_type=<ClusterType.Server: 0>, initially_disabled=False, attribute_initialized_from_cache=True, translation_key=None, enum=<enum 'PirTime'>, attribute_name='pir_time'), ZCLEnumMetadata(entity_platform=<EntityPlatform.SELECT: 'select'>, entity_type=<EntityType.CONFIG: 'config'>, cluster_id=61184, endpoint_id=1, cluster_type=<ClusterType.Server: 0>, initially_disabled=False, attribute_initialized_from_cache=True, translation_key=None, enum=<enum 'PirSensitivity'>, attribute_name='pir_sensitivity'), NumberMetadata(entity_platform=<EntityPlatform.NUMBER: 'number'>, entity_type=<EntityType.CONFIG: 'config'>, cluster_id=61184, endpoint_id=1, cluster_type=<ClusterType.Server: 0>, initially_disabled=False, attribute_initialized_from_cache=True, translation_key=None, attribute_name='interval_time', min=1, max=720, step=1, unit=None, mode=None, multiplier=None, device_class=None)], device_automation_triggers_metadata={}), QuirksV2RegistryEntry(registry=<zigpy.quirks.registry.DeviceRegistry object at 0xffff686bacf0>, quirk_location='file[/config/custom_zha_quirks/zg-204zs.py]-line:146', filters=[], custom_device_class=None, device_node_descriptor=None, skip_device_configuration=True, adds_metadata=[AddsMetadata(cluster=<class 'zg-204zs.LuminanceMotionManufCluster'>, endpoint_id=1, cluster_type=<ClusterType.Server: 0>, constant_attributes={}), AddsMetadata(cluster=<class 'zg-204zs.TuyaOccupancySensing'>, endpoint_id=1, cluster_type=<ClusterType.Server: 0>, constant_attributes={})], removes_metadata=[RemovesMetadata(cluster_id=1280, endpoint_id=1, cluster_type=<ClusterType.Server: 0>), RemovesMetadata(cluster_id=3, endpoint_id=1, cluster_type=<ClusterType.Server: 0>)], replaces_metadata=[ReplacesMetadata(remove=RemovesMetadata(cluster_id=1, endpoint_id=1, cluster_type=<ClusterType.Server: 0>), add=AddsMetadata(cluster=<class 'zhaquirks.tuya.TuyaPowerConfigurationCluster2AAA'>, endpoint_id=1, cluster_type=<ClusterType.Server: 0>, constant_attributes={})), ReplacesMetadata(remove=RemovesMetadata(cluster_id=1024, endpoint_id=1, cluster_type=<ClusterType.Server: 0>), add=AddsMetadata(cluster=<class 'zg-204zs.TuyaIlluminanceMeasurement'>, endpoint_id=1, cluster_type=<ClusterType.Server: 0>, constant_attributes={}))], entity_metadata=[ZCLEnumMetadata(entity_platform=<EntityPlatform.SELECT: 'select'>, entity_type=<EntityType.CONFIG: 'config'>, cluster_id=61184, endpoint_id=1, cluster_type=<ClusterType.Server: 0>, initially_disabled=False, attribute_initialized_from_cache=True, translation_key=None, enum=<enum 'PirTime'>, attribute_name='pir_time'), ZCLEnumMetadata(entity_platform=<EntityPlatform.SELECT: 'select'>, entity_type=<EntityType.CONFIG: 'config'>, cluster_id=61184, endpoint_id=1, cluster_type=<ClusterType.Server: 0>, initially_disabled=False, attribute_initialized_from_cache=True, translation_key=None, enum=<enum 'PirSensitivity'>, attribute_name='pir_sensitivity'), NumberMetadata(entity_platform=<EntityPlatform.NUMBER: 'number'>, entity_type=<EntityType.CONFIG: 'config'>, cluster_id=61184, endpoint_id=1, cluster_type=<ClusterType.Server: 0>, initially_disabled=False, attribute_initialized_from_cache=True, translation_key=None, attribute_name='interval_time', min=1, max=720, step=1, unit=None, mode=None, multiplier=None, device_class=None)], device_automation_triggers_metadata={})]
```
## Workaround
Manual restart of HA core.