PYTHON : Python CSV error: line contains NULL byte

preview_player
Показать описание
PYTHON : Python CSV error: line contains NULL byte

PYTHON : Python CSV error: line contains NULL byte

Note: The information provided in this video is as it is with no modifications.
Thanks to many people who made this project happen. Disclaimer: All information is provided as it is with no warranty of any kind. Content is licensed under CC BY SA 2.5 and CC BY SA 3.0. Question / answer owners are mentioned in the video. Trademarks are property of respective owners and stackexchange. Information credits to stackoverflow, stackexchange network and user contributions. If there any issues, contact us on - htfyc dot hows dot tech

#PYTHON:PythonCSVerror:linecontainsNULLbyte #PYTHON #: #Python #CSV #error: #line #contains #NULL #byte

Guide : [ PYTHON : Python CSV error: line contains NULL byte ]
Рекомендации по теме
Комментарии
Автор

It worked very well for me, I did it in the following way

if '\0' in open(path).read():
fi = open(path, "rb")
data = fi.read()
fi.close()
fo = open(path, "wb")
fo.write(data.replace(b'\0', b''))
fo.close()

In this way, if it detects that it contains blank lines, it replaces them with ''

vaky
join shbcf.ru