I don’t know what fit does exactly, but would assume that the stacktrace would point to the line of code raising the error.
E.g. os.path.join(True) would raise this error so I guess that some internal method is trying to create a path or load a file with a bool input argument instead of a valid path.