Skip to content

Commit

Permalink
Merge pull request #60 from FormingWorlds/hn/version
Browse files Browse the repository at this point in the history
Store version in janus.__init__
  • Loading branch information
nichollsh authored Oct 30, 2024
2 parents 8ae28b1 + 119a2e2 commit c8480fc
Show file tree
Hide file tree
Showing 10 changed files with 13 additions and 9 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/publish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
id-token: write

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: actions/setup-python@v4
with:
python-version: '3.12'
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ['3.10', '3.11', '3.12']
python-version: ['3.10', '3.11', '3.12', '3.13']

steps:
- uses: actions/checkout@v4
Expand All @@ -31,7 +31,7 @@ jobs:
repository: 'nichollsh/SOCRATES'
path: 'SOCRATES'

- uses: actions/cache@v3
- uses: actions/cache@v4
id: cache-socrates
with:
path: |
Expand All @@ -54,7 +54,7 @@ jobs:
with:
python-version: ${{ matrix.python-version }}

- uses: actions/cache@v3
- uses: actions/cache@v4
id: cache-virtualenv
with:
path: ${{ env.pythonLocation }}
Expand All @@ -65,7 +65,7 @@ jobs:
run: |
python -m pip install -e .[develop]
- uses: actions/cache@v3
- uses: actions/cache@v4
id: cache-fwl-data
with:
path: /home/runner/work/fwl_data
Expand Down
4 changes: 2 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"

[project]
name = "fwl-janus"
version = "24.09.12"
version = "24.10.30"
description = "Temperature structure generator for planetory atmospheres."
readme = "README.md"
authors = [
Expand Down Expand Up @@ -81,7 +81,7 @@ testpaths = ["tests"]

[tool.bumpversion]
# https://callowayproject.github.io/bump-my-version/howtos/calver/
current_version = "24.09.12"
current_version = "24.10.30"
parse = """(?x) # Verbose mode
(?P<release> # The release part
(?:[1-9][0-9])\\. # YY.
Expand Down
2 changes: 1 addition & 1 deletion requirements_full.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
#
# pip-compile --output-file=requirements_full.txt pyproject.toml
#
certifi==2024.6.2
certifi>=2024.07.04
# via
# netcdf4
# requests
Expand Down
3 changes: 3 additions & 0 deletions src/janus/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
from __future__ import annotations

__version__ = '24.10.30'
3 changes: 2 additions & 1 deletion src/janus/utils/atmosphere_column.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
import toml
import numpy as np
import netCDF4 as nc
from janus import __version__
from janus.utils import phys
from janus.utils.height import integrate_heights
import os, copy, platform, shutil
Expand Down Expand Up @@ -406,7 +407,7 @@ def write_ncdf(self, fpath:str):
# If os.getlogin() fails, try an alternative method
username = pwd.getpwuid(os.getuid()).pw_name
ds.username = str(username)
ds.JANUS_version = "24.09.12"
ds.JANUS_version = __version__
ds.SOCRATES_version = str(SOCRATES_version)
ds.platform = str(platform.system())
ds.date = str(datetime.now().strftime('%Y-%m-%d %H:%M:%S'))
Expand Down
Empty file modified tools/clean_spectral_file.py
100644 → 100755
Empty file.
Empty file modified tools/compute_wtg.py
100644 → 100755
Empty file.
Empty file modified tools/generate_requirements_txt.py
100644 → 100755
Empty file.
Empty file modified tools/generate_spectral_file.py
100644 → 100755
Empty file.

0 comments on commit c8480fc

Please sign in to comment.