Closed Bug 1564512 Opened 5 years ago Closed 4 years ago

[tc-github] a .taskcluster.yml in a PR without one in the master branch is skipped

Categories

(Taskcluster :: Services, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED MOVED

People

(Reporter: dustin, Unassigned)

References

(Blocks 1 open bug)

Details

(Keywords: good-first-bug)

https://github.com/taskcluster/taskcluster/blob/8bf75678626567ec2fdae3889dff2f6d86235958/services/github/src/handlers.js#L603-L605

    let defaultBranchYml = await this.getYml({instGithub, owner: organization, repo: repository, ref: defaultBranch});

    if (!defaultBranchYml) { return; }

This means experimenting with .taskcluster.yml in a PR silently does nothing.

Could we assume the most restrictive policy, instead?

Owlish, what do you think?

Flags: needinfo?(bugzeeeeee)

What policy would you suggest (to rephrase: what would "the most restrictive" mean)? (edited upon reading the title of the bug)

Flags: needinfo?(bugzeeeeee)

I think "collaborators" is the most restrictive (in other words, it allows the least of all of the policy options).

I see, so you are suggesting: why don't we stop checking the yml in the default branch and just use "collaborators" policy always. That will deprive people of policy choice tho?

No, my idea is that when there is no .taskcluster.yml in the default branch, then we default to "collaborators".

Hey there!

I hit that issue too, today. My main worry is that tc-github silently fails. I didn't have any feedback about the reason why no jobs were scheduled.

My STR are:

  1. Enable TC on a new repo
  2. Create a PR that creates .taskcluster.yml
  3. See a first error because of some parsing shenanigans.
  4. Fix it: No error is reported. No job is scheduled. Run json-e locally and see it output the expected result.

I was confused by this behavior, especially because tc-github did provide some early feedback at the beginning.

(In reply to Dustin J. Mitchell [:dustin] (he/him) from comment #5)

No, my idea is that when there is no .taskcluster.yml in the default branch, then we default to "collaborators".

+1, it's tricky setting up a .taskcluster.yml for the first time in a repo that i don't own atm.

Blocks: github-bugs
Mentor: bugzeeeeee
Keywords: good-first-bug
Mentor: bugzeeeeee
Status: NEW → RESOLVED
Closed: 4 years ago
Resolution: --- → MOVED
You need to log in before you can comment on or make changes to this bug.