@@ -93,6 +93,8 @@ Bug reports and feature requests
9393Bug reports and feature requests can be submitted to https://github.com/USEPA/WNTR/issues.
9494The core development team will prioritize and assign bug reports and feature requests to team members.
9595
96+ .. _contributing :
97+
9698Contributing
9799---------------------
98100Software developers, within the core development team and external collaborators,
@@ -101,6 +103,8 @@ Software developers interested in contributing to the project are encouraged to
101103create a `Fork ` of the project and submit a `Pull Request ` using GitHub.
102104Pull requests will be reviewed by the core development team.
103105
106+ Pull requests
107+ ^^^^^^^^^^^^^
104108Pull requests can be made to the **main ** or **dev ** (development) branch.
105109Developers can discuss new features and the appropriate branch for contributing
106110by opening a new issue on https://github.com/USEPA/WNTR/issues.
@@ -115,6 +119,35 @@ Pull requests must meet the following minimum requirements to be included in WNT
115119
116120* Network model files will not be duplicated in the repository. Network files are stored in examples/network and wntr/tests/networks_for_testing only.
117121
122+ Extensions
123+ ^^^^^^^^^^
124+ WNTR extensions are intended to house beta and self-contained functionality that adds to WNTR.
125+ Developers interested in contributing to WNTR extensions should communicate with the core development team
126+ through https://github.com/USEPA/WNTR/issues prior to submitting a pull request.
127+ See :ref: `extensions ` for a list of current WNTR extensions.
128+
129+ Extensions adhere to the following file structure:
130+
131+ * **Source code **: Source code files (*.py) associated with the extension, with the exception of documentation and testing,
132+ reside in a folder named ``wntr\e xtensions\< extension_name>``. The folder contains an ``__int__.py`` file to import the extension.
133+ * **Documentation* *: Documentation resides in a file named ``documentation\extensions\<extension_name>.rst ``.
134+ The documentation page should include
135+ 1) a high level summary of the extension,
136+ 2) a point of contact (developer name and GitHub username), and
137+ 3) supporting documentation and examples (using doctest).
138+ A link to the documentation should also be added to ``documentation\extensions.rst `` and ``documentation\userguide.rst ``.
139+ * **Testing **: Tests are run using the `extensions workflow <https://github.com/USEPA/WNTR/tree/main/.github/workflows/extensions.yml >`_.
140+ Tests reside in a file named ``wntr\tests\extensions\test_<extension_name>.py ``.
141+ Tests should be marked ``@pytest.mark.extensions ``.
142+ * **Requirements **: If the extension requires packages beyond WNTR's core dependencies, add a corresponding entry to
143+ ``extras_require `` in ``setup.py ``. Users can then install the extension's dependencies with ``pip install wntr[<extension_name>] ``.
144+
145+ .. note ::
146+ While documentation is required for extensions, the documentation is not included in the
147+ `WNTR EPA Report <https://cfpub.epa.gov/si/si_public_record_report.cfm?Lab=NHSRC&dirEntryID=337793 >`_.
148+ Documentation for extensions is only available online.
149+ Extensions that have long-term test failures will be removed from the repository.
150+
118151Software release
119152------------------
120153The software release process requires administrative privileges and knowledge about the external services used in the release process.
0 commit comments