Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
async def start_test_selection(self, build: PhabricatorBuild, revision: str):
"""
Run test selection by triggering a Taskcluster hook
"""
assert build.state == PhabricatorBuildState.Public
try:
if not self.should_run_test_selection(build):
return
task = self.community_tc["hooks"].triggerHook(
"project-relman",
"bugbug-test-select",
{
"PHABRICATOR_DEPLOYMENT": self.phabricator_deployment,
"DIFF_ID": build.diff_id,
"RUNNABLE_JOBS": self.index_service.buildUrl(
"findArtifactFromTask",
f"gecko.v2.try.revision.{revision}.firefox.decision",
"public/runnable-jobs.json",
),
},