code: def get_completed_tasks(self):
          
          self.owner.sync()
          tasks = []
          offset = 0
          while True:
              response = API.get_all_completed_tasks(self.owner.api_token,
                                                     limit=_PAGE_LIMIT,
                                                     offset=offset,
                                                     project_id=self.id)
              _fail_if_contains_errors(response)
              response_json = response.json()
              tasks_json = response_json['items']
              if len(tasks_json) == 0:
                  break  # There are no more completed tasks to retreive.
              for task_json in tasks_json:
                  project = self.owner.projects[task_json['project_id']]
                  tasks.append(Task(task_json, project))
              offset += _PAGE_LIMIT
          return tasks
docs: Return a list of all completed tasks in this project.
  
          :return: A list of all completed tasks in this project.
          :rtype: list of :class:`pytodoist.todoist.Task`
  
          >>> from pytodoist import todoist
          >>> user = todoist.login('john.doe@gmail.com', 'password')
          >>> project = user.get_project('PyTodoist')
          >>> task = project.add_task('Install PyTodoist')
          >>> task.complete()
          >>> completed_tasks = project.get_completed_tasks()
          >>> for task in completed_tasks:
          ...    task.uncomplete()