Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Meta: Limit IPR check job to the tc39 repository #3006

Merged
merged 1 commit into from
Feb 16, 2023

Conversation

gibson042
Copy link
Contributor

This aligns it with the other privileged jobs.

@bakkot bakkot requested a review from ljharb January 29, 2023 17:06
@ljharb
Copy link
Member

ljharb commented Jan 29, 2023

I had it this way so I could test it on my fork; maybe instead it could check not the repo name, but the presence of the secrets?

@ljharb ljharb added the meta label Jan 29, 2023
@gibson042
Copy link
Contributor Author

I'm not sure I understand; are you saying that this job should be subject to different conditions than the other privileged ecma262 workflows such as deploy and upload preview?

@ljharb
Copy link
Member

ljharb commented Jan 30, 2023

Yes - in general, I think an action should be checking for secret presence instead of hardcoding the repo name, but "upload preview" can't ever work for another repo (on the begin side), so that check is correct.

@gibson042
Copy link
Contributor Author

I think that's answering a different question than I asked. I agree that hardcoding the repo name isn't great, but I see more value in consistency across checks than in updating just one workflow to use a better approach. Regardless, I don't feel very strongly about this so if you make a concrete ```suggestion I'll accept it (or you can just apply a change directly).

@ljharb
Copy link
Member

ljharb commented Jan 30, 2023

I don't think consistency has much value here; each job is doing its own bespoke thing. I'll add a suggestion, though.

.github/workflows/ipr.yml Outdated Show resolved Hide resolved
@bakkot bakkot added the ready to merge Editors believe this PR needs no further reviews, and is ready to land. label Feb 15, 2023
@ljharb ljharb merged commit c9626d9 into tc39:main Feb 16, 2023
ljharb added a commit that referenced this pull request Feb 16, 2023
Apparently secrets can not be checked at workflow level
ljharb added a commit that referenced this pull request Feb 16, 2023
@ljharb
Copy link
Member

ljharb commented Feb 16, 2023

I ended up having to revert this; apparently secrets aren't available inside if conditionals. We'd have to figure out something more complex to make this job conditional on the secrets, and I prefer not to hardcode it to the specific repo.

If you'd like to try an alternative approach please open up a new PR.

@gibson042
Copy link
Contributor Author

@ljharb What about the original approach in 919b36d that is aligned with the other privileged ecma262 workflows such as deploy and upload preview?

@ljharb
Copy link
Member

ljharb commented Feb 16, 2023

That approach would work, but it would limit testing - the reason those specific deploys have that check is because the begin.com service they talk to also has that check.

@gibson042
Copy link
Contributor Author

gibson042 commented Feb 20, 2023

Right now this check is generating spurious failures in my own fork repository, and presumably in other forks as well. Where do you think it needs to happen other than tc39/ecma262, and why does the same not apply to the other privileged workflows?

@ljharb
Copy link
Member

ljharb commented Feb 20, 2023

I test changes to the workflow in ljharb/ecma262 so that I know they pass before landing them here. I failed to do that very testing on this PR, unfortunately.

The other privileged workflows are unique in that they contact a third party service that explicitly rejects, serverside, anything that's not tc39/ecma262.

I agree that spurious failures in a fork are undesirable, I just don't want to prevent testability of the workflow in the process if it can be avoided.

@gibson042
Copy link
Contributor Author

Can you move that from ljharb/ecma262 to non-main branches of tc39/ecma262? Or possibly to a new fork such as tc39/ecma262-testing?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
meta ready to merge Editors believe this PR needs no further reviews, and is ready to land.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants