robertdfrench / git-pr

Pull requests without Git(Hub|Lab)
GNU General Public License v3.0
0 stars 1 forks source link

Add Simple GitHub Action Workflow #15

Closed robertdfrench closed 3 years ago

robertdfrench commented 3 years ago

This came from a template, I'm not entirely sure how it will behave.

robertdfrench commented 3 years ago

It seems to work! There are no tests in this branch, but cargo test does at least run: https://github.com/robertdfrench/git-pr/pull/15/checks?check_run_id=3865816218

robertdfrench commented 3 years ago

@calebwherry I know we just discussed this, but I can't remember exactly what I said, and I get the feeling that I am about to contradict myself. So I apologize if I am about to induce a facepalm here. I think that our policy should look like this:

I say this because I believe that behavioral rather than performance differences between debug and release mode should not occur unless there is a bug in rustc, in which case we have bigger problems. (I guess a race condition is an example of a performance difference that could result in a behavioral difference, but I don't think we'll need any concurrency in this project). I don't think we should try to defensive against compiler bugs, for the same reason that we aren't really investing the effort to defend against bugs in the libraries we use.

That being said, what could we possibly lose by testing in release mode in CI? The compiler might take ~10% more time, but this project is too small for compilation to really ever be a bottleneck. Debugging failed tests that occur in CI will already require us to reproduce those failures locally, because we won't have interactive access to the GitHub Actions instance. So, there does not seem to be a downside, or at least if one exists I can't articulate it.

I don't think it's necessary; but if you think my reasoning doesn't hold water, I'm not against it.

robertdfrench commented 3 years ago

Oh, also I don't know yet how to make GitHub Actions take different actions for different branches. So what is described here would give us debug builds in trunk, so we've got to at least fix that. And the easiest way to fix that is just to do release-mode testing on all branches, so maybe we'll do that and if it does end up actually being a problem, we can deal with it when it comes up.

robertdfrench commented 3 years ago

Yeah, you're right, this is better. Had to think through it for a bit first.