Python: Passing SequenceMatcher in difflib an “autojunk=False” flag yields error
问题 I am trying to use the SequenceMatcher method in Python's difflib package to identify string similarity. I have experienced strange behavior with the method, though, and I believe my problem may be related to the package's "junk" filter, a problem described in detail here. Suffice it to say that I thought I could fix my problem by passing an autojunk flag to my SequenceMatcher in the way described by the difflib documentation: import difflib def matches(s1, s2): s = difflib.SequenceMatcher