解决Python中出现的ValueError: not enough values to unpack (expected 2, got 1)的问题
2018-03-10 16:58
741 查看
解决问题:解决Python中出现的ValueError: not enough values to unpack (expected 2, got 1)的问题
解决思路:值错误,没有足够的值解压(期望2,得到1)。出现错误的原因是读取的文件有问题,读取的文件内不能包含换行符。
解决方法:将txt文件的内容中所有的换行去掉即可!
哈哈,大功告成!
相关文章推荐
- python 使用GridSearchCV 报错 ValueError: not enough values to unpack (expected 2, got 1)
- ValueError: not enough values to unpack (expected 2, got 1)
- ValueError: not enough values to unpack (expected 3, got 0)
- Celery ValueError: not enough values to unpack (expected 3, got 0)的解决方案
- 关于python下构建c模块出现error: Unable to find vcvarsall.bat问题的解决方法
- mysql连接linux系统提示“登录出现1130 is not allowed to connect to this MySql server”问题,解决方法
- 解决android sdk 运行出现 could not install *smartsocket* listener: cannot bind to 127.0.0.1:5037:的问题
- 使用myeclipse开发java,解决java中继承JFrame类出现The type JFrame is not accessible due to restriction的问题
- 解决使用python3.5来获取PCL库出现 unable to find vcvarsall.bat的问题
- ValueError: too many values to unpack (expected 2)
- 解决Linux出现"Device eth0 does not seem to be present"问题
- 解决android sdk 运行出现 could not install -smartsocket- listener- cannot bind to 127.0.0.1-5037-的问题
- 解决VMware出现Not enough physical memory is available to power on this virtual machine
- 解决iscsi initiator出现 “CHAP secret given does not conform to the standard”的问题
- telnet mysql时出现:is not allowed to connect to this MySQL serverConnection closed by foreign host问题的解决
- mysql连接linux系统提示“登录出现1130 is not allowed to connect to this MySql server”问题,解决方法
- windows安装python出现A program run as part of the setup did not finish as expected 的解决办法
- 解决安装vmware-tools出现的“The path "" is not a valid path to the 3.2.0-4-amd64 kernel headers”问题
- [Centos] mod_wsgi 安装流程以及遇到问题解决办法。apxs: command not found 或 Sorry, Python developer package does not appear to be installed.
- mysql连接linux系统提示“登录出现1130 is not allowed to connect to this MySql server”问题,解决方法