Closed Shameel123 closed 2 years ago
The error persists on following node.js versions:
I have traced the error to zklibtco.js
The error occurs in following function when returning the data.
async getInfo() {
try {
const data = await this.executeCmd(COMMANDS.CMD_GET_FREE_SIZES, "");
return {
userCounts: data.readUIntLE(24, 4),
logCounts: data.readUIntLE(40, 4),
logCapacity: data.readUIntLE(72, 4),
};
} catch (err) {
console.log("noway");
return Promise.reject(err);
}
}
I have changed it to this and it is now working fine:
async getInfo() {
try {
const data = await this.executeCmd(COMMANDS.CMD_GET_FREE_SIZES, "");
return {
userCounts: data.readUIntLE(0, 4),
logCounts: data.readUIntLE(0, 4),
logCapacity: data.readUIntLE(0, 4),
};
} catch (err) {
console.log("noway");
return Promise.reject(err);
}
}
I am getting the following error and unable to understand the reason for its occurrence. I tried to find solutions on Google but different people are facing this issue for entirely different applications.
Node Version: 17.0.0
The code execute perfectly till ok tcp
Error: