str object has no attribute ‘splict'
时间: 2023-08-22 22:08:49 浏览: 115
引用的解释,decode()方法是用来将bytes类型转换为string类型的,但在此处应该不需要解码。因此,可以将if语句注释掉来解决这个错误。<span class="em">1</span><span class="em">2</span><span class="em">3</span>
#### 引用[.reference_title]
- *1* *2* [Django2.2报错 AttributeError: str object has no attribute decode](https://blog.csdn.net/jueji1998/article/details/116496207)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v92^chatsearchT3_1"}}] [.reference_item style="max-width: 50%"]
- *3* [解决运行 AttributeError: ‘str‘ object has no attribute ‘read‘ and ‘str‘ object has no ...](https://blog.csdn.net/weixin_43638241/article/details/129364741)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v92^chatsearchT3_1"}}] [.reference_item style="max-width: 50%"]
[ .reference_list ]
阅读全文