Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unhandled rejection TypeError: Cannot read properties of undefined (reading 'computed_dev_id') #23

Open
yzeng1314 opened this issue Oct 20, 2023 · 3 comments
Labels
bug Something isn't working

Comments

@yzeng1314
Copy link

Describe The Bug:
Every time an device status changes, it will throw this error.

Logs:

Unhandled rejection TypeError: Cannot read properties of undefined (reading 'computed_dev_id')
    at Client.get fingerprint (/volume1/homebridge/node_modules/homebridge-unifi-occupancy/src/client.ts:87:34)
    at Client.<anonymous> (/volume1/homebridge/node_modules/homebridge-unifi-occupancy/node_modules/typescript-memoize/src/memoize-decorator.ts:123:36)
    at /volume1/homebridge/node_modules/homebridge-unifi-occupancy/src/client_type.ts:53:56
    at /volume1/homebridge/node_modules/homebridge-unifi-occupancy/src/client_filter.ts:10:42
    at Array.some (<anonymous>)
    at ClientType.matchesClient (/volume1/homebridge/node_modules/homebridge-unifi-occupancy/src/client_filter.ts:10:29)
    at /volume1/homebridge/node_modules/homebridge-unifi-occupancy/src/client.ts:120:56
    at Array.find (<anonymous>)
    at Client.get type [as type] (/volume1/homebridge/node_modules/homebridge-unifi-occupancy/src/client.ts:120:38)
    at Client.get config (/volume1/homebridge/node_modules/homebridge-unifi-occupancy/src/client.ts:130:23)
    at Client.<anonymous> (/volume1/homebridge/node_modules/homebridge-unifi-occupancy/node_modules/typescript-memoize/src/memoize-decorator.ts:123:36)
    at Client.get displayName [as displayName] (/volume1/homebridge/node_modules/homebridge-unifi-occupancy/src/client.ts:168:14)
    at Client.accessoryUUIDKey (/volume1/homebridge/node_modules/homebridge-unifi-occupancy/src/client.ts:175:24)
    at Client.accessoryUUID (/volume1/homebridge/node_modules/homebridge-unifi-occupancy/src/accessory_subject.ts:14:53)
    at ClientTypeAccessoryHandler.get uuid [as uuid] (/volume1/homebridge/node_modules/homebridge-unifi-occupancy/src/accessory_handler.ts:124:26)
    at ClientTypeAccessoryHandler.get valid [as valid] (/volume1/homebridge/node_modules/homebridge-unifi-occupancy/src/accessory_handler.ts:158:23)
    at /volume1/homebridge/node_modules/homebridge-unifi-occupancy/src/platform.ts:349:21
    at Map.forEach (<anonymous>)
    at UnifiOccupancyPlatform.removeInvalidAccessories (/volume1/homebridge/node_modules/homebridge-unifi-occupancy/src/platform.ts:347:22)
    at UnifiOccupancyPlatform.refreshAccessories (/volume1/homebridge/node_modules/homebridge-unifi-occupancy/src/platform.ts:314:10)
    at /volume1/homebridge/node_modules/homebridge-unifi-occupancy/src/platform.ts:284:24
    at tryCatcher (/volume1/homebridge/node_modules/homebridge-unifi-occupancy/node_modules/bluebird/js/release/util.js:16:23)
@yzeng1314 yzeng1314 added the bug Something isn't working label Oct 20, 2023
@yzeng1314
Copy link
Author

when i check the output from https://<ip>/proxy/network/v2/api/site/default/clients/active, i do see a few of my devices doesn't have full fingerprint object, i.e. missing computed_dev_id field etc.

@DouweM
Copy link
Owner

DouweM commented Nov 1, 2023

@yzeng1314 What version of UnifiOS are you running? Is fingerprinting enabled?

@yzeng1314
Copy link
Author

yzeng1314 commented Nov 2, 2023

@DouweM It is on UniFi OS 3.1.16 and yes, fingerprinting is enabled. Most of my devices are showing fingerprint just fine via the API

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants