Pandas CParseError, file downloaded via FTP
I am trying to read a csv file (downloaded via FTP )in Pandas using read_csv df = pandas.read_csv("file.csv") but I get error : CParserError: Error tokenizing data. C error: EOF inside string starting at line 652 The code to download the file via FTP: f = open(file_name, 'wb') ftp.retrbinary("RETR " + file_name, f.write) But when I download the same file on browser and parse it, it does fine. Please suggest any solution.
Try this instead: df = pandas.read_csv('ftp://...') # puth there the real FTP URL from docs: filepath_or_buffer : str, pathlib. Path, py._path.local.LocalPath or any object with a read() method (such as a file handle or StringIO) The string could be a URL. Valid URL schemes include http, ftp, s3, and file. For file URLs, a host is expected. For instance, a local file could be file ://localhost/path/to/table.csv
How to sort keys of dict by values?
a data structure with key as a cluster of words and value as a single word or string
Disable python warnings only for specific module via commandline
Error running GAE tutorial code - Guestbook
How to create a running total- Python [closed]
Unbuffered Python Subrocess PIPE
Django runserver syntax error
How to parse the string into list of tuples
Make instance methods global in module?
try-finally with SqlAlchemy: is this a good habit?
Bokeh not handling colors properly with ColumnDataSource
Psychopy MovieStim3: pausing errors
Django Mysql Complex annotations require an alias
Django: Unresolved reference 'project_name' warning
Using pyspeech for text-to-speech in python 2.7 script [duplicate]
How do I click this button using Selenium Webdriver?