Skip to content

Overhaul CI lesson#6

Open
LiamPattinson wants to merge 3 commits intomainfrom
ci_edits
Open

Overhaul CI lesson#6
LiamPattinson wants to merge 3 commits intomainfrom
ci_edits

Conversation

@LiamPattinson
Copy link
Collaborator

Resolves #5

Opted not to teach branch protection here.

Instead teaches:

  • Getting the basics working
  • Run on pull_request vs push
  • Setting up a job matrix
  • Running only under certain conditions

@github-actions
Copy link

github-actions bot commented Feb 6, 2026

Thank you!

Thank you for your pull request 😃

🤖 This automated message can help you check the rendered files in your submission for clarity. If you have any questions, please feel free to open an issue in {sandpaper}.

If you have files that automatically render output (e.g. R Markdown), then you should check for the following:

  • 🎯 correct output
  • 🖼️ correct figures
  • ❓ new warnings
  • ‼️ new errors

Rendered Changes

🔍 Inspect the changes: https://github.com/ResearchCodingClub/python-testing-for-research/compare/md-outputs..md-outputs-PR-6

The following changes were observed in the rendered markdown documents:

 10-CI.md                               | 324 +++++++++++++++++++++++++--------
 fig/github_action.png (new)            | Bin 0 -> 97368 bytes
 fig/github_actions_button.png (new)    | Bin 0 -> 9092 bytes
 fig/github_repo_view.png (new)         | Bin 0 -> 35113 bytes
 fig/matrix_tests.png (new)             | Bin 0 -> 30443 bytes
 fig/pull_request_test_failed.png (new) | Bin 0 -> 50360 bytes
 files/10-CI/tests.yaml (new)           |  72 ++++++++
 md5sum.txt                             |   2 +-
 8 files changed, 319 insertions(+), 79 deletions(-)
What does this mean?

If you have source files that require output and figures to be generated (e.g. R Markdown), then it is important to make sure the generated figures and output are reproducible.

This output provides a way for you to inspect the output in a diff-friendly manner so that it's easy to see the changes that occur due to new software versions or randomisation.

⏱️ Updated at 2026-02-10 17:40:39 +0000

github-actions bot pushed a commit that referenced this pull request Feb 6, 2026
github-actions bot pushed a commit that referenced this pull request Feb 6, 2026
@LiamPattinson LiamPattinson requested a review from avadean February 6, 2026 19:12
@LiamPattinson
Copy link
Collaborator Author

I've modified this lesson to talk about matrix jobs earlier, and to simplify the push/pull_request section. The exercise to engineer a situation in which push would pass but pull_request wouldn't has been left as the final exercise to the students, so not a huge problem if we run out of time for it.

github-actions bot pushed a commit that referenced this pull request Feb 10, 2026
and add the following contents:

```
pytest
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The "Summary and Setup" section of the course already specifies the requirements, so maybe don't need to mention it here. There's also good reason to leave it in, in the future case people come to the course for this specific module. Just thought I'd mention!

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The inclusion of a requirements.txt here is just so that the CI job has a list of packages to install -- essentially just a poor substitute for a pyproject.toml since we don't have time to teach that here.

@avadean
Copy link
Collaborator

avadean commented Feb 12, 2026

Definitely a tricky concept to teach and create a lesson for - looks great!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Overhaul CI section

2 participants