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

CI: add scheduled testing against nightlies #2376

Merged
merged 1 commit into from
Apr 29, 2024

Conversation

rcomer
Copy link
Member

@rcomer rcomer commented Apr 26, 2024

Rationale

This PR removes shapely-dev from the CI test matrix and instead introduces monthly testing against the Shapely, SciPy and Matplotlib nightly builds (note Numpy and ContourPy nightlies are automatically pulled in with Matplotlib).

The guidance from Scientific Python recommends a weekly job for this. At #2371 (comment), @greglucas suggested a monthly job. I also lean towards monthly just because Cartopy doesn't have a lot of resource so with a more frequent run we probably would end up closing lots of duplicate issues that we didn't get around to looking at yet. The choice of 10th of the month is pretty arbitrary but it seems good to move it away from the beginning of the month so we aren't bothered by it on New Year's Day! I also added a workflow-dispatch trigger so we can run it if and when we have any reason to worry about recent updates in any package.

For the approach I roughly followed Matplotlib's workflow. It feels a little excessive to run the whole matrix but I couldn't find a neat way to restrict it for just these workflow triggers. I took the command to install the nightlies from the Scientific Python page. It's a little different from what Matplotlib does, and what's recommended in Matplotlib's installation documentation but I don't know the reason for the difference or how to choose between them.

Implications

@rcomer rcomer marked this pull request as draft April 26, 2024 20:46
@rcomer

This comment was marked as resolved.

@rcomer rcomer force-pushed the ci-nightly-tests branch 2 times, most recently from 663f7e4 to aa272cf Compare April 27, 2024 07:50
@rcomer
Copy link
Member Author

rcomer commented Apr 27, 2024

I now have a run that demonstrates installing nightlies of all five expected packages: https://github.com/rcomer/cartopy/actions/runs/8858366152

I have also learned that if you still get failures after re-spin, you get duplicate issues: rcomer#12, rcomer#13, rcomer#14. I think the flakiness of our tests is another good reason to keep the schedule fairly low frequency.

@rcomer rcomer marked this pull request as ready for review April 27, 2024 08:23
Copy link
Contributor

@greglucas greglucas left a comment

Choose a reason for hiding this comment

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

Looks good, and I agree monthly seems like the right cadence for now.


# Separate dependent job to only upload one issue from the matrix of jobs
create-issue:
if: ${{ failure() && (github.event_name == 'schedule' || github.event_name == 'workflow_dispatch') }}
Copy link
Contributor

Choose a reason for hiding this comment

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

Do we want workflow_dispatch to upload an issue as well, or just the scheduled run?

Copy link
Member Author

Choose a reason for hiding this comment

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

Fair point. I guess if you've done workflow_dispatch then you are actively looking at it and don't need the issue.

@rcomer rcomer force-pushed the ci-nightly-tests branch from aa272cf to b14a31e Compare April 28, 2024 15:19
@greglucas greglucas merged commit d57166c into SciTools:main Apr 29, 2024
24 checks passed
@QuLogic QuLogic added this to the Next Release milestone Apr 29, 2024
@rcomer rcomer deleted the ci-nightly-tests branch April 29, 2024 16:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants