paramm-team / pybamm-param

Parameter optimisation for PyBaMM.
BSD 3-Clause "New" or "Revised" License
38 stars 8 forks source link

Post-job failing as develop branch is protected #54

Closed brosaplanella closed 1 year ago

brosaplanella commented 1 year ago

The post-job fails to push coverage report and requirements as the develop branch is protected and changes can't be directly pushed (see here). Not sure if we can bypass the protection only for the action, alternatively we can use the codecov/codecov-action@v3.1.4 action which seems to work in the PyBaMM repository.

PipGrylls commented 1 year ago

Does codecov add files, this part of the push was designed to ensure we have uptodate requirements and coverage.

To note this job fails as develop is protected which is why it doesn’t fail on the feature branches.

The solution here would be to add github actions as an exception to the branch protection rule, I dont have access to this setting.

PipGrylls commented 1 year ago

Am I correct in thinking that codecov doesn't actually commit to the repository? The documentation for it shows that it uploads coverage reports to codecov.io

muhammedsogut commented 1 year ago

Yes. I think it doesn't commit just shows a report.

PipGrylls commented 1 year ago

Okay fun updates, there is a new robot member of the team who can make pushes not so fun is that the push then triggers another run so I need to sort that. Also weirdly despite the fact that the VSCode git actions linter gives it a clean bill of health the release action is complaining.

So solution is in place but needs a little more polish.

muhammedsogut commented 1 year ago

If this new robot member of the team can write tests then it's more than welcome :)

PipGrylls commented 1 year ago

Okay the latest commit solves this and the PR closes this.

PipGrylls commented 4 months ago

As an addition to this the new line in the workflow: if: github.ref != 'refs/heads/main' && github.ref != 'refs/heads/master’

Solves the main branch job faliure.