title: Running a function on thread gives an error
body: <p>I am trying to run a function "generate_model" on thread which takes three arguments. </p>
  
  <pre><code>def thread_for_generate_model(Thread):
      def __init__(self, name, job_id, boolean_string, Batch_size):
          self.name = name
          self.job_id = job_id
          self.boolean_string = boolean_string
          self.Batch_size = Batch_size
  
      def run(self):
          LOGGER.info("vector model create started for job_id: %s on thread %s", self.job_id, self.name)
          generate_model(self.job_id, self.boolean_string, self.Batch_size)
          LOGGER.info("vector model created for job_id: %s", self.job_id)
  
  def main(): 
       ....
       thread_for_generate_model("Thread_for_vectormodel", job_id, generate_search_string(job_id,keywords), 5000).start()
       # I am trying to run this function on a thread
       # generate_model(job_id, generate_search_string(job_id,keywords), 5000)
       ....
  </code></pre>
  
  <p>I got an error , </p>
  
  <pre><code>TypeError: thread_for_generate_model() takes 1 positional argument but 4 were given
  </code></pre>
  
  <p>by solution in the <a href="https://stackoverflow.com/questions/44288364/keyboard-shortcut-takes-1-positional-argument-but-2-were-given">link</a>, I have modified as below by adding an additional parameter</p>
  
  <pre><code> def run(self, event=  None)
  </code></pre>
  
  <p>but still has the same error. how to rectify it? </p>