Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion .github/workflows/build_package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: [ '3.9', '3.10' ]
python-version: [ '3.9', '3.10', '3.11', '3.12' ]

steps:
- uses: actions/checkout@v4
Expand All @@ -36,6 +36,9 @@ jobs:
./build.sh
- name: Test Package Install
run: |
CONDA_BASE=$(conda info --base)
source "${CONDA_BASE}/etc/profile.d/conda.sh"
conda activate coast
python -m pip install dist/coast-*.tar.gz
- name: Generate Conda Metadata
run: |
Expand Down
6 changes: 5 additions & 1 deletion .github/workflows/unit_test_contents.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,11 @@ jobs:
python-version: ${{ matrix.python-version }}
- name: Generate contents.
run: |
pip install .
CONDA_BASE=$(conda info --base)
source "${CONDA_BASE}/etc/profile.d/conda.sh"
conda env update --prune --file environment.yml
conda activate coast
pip install .
mkdir -p example_files
sudo apt-get update
sudo apt-get install -y libgeos-dev
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/verify_package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: [ '3.9', '3.10' ]
python-version: [ '3.9', '3.10', '3.11', '3.12' ]

steps:
- uses: actions/checkout@v4
Expand All @@ -34,6 +34,7 @@ jobs:
run: |
CONDA_BASE=$(conda info --base)
source "${CONDA_BASE}/etc/profile.d/conda.sh"
conda config --set verbosity 3 --env
conda env update --prune --file environment.yml
conda activate coast
sudo apt-get update
Expand Down
7 changes: 5 additions & 2 deletions build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@ mkdir -p build dist
echo "Cleaning up old versions..."
rm -rf ./build/* ./dist/* ./Example_Python_Package.egg-info
echo "Building package for distribution..."
./venv/bin/python ./setup.py sdist bdist_wheel
CONDA_BASE=$(conda info --base)
source "${CONDA_BASE}/etc/profile.d/conda.sh"
conda activate coast
python ./setup.py sdist bdist_wheel

echo "Done!"
echo "Done!"
4 changes: 2 additions & 2 deletions environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ channels:
- nodefaults
dependencies:
- python==3.10
- cython==3.1.1
- cython==0.29.37
- cartopy==0.23.0
- gsw==3.6.19
- xarray[complete]==2023.7.0
Expand All @@ -31,5 +31,5 @@ dependencies:
- spyder==6.0.7
- jupyterlab==4.4.3
- aiohttp==3.11.13
- PyYAML==6.0
- PyYAML==5.4.1
- oyaml==1.0
4 changes: 3 additions & 1 deletion generate_conda_meta.sh
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
#!/bin/bash

CONDA_BASE=$(conda info --base)
source "${CONDA_BASE}/etc/profile.d/conda.sh"
conda activate coast
python setup.py conda
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
[tool.black]
line-length = 120
target-version = ['py38', 'py39', 'py310']
target-version = ['py38', 'py39', 'py310']
6 changes: 3 additions & 3 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,8 @@
"keywords": ["NEMO", "shallow water", "ocean assessment"],
"project_urls": {"documentation": "https://british-oceanographic-data-centre.github.io/COAsT/"},
"install_requires": [
"PyYAML==6.0",
"cython==0.29.37",
"PyYAML==5.4.1",
"oyaml==1.0",
"pytest==7.1.1",
"pytest-mock==3.7.0",
Expand All @@ -53,7 +54,6 @@
"aiohttp==3.11.13",
"tqdm==4.67.1",
"pyproj==3.6.1",
"cython==3.1.1",
"cartopy==0.23.0",
"h5py==3.6.0",
"zarr==2.18.2",
Expand All @@ -63,7 +63,7 @@
# "xesmf>=0.3.0", # Optional. Not part of main package
# "esmpy>=8.0.0", # Optional. Not part of main package
],
"python_requires": ">3.8,<3.11",
"python_requires": ">3.8,<3.13",
"packages": ["coast", "coast.data", "coast._utils", "coast.diagnostics"],
"include_package_data": True,
"github": "British-Oceanographic-Data-Centre",
Expand Down
7 changes: 2 additions & 5 deletions setup_environment.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,10 @@ cd "$(dirname "$0")" # Set working directory

echo "Cleaning up any existing virtual environment..."
rm -rf ./venv
echo "Creating new virtual environment..."
python3 -m virtualenv ./venv
echo "Installing required packages..."
./venv/bin/pip install setuptools wheel twine
CONDA_BASE=$(conda info --base)
source "${CONDA_BASE}/etc/profile.d/conda.sh"
conda env update --prune --file environment.yml
conda activate coast
conda install -c conda-forge cython setuptools wheel twine

echo "Done!"
echo "Done!"
Loading