MCPcopy Create free account
hub / github.com/apache/arrow / trigger_bot

Function trigger_bot

dev/archery/archery/cli.py:827–842  ·  view source on GitHub ↗
(arrow_token, committers_file, event_name, event_payload)

Source from the content-addressed store, hash-verified

825@click.option('--event-payload', '-p', type=click.File('r', encoding='utf8'),
826 default='-', required=True)
827def trigger_bot(arrow_token, committers_file, event_name, event_payload):
828 from .bot import CommentBot, PullRequestWorkflowBot, actions
829 from ruamel.yaml import YAML
830
831 event_payload = json.loads(event_payload.read())
832 if 'comment' in event_name:
833 bot = CommentBot(name='github-actions', handler=actions, token=arrow_token)
834 bot.handle(event_name, event_payload)
835 else:
836 committers = None
837 if committers_file:
838 committers = [committer['alias']
839 for committer in YAML().load(committers_file)]
840 bot = PullRequestWorkflowBot(event_name, event_payload, token=arrow_token,
841 committers=committers)
842 bot.handle()
843
844
845@archery.group("linking")

Callers

nothing calls this directly

Calls 6

handleMethod · 0.95
CommentBotClass · 0.85
loadsMethod · 0.80
readMethod · 0.45
loadMethod · 0.45

Tested by

no test coverage detected