def METHOD_NAME(testcase):
  """Notify the bisection infrastructure of a testcase getting into invalid
  state."""
  pubsub_topic = _get_topic()
  if not pubsub_topic:
    return
  pubsub_client = pubsub.PubSubClient()
  pubsub_client.publish(pubsub_topic, [
      pubsub.Message(b'', {
          'type': 'invalid',
          'testcase_id': str(testcase.key.id()),
      })
  ])