mm, upload file could be removed to the highest level. but this method is not mine, can't say why it was written right here. I just replaced the self.conn