Development¶
This page contains all the information necessary to setup a local development environment.
Contribution¶
All contributions are welcome!
Please create a new discussion or issue within the github repository for any questions, ideas and suggestions.
Installation¶
Clone the project locally
We recommend using poetry to manage the environment and pyenv to manage the python version:
Install poetry python environment with:
Go to the project directory and install dependancies in a poetry environment.
Testing¶
The package use pytest to run a series of tests in order to help the development of the different aspect of the package. Within a developping environment, to run the different tests, run the pytest commmand through your terminal within the base directory of the repository. Pytest can also be integrated with different IDE and is run on any pushes and PR to the main
and development
branches.
Parsers Tests¶
The package contains a number of different parsers compatible with different standard file formats. Each parser is tested on a series of test files made available within the test file directory The different tests executed on each individual parsers can be subdivided in 3 main categories:
- Parse test file to an xarray dataset
- Parse test file to an xarray dataset and save to a NetCDF4 file.
- Parse test file to an xarray dataset and compare to a reference file ('*_reference.nc) if made available. Any differences are flagged
- (in development) Assess parsed xarray object compliance with the different convention by using the ioos-compliance checker, resulting objects should be to a minimum compliante to ACDD 1.3 and CF 1.6. Other conventions can be added by adding them to the xarray object global attribute
Convention
.
Documentation Build¶
To run a local instance of the documentation webpage. Install the dependancies:
And run the command:
Any documentation changes to the main and development branches will automatically update respectively the main and dev document pages.