VScode代码格式化插件black失效问题
之前有如下提示:
没太当回事,发现还能用。之后突然就用不了了,跟着官方插件的文档来查看log:
查看发现提示:
Message: TypeError: 'type' object is not subscriptable
在github界面找到解决方案:安装Version 2024.6.0即可
GitHub · Where software is builtFormatting support for Python using the Black formatter - microsoft/vscode-black-formatterhttps://github.com/microsoft/vscode-black-formatter/issues/564需要再插件界面点击齿轮:选择安装指定版本