1.TabError: inconsistent use of tabs and spaces in indentation

这是我的代码,感觉没啥不对,

后来运行之后出现了下面的错误,我也是弄了好久才弄好这个bug。

.

这个一般是由于你用编译器写代码时的Tab符和空格符混用引起的。对于Notepade++来说,只要你设置“显示空格和制表符”就行。

1.点击如下按钮:

2.手动设置:

View->Show Symbl->Show All Characters

下面是设置之后我的代码,这样就很容易看出来我的代码哪里有问题:

2.ModuleNotFoundError:No module named 'win32api'

真是令人烦躁,解决了这个问题之后,又出现了如下问题:

解决这个问题的办法如下:打开命令行,安装pypiwin32

Python之TabError: inconsistent use of tabs and spaces in indentation和ModuleNotFoundError:No module named 'win32api'的更多相关文章

  1. [bug] Python:“TabError: inconsistent use of tabs and spaces in indentation”

    原因 代码中混用了Tab和4个空格 参考 https://blog.csdn.net/dongdong9223/article/details/82745068

  2. python 报错 TabError: inconsistent use of tabs and spaces in indentation

    写python的时候如果出现如题的错误 TabError: inconsistent use of tabs and spaces in indentation 意为:制表符错误:缩进中制表符和空格使 ...

  3. Python文件运行时报TabError: inconsistent use of tabs and spaces in indentation

    1. 问题描述 Python文件运行时报TabError: inconsistent use of tabs and spaces in indentation 2. 问题原因 tab 和 space ...

  4. Python使用4个空格替换Tab, TabError: inconsistent use of tabs and spaces in indentation。

    问题:以前使用Pycharm和VsCode没遇到问题,使用nodepat++老是提示Tab异常  TabError: inconsistent use of tabs and spaces in in ...

  5. python运行错误---TabError: Inconsistent use of tabs and spaces in indentation

    本文转载于:http://blog.csdn.net/sinat_36384705/article/details/71155379 首先这个错误的意思是:在缩进的时候,使用了错误的空格和tab 我使 ...

  6. Python程序调试-TabError: inconsistent use of tabs and spaces in indentation

    报错信息:TabError: inconsistent use of tabs and spaces in indentation 说明:代码缩进统一使用Tab键或空格键,不能混用. 解决办法: 1. ...

  7. python错误提示“TabError: inconsistent use of tabs and spaces in indentation”

    在遍历打印10以内的奇数是出现“TabError: inconsistent use of tabs and spaces in indentation”的错误提示: 代码如下: 第一感觉没什么错误, ...

  8. vscode 遇到 TabError: inconsistent use of tabs and spaces in indentation

    Python开发,全靠缩进来控制Scope.缩进搞错了,代码也就有问题了.所以写着代码的时候,总是会遇到一个非常常见的问题.TabError: inconsistent use of tabs and ...

  9. PyCharm出现TabError: inconsistent use of tabs and spaces in indentation最简单实用的解决办法

    本文使用PyCharm的格式化代码功能解决TabError: inconsistent use of tabs and spaces in indentation. 当把代码从别处复制进来PyChar ...

随机推荐

  1. Hibernate入门(十一)多对多案例

    Hibernate多对多案例 1.用户对角色 DROP TABLE IF EXISTS emp_role; DROP TABLE IF EXISTS employee; DROP TABLE IF E ...

  2. vim 中:wq和:wq的不同之处

  3. memcached 源码阅览 一

    想要快速了解memcached内部原理么?那么赶紧离开本页,这会耽误您的时间. 不知时隔多少时间,今天受了些刺激,在码农路上开始犹豫起来,但是想想自己也没其他本身,就只好放下王者荣耀,重新看看技术内容 ...

  4. wx-charts 微信小程序图表 -- radarChart C# .net .ashx 测试

    radarChart:原始代码 new wxCharts({ canvasId: 'radarCanvas', type: 'radar', categories: ['1', '2', '3', ' ...

  5. django rest framework 与 Vue 整合遇到的坑

    前提是已经有了Django项目与前端Vue打包好的dist文件 好,开始整合!!! 当然还是先设置Django的setting.py 1设置模板路径 2 设置静态文件路径 TEMPLATES = [ ...

  6. 第二章 运算方法与运算器(浮点数的加减法,IEEE754标准32/64浮点规格化数)

    这一章,主要介绍了好多种计算方法.下面,写一点自己对于有些计算(手写计算过程)的见解. 1.原码.反码.补码 原码:相信大家都会写,符号位在前二进制数值在后,凑够位数即可. 反码:原码符号位不变,其他 ...

  7. codeforces 632C The Smallest String Concatenation

    The Smallest String Concatenation 题目链接:http://codeforces.com/problemset/problem/632/C ——每天在线,欢迎留言谈论. ...

  8. RESTful相关理解

    just 一种接口规范,写法种类不止一种  类似python的那啥标准

  9. PowerDesigner 12.5 汉化包-CSDN下载

    来源 csdn积分下载的. 人们太小家子气,随随便便文件要那么多积分. 地址 链接: https://pan.baidu.com/s/1cwc24Y 密码: cr9k

  10. mssql sqlserver 使用脚本输出excel文件的方法分享

    转自:http://www.maomao365.com/?p=6683 摘要: 下文将分享使用sql脚本输出excel的方法 此脚本可以应用于 表或视图生成excel的方法,若需使用sql脚本输出ex ...