python-template icon indicating copy to clipboard operation
python-template copied to clipboard

Less ci computation

Open cwmeijer opened this issue 1 year ago • 5 comments

I propose

  • fewer builds by only running on the first and latest supported python versions (@egpbos ' idea)
  • only run build jobs on several configurations when a single configuration has succeeded already

Pro:

  • less computation 🍃

Cons:

  • More time needed to finish the build job, as most runs will start only after the first has succeeded
  • We might miss a failing python version sometimes (only in quite special cases I imagine)

I did exactly this change in my own package, created using the python-template (see https://github.com/dianna-ai/distance_explainer/pull/7/files). I propose to do this exact change on the template as well.

cwmeijer avatar Jul 20 '23 11:07 cwmeijer

Also con: additional complexity and maintenance burden. Not necessarily a show-stopper, but something to think about: how do you implement these things as simply as possible?

LourensVeen avatar Jul 20 '23 11:07 LourensVeen

I saw that @cwmeijer was already experimenting with this in https://github.com/dianna-ai/distance_explainer/pull/7/files. Reviewing that commit in this thread (just to display some blatant violation of best practices of basic communication, let alone collaborative development :D), I would say it would be very much preferable if there were still only one job definition and the dependencies could be defined on the matrix-element level within that job... Is that an option? Then maintenance burden would be minimal.

Edit: I see now that Chris already mentioned that PR himself, d'oh. Talk about blatant violations of best practices of basic communication :D

egpbos avatar Jul 20 '23 13:07 egpbos

Note that https://github.com/NLeSC/GREEN/issues/24 lists another bunch of cool ideas. I'm all for implementing these here as well. The maintainability is a concern, so we should document things well (maybe just in inline comments?).

egpbos avatar Jul 27 '23 16:07 egpbos

A single job definition would absolutely be favorable. I don't know how to do that though. Suggestions are very welcome.

cwmeijer avatar Aug 03 '23 14:08 cwmeijer

To keep things simple, we could also just set fail-fast to true. This will still start running the other matrix jobs, but will kill them as soon as one fails. It's not perfect, in terms of green-ness, but I think a pretty good compromise with maintainability?

egpbos avatar Oct 20 '23 12:10 egpbos

Solved by #551. Please reopen if needed.

fdiblen avatar Aug 26 '24 14:08 fdiblen