Skip to content

Commit

Permalink
add .github workflow and update basic info on the project
Browse files Browse the repository at this point in the history
  • Loading branch information
aerorahul committed Jul 1, 2023
1 parent ecb78f9 commit 00a8338
Show file tree
Hide file tree
Showing 9 changed files with 266 additions and 15 deletions.
54 changes: 54 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
---
name: Bug report
about: Create a report to help us improve
title:
labels: bug
assignees:

---

<!--
This bug report template is to be used by developers to report issues
encountered within the development branches and releases.
-->

<!--
Please remove unwanted/unrelated/irrelevant information such as comments.
Use proper formatting to separate code snippets from text description.
Please copy any output files into a Github gist (for e.g.) and link to the gist, rather than relying on paths that might change.
-->

Your bug may already be reported!
Please search on the [Issue tracker](https://github.com/NOAA-EMC/wxflow/issues) before creating one.
<!--
Please look through the existing issues to see if this bug has been reported and an Issue has been created.
If so, please consider using that Issue to add any additional information.
-->

**Expected behavior**
<!-- Tell us what should happen. -->

**Current behavior**
<!-- Tell us what happens instead of the expected behavior. -->

**Machines affected**
<!-- Tell us which HPC environments have this bug been detected. -->

**To Reproduce**
<!--- Provide a link to a live example, and/or an unambiguous set of steps to -->
<!--- reproduce this bug. Include code to reproduce, if relevant -->
<!--1. -->
<!--2. -->
<!--3. -->

**Context**
<!--- Providing context helps us come up with a solution that is most useful in the real world. -->

**Detailed Description**
<!--- Provide a detailed description of the change or addition you are proposing. -->

**Additional Information**
<!-- Any other relevant information that we should know to correctly understand and reproduce the issue. Please describe in as much detail as possible. -->

**Possible Implementation**
<!--- Not obligatory, but suggest an idea for implementing addition or change. -->
41 changes: 41 additions & 0 deletions .github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
---
name: Feature Request
about: Use this template for requesting new features
title:
labels: feature
assignees:

---


<!--
Please look through the existing issues to see if this issue has been created.
If so, please consider using that Issue to add any additional information.
-->

<!--
Please remove unwanted/unrelated/irrelevant information such as comments.
Use proper formatting to separate code snippets from text description.
Please copy any output files into a Github gist (for e.g.) and link to the gist, rather than relying on paths that might change.
-->

**Description**
<!-- Provide a consise description of the problem to be addressed by this feature request. -->
<!-- Please be clear what parts of the problem are considered to be in-scope and out-of-scope -->
<!-- Please describe if this new feature will introduce additional python module dependencies. Adding a new python dependency should be its own separate issue before this feature will be accepted for development. -->

**Requirements**
<!-- What does the new code need to accomplish? -->

**Acceptance Criteria (Definition of Done)**
<!-- What does it mean for this to be finished? -->

**(Optional): Suggest A Solution**
<!--
A concise description of your preferred solution. Things to address include:
* Details of the technical implementation
* Tradeoffs made in design decisions
* Caveats and considerations for the future
If there are multiple solutions, please present each one separately. Save comparisons for the very end.)
-->
41 changes: 41 additions & 0 deletions .github/ISSUE_TEMPLATE/general_issue.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
---
name: General Issue
about: Use this template for general issues
title:
labels:
assignees:

---


If this is a bug, please consider using the [Bug Report](./bug_report.md) template.
Your issue may already have been created!
Please search on the [Issue tracker](https://github.com/NOAA-EMC/wxflow/issues) before creating one.
<!--
Please look through the existing issues to see if this issue has been created.
If so, please consider using that Issue to add any additional information.
-->

<!--
Please remove unwanted/unrelated/irrelevant information such as comments.
Use proper formatting to separate code snippets from text description.
Please copy any output files into a Github gist (for e.g.) and link to the gist, rather than relying on paths that might change.
-->

**Description**
<!-- Provide a detailed description of this issue. -->
<!-- What problem needs to be fixed? -->
<!-- What new capability needs to be added? -->

**Requirements**
<!-- If this is a new feature: -->
<!-- What does the new code need to accomplish? -->
<!-- If this is a bugfix: What is the expected behavior? -->

**Acceptance Criteria (Definition of Done)**
<!-- What does it mean for this to be finished? -->

**Dependencies**
<!-- What must be done before this can be done? Add issue dependencies as appropriate e.g. depends on #IssueNumber -->
<!-- Does this block progress on other issues? Add this issue as a dependency to other issues as appropriate e.g. #IssueNumber has a dependency on this issue -->
<!-- Does this feature introduce any new python dependencies? If so, please list the name of the dependency and its dependencies explicitly together with what their expected use will be in this feature. -->
48 changes: 48 additions & 0 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
<!-- PLEASE READ -->
<!--
Before opening a PR, please note these guidelines:
- Each PR should only address ONE topic and have an associated issue
- No hardcoded or paths to personal directories should be present
- No temporary or backup files should be committed
- Any code that was disabled by being commented out should be removed
-->

**Description**

<!-- Please include relevant motivation and context. -->
<!-- Please include a summary of the change and which issue is fixed. -->
<!-- List any dependencies that are required for this change. -->

<!-- Please provide reference to the issue this pull request is addressing. -->
<!-- For e.g. Fixes #IssueNumber -->

**Type of change**

Please delete options that are not relevant.

- [ ] Bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
- [ ] This change requires a documentation update

**How Has This Been Tested?**

<!-- Please describe the tests that you ran to verify your changes and on the platforms these tests were conducted. -->
<!-- Provide instructions so we can reproduce. -->
<!-- Please also list any relevant details for your test configuration -->

<!-- Use the following as a guide to list your tests and delete options that are not relevant. Expand as necessary. -->
<!--
- [ ] pytests
-->

**Checklist**

- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my own code
- [ ] I have commented my code, particularly in hard-to-understand areas
- [ ] My changes need updates to the documentation. I have made corresponding changes to the documentation
- [ ] My changes generate no new warnings
- [ ] New and existing tests pass with my changes
- [ ] Any dependent changes have been merged and published
24 changes: 24 additions & 0 deletions .github/workflows/pynorms.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: pynorms
on: [push, pull_request]

jobs:
check_norms:
runs-on: ubuntu-latest
name: Check Python coding norms with pycodestyle

steps:

- name: Install dependencies
run: |
pip install --upgrade pip
pip install pycodestyle
- name: Checkout
uses: actions/checkout@v3
with:
path: global-workflow

- name: Run pycodestyle
run: |
cd $GITHUB_WORKSPACE/global-workflow
pycodestyle -v --config ./.pycodestyle --exclude='.git,.github' ./
36 changes: 36 additions & 0 deletions .github/workflows/pytests.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: pytests
on: [push, pull_request]

jobs:
run_pytests:
runs-on: ubuntu-latest
name: Install pygw and run tests with pytests
strategy:
max-parallel: 1
matrix:
python: ["3.7", "3.8", "3.9", "3.10"]

steps:
- name: Setup Python
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python }}

- name: Install (upgrade) python dependencies
run: |
pip install --upgrade pip
- name: Checkout
uses: actions/checkout@v3
with:
path: global-workflow

- name: Install pygw
run: |
cd $GITHUB_WORKSPACE/global-workflow/ush/python/pygw
pip install .[dev]
- name: Run pytests
run: |
cd $GITHUB_WORKSPACE/global-workflow/ush/python/pygw
pytest -v src/tests
6 changes: 6 additions & 0 deletions .pycodestyle
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
[pycodestyle]
count = False
ignore = E402,W504
max-line-length = 160
statistics = True
exclude = Experimental
18 changes: 9 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
# global workflow specific tools
# Tools for Weather Workflows

Python tools specifically for global applications
Common set of tools used in weather workflows

## Installation
Simple installation instructions
```sh
$> git clone https://github.com/noaa-emc/global-workflow
$> cd global-workflow/ush/python/pygw
$> git clone https://github.com/noaa-emc/wxflow
$> cd wxflow
$> pip install .
```

It is not required to install this package. Instead,
It is not required to install this package. Instead,
```sh
$> cd global-workflow/ush/python/pygw
$> export PYTHONPATH=$PWD/src/pygw
$> cd wxflow
$> export PYTHONPATH=${PWD}/src/wxflow
```
would put this package in the `PYTHONPATH`

Expand All @@ -24,11 +24,11 @@ These instructions will be updated and the tools are under development.
Simple instructions to enable executing pytests manually
```sh
# Create a python virtual environment and step into it
$> cd global-workflow/ush/python/pygw
$> cd wxflow
$> python3 -m venv venv
$> source venv/bin/activate

# Install pygw with the developer requirements
# Install `wxflow` with the developer requirements
(venv) $> pip install .[dev]

# Run pytests
Expand Down
13 changes: 7 additions & 6 deletions setup.cfg
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
[metadata]
name = pygw
name = wxflow
version = 0.0.1
description = Global applications specific workflow related tools
description = Tools for Weather Workflows
long_description = file: README.md
long_description_content_type = text/markdown
author = "NOAA/NWS/NCEP/EMC"
#author_email = first.last@domain.tld
keywords = NOAA, NWS, NCEP, EMC, GFS, GEFS
home_page = https://github.com/noaa-emc/global-workflow
keywords = NOAA, NWS, NCEP, EMC, GFS, GEFS, SFS, RRFS
home_page = https://github.com/noaa-emc/wxflow
license = GNU Lesser General Public License
classifiers =
Development Status :: 1 - Beta
Expand All @@ -22,12 +22,13 @@ classifiers =
Programming Language :: Python :: 3.7
Programming Language :: Python :: 3.8
Programming Language :: Python :: 3.9
Programming Language :: Python :: 3.10
Topic :: Software Development :: Libraries :: Python Modules
Operating System :: OS Independent
Typing :: Typed
project_urls =
Bug Tracker = https://github.com/noaa-emc/global-workflow/issues
CI = https://github.com/noaa-emc/global-workflow/actions
Bug Tracker = https://github.com/noaa-emc/wxflow/issues
CI = https://github.com/noaa-emc/wxflow/actions

[options]
zip_safe = False
Expand Down

0 comments on commit 00a8338

Please sign in to comment.