feat(arduino-shell): 在前端过滤掉 serial1/undefined 错误提示
This commit is contained in:
@@ -75,6 +75,16 @@ goog.loadJs('web', () => {
|
|||||||
} catch (error) {
|
} catch (error) {
|
||||||
Debug.error(error);
|
Debug.error(error);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 过滤掉无关紧要的端口错误(因为已经在本地完成上传了)
|
||||||
|
if (typeof data === 'string' && (
|
||||||
|
data.includes('cannot open serial1') ||
|
||||||
|
data.includes('cannot open device "undefined"') ||
|
||||||
|
data.includes('No such file or directory, cannot open')
|
||||||
|
)) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
statusBarTerminal.addValue(data);
|
statusBarTerminal.addValue(data);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user