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

Ignore unsupported_attribute erros #3874

Merged
merged 1 commit into from
Feb 15, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 12 additions & 2 deletions devices/lixee.js
Original file line number Diff line number Diff line change
Expand Up @@ -556,7 +556,11 @@ const definition = {
(await Promise.allSettled(configReportings))
.filter((e) => e.status == 'rejected')
.forEach((e) => {
throw e.reason;
if (e.reason.code == 134) { // unsupported_attribute
logger.warn(e.reason.message);
} else {
throw e.reason;
}
});
},
ota: ota.lixee,
Expand All @@ -574,7 +578,13 @@ const definition = {
for (const e of currentExposes) {
await endpoint
.read(e.cluster, [e.att])
.catch((err) => { }); // TODO: Ignore reads error?
.catch((err) => {
if (err.code == 134) { // unsupported_attribute
console.warn(err.message);
} else {
throw err;
}
});
}
}, seconds * 1000);
globalStore.putValue(device, 'interval', interval);
Expand Down