From 8556e11686aba6235046bc934ec318cce8f030fc Mon Sep 17 00:00:00 2001 From: Matt Fisher Date: Tue, 25 Jun 2024 12:33:56 -0600 Subject: [PATCH 01/10] Init PR template --- .github/pull_request_template.md | 36 ++++++++++++++++++++++++++++++++ docs/contributing/index.md | 19 +++-------------- 2 files changed, 39 insertions(+), 16 deletions(-) create mode 100644 .github/pull_request_template.md diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md new file mode 100644 index 00000000..6394a631 --- /dev/null +++ b/.github/pull_request_template.md @@ -0,0 +1,36 @@ +
PR draft checklist + +Please start by opening this Pull Request as a "draft". You can do this by clicking the +arrow on the right side of the green "Create pull request" button. + +- [ ] Please review our + [contributing documentation](https://earthaccess.readthedocs.io/en/latest/contributing/) + before getting started. +- [ ] Ensure an issue exists representing the problem being solved in this PR. +- [ ] Link any issues resolved by this PR with text in the PR description, for example + `closes #1`. +- [ ] Update `CHANGELOG.md` with details about your change in a section titled + `## Unreleased`. If such a section does not exist, please create one. +- [ ] Update the documentation and/or the `README.md` with details of changes to the + interface. This includes new environment variables, function names, decorators, + etc. + +Click the "Ready for review" button at the bottom of the "Conversation" tab in GitHub +once these requirements are fulfilled. Don't worry if you see any test failures in +GitHub at this point! + +
+ +
PR merge checklist + +Please do your best to complete these requirements! If you need help with any of these +requirements, you can ping the `@nsidc/earthaccess-support` team in a comment and we +will help you out! + +- [ ] Add unit tests for any new features. +- [ ] Apply formatting and linting autofixes. You can add a GitHub comment in this Pull + Request containing "pre-commit.ci autofix" to automate this. +- [ ] Ensure all automated PR checks (seen at the bottom of the "conversation" tab) pass. +- [ ] Get at least one approving review. + +
diff --git a/docs/contributing/index.md b/docs/contributing/index.md index 3d149637..b0f24a1b 100644 --- a/docs/contributing/index.md +++ b/docs/contributing/index.md @@ -66,21 +66,8 @@ We have included type stubs for the untyped `python-cmr` library, which we intend to eventually upstream. Since `python-cmr` exposes the `cmr` package, the stubs appear under `stubs/cmr`. -### Requirements to merge code (Pull Request Process) - -- you must include test coverage -- you must update the documentation -- you must format and lint - ## Pull Request process -1. Ensure you include test coverage for all changes -1. Ensure your code is formatted properly following this document -1. Update the documentation and the `README.md` with details of changes to the - interface, this includes new environment variables, function names, - decorators, etc. -1. Update `CHANGELOG.md` with details about your change in a section titled - `Unreleased`. If one does not exist, please create one. -1. You may merge the Pull Request once you have the sign-off of another - developer, or if you do not have permission to do that, you may request the - reviewer to merge it for you. +Fork the repository using the "Fork" button on the [repository +homepage](https://github.com/nsidc/earthaccess), make your change on the fork, then open +a pull request from your fork and follow the instructions populated in the text box. From 47a1366f797ed1dc6deecf3e22fed9224f49e06c Mon Sep 17 00:00:00 2001 From: Matt Fisher Date: Tue, 25 Jun 2024 12:49:07 -0600 Subject: [PATCH 02/10] Clarify the instructional text in the PR template --- .github/pull_request_template.md | 42 +++++++++++++++++++++++--------- 1 file changed, 30 insertions(+), 12 deletions(-) diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md index 6394a631..5b2df6f3 100644 --- a/.github/pull_request_template.md +++ b/.github/pull_request_template.md @@ -1,27 +1,45 @@ -
PR draft checklist - -Please start by opening this Pull Request as a "draft". You can do this by clicking the -arrow on the right side of the green "Create pull request" button. - + + + + +
Pull Request (PR) draft checklist - click to expand + +- [ ] Populate a descriptive title. Ensure the title does not look like "Updated + README.md". +- [ ] Populate the body of the pull request with : + - A clear description of the change you are proposing. + - Links to any issues resolved by this PR with text in the PR description, for + example "closes #1". - [ ] Please review our [contributing documentation](https://earthaccess.readthedocs.io/en/latest/contributing/) before getting started. - [ ] Ensure an issue exists representing the problem being solved in this PR. -- [ ] Link any issues resolved by this PR with text in the PR description, for example - `closes #1`. - [ ] Update `CHANGELOG.md` with details about your change in a section titled `## Unreleased`. If such a section does not exist, please create one. - [ ] Update the documentation and/or the `README.md` with details of changes to the interface. This includes new environment variables, function names, decorators, etc. - -Click the "Ready for review" button at the bottom of the "Conversation" tab in GitHub -once these requirements are fulfilled. Don't worry if you see any test failures in -GitHub at this point! +- [ ] Click the "Ready for review" button at the bottom of the "Conversation" tab in GitHub + once these requirements are fulfilled. Don't worry if you see any test failures in + GitHub at this point!
-
PR merge checklist +
Pull Request (PR) merge checklist - click to expand Please do your best to complete these requirements! If you need help with any of these requirements, you can ping the `@nsidc/earthaccess-support` team in a comment and we From f529c35cc18434c2223c12207a45b61e6eb3658b Mon Sep 17 00:00:00 2001 From: Matt Fisher Date: Tue, 25 Jun 2024 12:49:28 -0600 Subject: [PATCH 03/10] Fix Unreleased section in CHANGELOG to be compatible with our bumpversion config --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index c5ee95ac..a0cc813c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,6 @@ # Changelog -## [Unreleased] +## Unreleased ### Changed From 91e559990659fa77e1bc68452f8bbde220e292ee Mon Sep 17 00:00:00 2001 From: Matt Fisher Date: Sat, 6 Jul 2024 11:19:06 -0600 Subject: [PATCH 04/10] Clarify "descriptive title" task Co-Authored-By: danielfromearth --- .github/pull_request_template.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md index 5b2df6f3..8971a273 100644 --- a/.github/pull_request_template.md +++ b/.github/pull_request_template.md @@ -18,8 +18,8 @@ the PR as a non-draft, don't worry, you can still change it to a draft using the
Pull Request (PR) draft checklist - click to expand -- [ ] Populate a descriptive title. Ensure the title does not look like "Updated - README.md". +- [ ] Populate a descriptive title. For example, instead of "Updated README.md", use a + title such as "Add testing details to the contributor section of the README". - [ ] Populate the body of the pull request with : - A clear description of the change you are proposing. - Links to any issues resolved by this PR with text in the PR description, for From f058822173cce6cbfa03edb5def895352b6fd1f8 Mon Sep 17 00:00:00 2001 From: Matt Fisher Date: Sat, 6 Jul 2024 11:25:58 -0600 Subject: [PATCH 05/10] Move items that belong at the top of the checklist to the top Co-Authored-By: danielfromearth --- .github/pull_request_template.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md index 8971a273..40f3938e 100644 --- a/.github/pull_request_template.md +++ b/.github/pull_request_template.md @@ -18,16 +18,16 @@ the PR as a non-draft, don't worry, you can still change it to a draft using the
Pull Request (PR) draft checklist - click to expand +- [ ] Please review our + [contributing documentation](https://earthaccess.readthedocs.io/en/latest/contributing/) + before getting started. +- [ ] Ensure an issue exists representing the problem being solved in this PR. - [ ] Populate a descriptive title. For example, instead of "Updated README.md", use a title such as "Add testing details to the contributor section of the README". - [ ] Populate the body of the pull request with : - A clear description of the change you are proposing. - Links to any issues resolved by this PR with text in the PR description, for example "closes #1". -- [ ] Please review our - [contributing documentation](https://earthaccess.readthedocs.io/en/latest/contributing/) - before getting started. -- [ ] Ensure an issue exists representing the problem being solved in this PR. - [ ] Update `CHANGELOG.md` with details about your change in a section titled `## Unreleased`. If such a section does not exist, please create one. - [ ] Update the documentation and/or the `README.md` with details of changes to the From d5c5aaa8f964df8e129af71f30f3e6390197668b Mon Sep 17 00:00:00 2001 From: Matt Fisher Date: Sat, 6 Jul 2024 11:32:29 -0600 Subject: [PATCH 06/10] Clarify expectations for maintainer attention Co-Authored-By: Ian Carroll --- .github/pull_request_template.md | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md index 40f3938e..2c8ec43c 100644 --- a/.github/pull_request_template.md +++ b/.github/pull_request_template.md @@ -10,9 +10,12 @@ expect you to complete the steps in the "PR draft checklist" below. Maintainers willing and ready to help pick it up from there! Please start by opening this Pull Request as a "draft". You can do this by -clicking the arrow on the right side of the green "Create pull request" button. Follow -the draft checklist below to move the PR out of draft state. If you accidentally created -the PR as a non-draft, don't worry, you can still change it to a draft using the +clicking the arrow on the right side of the green "Create pull request" button. While +your pull request is in "draft" state, maintainers will assume the PR isn't ready for +their attention unless they are specifically summoned using GitHub's @ system. + +Follow the draft checklist below to move the PR out of draft state. If you accidentally +created the PR as a non-draft, don't worry, you can still change it to a draft using the "Convert to draft" button on the right side panel under the "Reviewers" section. --> From 7e34898e2dded37f526532730e320b86cceb59c1 Mon Sep 17 00:00:00 2001 From: Matt Fisher Date: Sat, 6 Jul 2024 11:33:55 -0600 Subject: [PATCH 07/10] Un-checkbox "ready for review" instructions Co-Authored-By: Ian Carroll --- .github/pull_request_template.md | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md index 2c8ec43c..71a136f6 100644 --- a/.github/pull_request_template.md +++ b/.github/pull_request_template.md @@ -36,9 +36,10 @@ created the PR as a non-draft, don't worry, you can still change it to a draft u - [ ] Update the documentation and/or the `README.md` with details of changes to the interface. This includes new environment variables, function names, decorators, etc. -- [ ] Click the "Ready for review" button at the bottom of the "Conversation" tab in GitHub - once these requirements are fulfilled. Don't worry if you see any test failures in - GitHub at this point! + +Click the "Ready for review" button at the bottom of the "Conversation" tab in GitHub +once these requirements are fulfilled. Don't worry if you see any test failures in +GitHub at this point!
From 3cb282b877cdc603872c1b502224a0e6b4bcb47b Mon Sep 17 00:00:00 2001 From: Matt Fisher Date: Sat, 6 Jul 2024 11:34:13 -0600 Subject: [PATCH 08/10] Clarify draft PR instructions --- .github/pull_request_template.md | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md index 71a136f6..60c23104 100644 --- a/.github/pull_request_template.md +++ b/.github/pull_request_template.md @@ -27,15 +27,16 @@ created the PR as a non-draft, don't worry, you can still change it to a draft u - [ ] Ensure an issue exists representing the problem being solved in this PR. - [ ] Populate a descriptive title. For example, instead of "Updated README.md", use a title such as "Add testing details to the contributor section of the README". -- [ ] Populate the body of the pull request with : +- [ ] Populate the body of the pull request with: - A clear description of the change you are proposing. - Links to any issues resolved by this PR with text in the PR description, for - example "closes #1". + example `closes #1`. See + [GitHub docs - Linking a pull request to an issue](https://docs.github.com/en/issues/tracking-your-work-with-issues/linking-a-pull-request-to-an-issue). - [ ] Update `CHANGELOG.md` with details about your change in a section titled `## Unreleased`. If such a section does not exist, please create one. - [ ] Update the documentation and/or the `README.md` with details of changes to the - interface. This includes new environment variables, function names, decorators, - etc. + earthaccess interface, if any. Consider new environment variables, function names, + decorators, etc. Click the "Ready for review" button at the bottom of the "Conversation" tab in GitHub once these requirements are fulfilled. Don't worry if you see any test failures in From 805c65598437ba81344a733ed4c449d8b760e40c Mon Sep 17 00:00:00 2001 From: Matt Fisher Date: Sat, 6 Jul 2024 11:43:19 -0600 Subject: [PATCH 09/10] Make PR instructions clearer and more welcoming Co-authored-by: Ian Carroll --- docs/contributing/index.md | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/docs/contributing/index.md b/docs/contributing/index.md index b0f24a1b..fc39f629 100644 --- a/docs/contributing/index.md +++ b/docs/contributing/index.md @@ -69,5 +69,6 @@ the stubs appear under `stubs/cmr`. ## Pull Request process Fork the repository using the "Fork" button on the [repository -homepage](https://github.com/nsidc/earthaccess), make your change on the fork, then open -a pull request from your fork and follow the instructions populated in the text box. +homepage](https://github.com/nsidc/earthaccess), create a branch with your changes in the fork, then open +a draft pull request from your fork. Starting a pull request provides additional instructions and requirements, and +there is no harm in starting a draft pull request while still developing. From 728eb17e52738f62dcd08d86093da7fa7bde1a3d Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Sat, 6 Jul 2024 18:57:36 +0000 Subject: [PATCH 10/10] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- docs/contributing/maintainers-guide.md | 3 --- 1 file changed, 3 deletions(-) diff --git a/docs/contributing/maintainers-guide.md b/docs/contributing/maintainers-guide.md index 1ac2fc79..2d54a354 100644 --- a/docs/contributing/maintainers-guide.md +++ b/docs/contributing/maintainers-guide.md @@ -53,6 +53,3 @@ The GitHub Actions CI services handle the project's building, testing, and manag ## Continuous Documentation [ReadTheDocs](https://readthedocs.org/projects/earthaccess/) is used to generate and host [our documentation website](https://earthaccess.readthedocs.io/) as well as the preview for documentation changes made in pull requests. This service uses a configuration file in the root of the project, `.readthedocs.yml`. - - -