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 the "Doctests" workflow to run doctests weekly #2456

Merged
merged 15 commits into from
Apr 12, 2023
Merged

Conversation

seisman
Copy link
Member

@seisman seisman commented Mar 23, 2023

Description of proposed changes

Add a new workflow "ci_doctests.yaml" to run all doctests. This workflow is scheduled to run weekly on Sunday.

Fixes #2286.

Reminders

  • Run make format and make check to make sure the code follows the style guide.
  • Add tests for new features or tests that would have caught the bug that you're fixing.
  • Add new public functions/methods/classes to doc/api/index.rst.
  • Write detailed docstrings for all functions/methods.
  • If wrapping a new module, open a 'Wrap new GMT module' issue and submit reasonably-sized PRs.
  • If adding new functionality, add an example to docstrings or tutorials.
  • Use underscores (not hyphens) in names of Python files and directories.

Slash Commands

You can write slash commands (/command) in the first line of a comment to perform
specific operations. Supported slash commands are:

  • /format: automatically format and lint the code
  • /test-gmt-dev: run full tests on the latest GMT development version

@seisman seisman added the maintenance Boring but important stuff for the core devs label Mar 23, 2023
@seisman seisman modified the milestones: 0.9.0, 0.10.0 Mar 23, 2023
@seisman seisman marked this pull request as ready for review March 26, 2023 08:25
@@ -79,8 +79,7 @@ There are 11 configuration files located in `.github/workflows`:
2. `ci_tests.yaml` (Tests on Linux/macOS/Windows)
Copy link
Member Author

@seisman seisman Mar 26, 2023

Choose a reason for hiding this comment

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

Off-topic question: Currently, we're documenting what a workflow does in the maintainers' guide, but it's very likely that we may forget to update the guides when we make changes to a workflow.

Perhaps we should only keep a short, one-sentence description for each workflow in the maintainers' guide and put a much longer description in the workflow file.

Copy link
Member Author

Choose a reason for hiding this comment

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

Ping @GenericMappingTools/pygmt-maintainers for comments on this.

Copy link
Member

Choose a reason for hiding this comment

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

Maybe have a README.md under https://github.com/GenericMappingTools/pygmt/tree/v0.9.0/.github/workflows to document, so that people looking at the folder can see what the *.yml files are for? Also fine with including it in the YAML file since that will be more visible.

Copy link
Member Author

Choose a reason for hiding this comment

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

Also fine with including it in the YAML file since that will be more visible.

I'm inclined to this option because (1) we won't forget to update the workflow descriptions; (2) the workflows are more self-explanatory.

Copy link
Member

Choose a reason for hiding this comment

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

Also fine with including it in the YAML file since that will be more visible.

I'm inclined to this option because (1) we won't forget to update the workflow descriptions; (2) the workflows are more self-explanatory.

Ok, so just document things in the YAML files and remove the descriptions from the doc/maintenance.md file. Can do this in another PR once this one is merged.

@seisman seisman added the needs review This PR has higher priority and needs review. label Apr 7, 2023
@seisman seisman requested a review from weiji14 April 9, 2023 00:43
@@ -79,8 +79,7 @@ There are 11 configuration files located in `.github/workflows`:
2. `ci_tests.yaml` (Tests on Linux/macOS/Windows)
Copy link
Member

Choose a reason for hiding this comment

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

Maybe have a README.md under https://github.com/GenericMappingTools/pygmt/tree/v0.9.0/.github/workflows to document, so that people looking at the folder can see what the *.yml files are for? Also fine with including it in the YAML file since that will be more visible.

doc/maintenance.md Outdated Show resolved Hide resolved
.github/workflows/ci_doctests.yaml Outdated Show resolved Hide resolved
Copy link
Member

@weiji14 weiji14 left a comment

Choose a reason for hiding this comment

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

Almost ready I think, just need to comment the pull_request: line and fix the typo.

@@ -79,8 +79,7 @@ There are 11 configuration files located in `.github/workflows`:
2. `ci_tests.yaml` (Tests on Linux/macOS/Windows)
Copy link
Member

Choose a reason for hiding this comment

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

Also fine with including it in the YAML file since that will be more visible.

I'm inclined to this option because (1) we won't forget to update the workflow descriptions; (2) the workflows are more self-explanatory.

Ok, so just document things in the YAML files and remove the descriptions from the doc/maintenance.md file. Can do this in another PR once this one is merged.

@weiji14 weiji14 added final review call This PR requires final review and approval from a second reviewer and removed needs review This PR has higher priority and needs review. labels Apr 12, 2023
Co-authored-by: Wei Ji <23487320+weiji14@users.noreply.github.com>
doc/maintenance.md Outdated Show resolved Hide resolved
Co-authored-by: Michael Grund <23025878+michaelgrund@users.noreply.github.com>
@seisman seisman merged commit e799cc6 into main Apr 12, 2023
@seisman seisman deleted the workflow-doctests branch April 12, 2023 07:06
@seisman seisman removed the final review call This PR requires final review and approval from a second reviewer label Apr 12, 2023
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
maintenance Boring but important stuff for the core devs
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Run full tests (including inline doctests) in workflows
3 participants