code: def cancel(self, project, job, signal=None):
          
          url = self._build_url(constants.CANCEL_ENDPOINT)
          data = {
              'project': project,
              'job': job,
          }
          if signal is not None:
              data['signal'] = signal
          json = self.client.post(url, data=data, timeout=self.timeout)
          return json['prevstate']
docs: Cancels a job from a specific project. First class, maps to
          Scrapyd's cancel job endpoint.