DEEPDIP-project / CoupledNODE.jl

Apache License 2.0
2 stars 0 forks source link

Implement git hooks to create markdowns and notebooks #13

Closed SCiarella closed 3 months ago

SCiarella commented 3 months ago

Also test if the notebooks can be automatically executed.

luisaforozco commented 3 months ago

Would we like this to be:

Also, is the check of notebooks running necessary? Maybe we can check that examples/*.jl run without problems. A think to keep into consideration is that the notebooks do not run super-fast.

APJansen commented 3 months ago

I prefer pre-commits as having tons of auto generated commits after pushing I think interferes more with our workflow. If you push some changes, then make some more commits and push again, you may get conflicts if in the mean time there has been an automatic commit.

In my other projects I am using precommit for formatting. In case you are not all familiar, the way this works is that every time you try to commit something, it checks the formatting and if anything is wrong, it makes the changes automatically but doesn't stage or commit them. So in practice instead of just committing, you'll have to commit, stage again after automatic changes, and commit again.

I can set that up here for the formatting, and then also add the generation of the notebooks, that only takes like a second.

The only danger I see with this is that if you make changes to a notebook rather than the code that generates it, it will get overwritten.

SCiarella commented 3 months ago

pre-commits sounds awesome! Also, I don't think it is a problem if the markdowns or the notebooks get overwritten.

My question is instead the following: does it make sense to have notebooks that are not executed while we also have markdown files? Maybe for now we can avoid executing them and think about this later, when we build a better documentation.

APJansen commented 3 months ago

You mean because the main advantage of aa notebook over markdown is that it would have all the results displayed when it's been run? Makes sense. Running them would be quite expensive though. I agree let's worry about that later.