0
votes
text = getPDFContent(path).encode("ascii", "ignore")

This is my actual code. Can anyone tell me what does ignore do? And if there's an another parameter for don't copy non-ascii chars? (I copied the function. It is used to get the contents of a pdf) Thanks

1

1 Answers

0
votes

Did you look at the documentation? The second argument to the encode method on a string object indicates how errors are handled.