Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Separate Nightly workflow #488

Merged
merged 1 commit into from Jan 25, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
6 changes: 2 additions & 4 deletions .github/workflows/actions.yml
@@ -1,4 +1,4 @@
name: gh
name: Main

on:
create: # is used for publishing to PyPI and TestPyPI
Expand All @@ -12,13 +12,11 @@ on:
- >-
**
pull_request:
schedule:
- cron: '1 0 * * *' # Run daily at 0:01 UTC

jobs:
build_docs:
name: Build Docs
runs-on: ubuntu-18.04
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- name: Set up Python
Expand Down
9 changes: 9 additions & 0 deletions .github/workflows/nightly.yml
@@ -0,0 +1,9 @@
name: Nightly tests
Copy link
Member

Choose a reason for hiding this comment

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

Out of curiosity, why separate these workflows?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Basically for the same reasons we don't put all python code in one file, logical separation, readability, maintainability, etc.

Which, imo, is especially true for CI config which has a tendency to rarely see changes once defined. So having it logically separated (I will separate out publish to it's own file as well) will help when someone has to make changes.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

For a concrete example: https://github.com/pytest-dev/pytest-html/blob/master/.github/workflows/actions.yml#L36

All these if makes at least my head hurt. Can I wrap my head around it? Sure, but it will take some time. And 6 months later when I need to revisit, I'm going to need to go through that pain again.


on:
schedule:
- cron: '1 0 * * *' # Run daily at 0:01 UTC

jobs:
tests:
uses: pytest-dev/pytest-html/.github/workflows/tests.yml@master