List function is not working in jupyter

from csv import reader

opened_file = open(‘C:/Users/mkman/Desktop/DataQ/mission2/artworks.csv’)
read_file = reader(opened_file)
children = list(read_file)
children = children[1:]
children.head()

Error:

UnicodeDecodeError Traceback (most recent call last)
in
3 opened_file = open(‘C:/Users/mkman/Desktop/DataQ/mission2/artworks.csv’)
4 read_file = reader(opened_file)
----> 5 children = list(read_file)
6 children = children[1:]
7 children.head()

~\Anaconda3\lib\encodings\cp1252.py in decode(self, input, final)
21 class IncrementalDecoder(codecs.IncrementalDecoder):
22 def decode(self, input, final=False):
—> 23 return codecs.charmap_decode(input,self.errors,decoding_table)[0]
24
25 class StreamWriter(Codec,codecs.StreamWriter):

UnicodeDecodeError: ‘charmap’ codec can’t decode byte 0x81 in position 6856: character maps to

1 Like

Hi @manojkumar.manish

Welcome to our Dataquest Community.

Please go through the below posts.

Thank You :slightly_smiling_face: .

1 Like