Closed BenHenning closed 4 months ago
@adhiamboperes PTAL with priority as this will block all merged PRs from passing (it doesn't block PR merging or PR CI workflows since that part is still configured correctly).
Enabling auto-merge since this seems like a straightforward fix and it'd be good to get this merged ASAP.
Rerunning bazel tests since CI is stuck.
Hi @BenHenning, this PR is ready to be merged. Please address any remaining comments prior to merging, and feel free to merge this PR once the CI checks pass and you're happy with it. Thanks!
Looks like the CI workflow change actually isn't valid:
[Invalid workflow file: .github/workflows/unit_tests.yml#L80](https://github.com/oppia/oppia-android/actions/runs/9199774806/workflow)
The workflow is not valid. .github/workflows/unit_tests.yml (Line: 80, Col: 29): Unexpected symbol: '"origin/develop"'. Located at position 39 within expression: github.event.pull_request.base.sha || "origin/develop"
Looks like it's passing now, and I've verified that the env looks correct:
env:
CACHE_DIRECTORY: ~/.bazel_cache
compute_all_targets: false
base_commit_hash: 24b17211a9d66447a3c9a6350aee5331eef1c1a3
Will verify again for develop once this is merged & will update the issue.
Explanation
Fixes #5407
This introduces a proper fallback for the base branch used for computing affected tests when off-develop:
origin/develop
(which was the same base used prior to #4929 being merged).This can't easily be verified without being merged, but I have high confidence it'll work since we've used the JavaScript
||
fallback syntax in GitHub workflowif
conditionals in the past (and the environment should be the same forenv
variables).Note that this is being fixed forward rather than reverted because the only verification is merging the PR, so it's actually faster and simpler to fix forward than to revert the original PR and re-submit a fix (which has the same likelihood of fixing CI as this fix forward).
Essential Checklist
For UI-specific PRs only
N/A -- This only affects CI infrastructure.