if the end of the line is import, should check if file_path exists

a = """import os
import sys

import something
"""

SortImports(file_contents=a) will raise error, because the end of the line is import.

Should ignore this error if file_path is None. or raise some other error.