diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 39515b10f..d6fe8f42b 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -43,9 +43,8 @@ jobs: - run: pip install . - run: pip list - id: version - uses: mtkennerly/dunamai-action@v1 - with: - args: --strict --pattern "default-unprefixed" --style semver + name: retrieve package version + run: echo version=$(python -c "import jwql; print(jwql.__version__)") >> $GITHUB_OUTPUT - id: filename run: echo "filename=jwql_${{ steps.version.outputs.version }}_conda_${{ runner.os }}_${{ runner.arch }}_py${{ matrix.python-version }}.yml" >> $GITHUB_OUTPUT - run: conda env export --no-build | grep -v "name:" | grep -v "prefix:" > ${{ steps.filename.outputs.filename }} diff --git a/jwql/__init__.py b/jwql/__init__.py index d1949b6ee..630d20207 100644 --- a/jwql/__init__.py +++ b/jwql/__init__.py @@ -1,4 +1,6 @@ +import warnings from importlib.metadata import version + from jwql.utils import utils __version__ = version('jwql') @@ -10,4 +12,4 @@ f"while JWQL is using {__version__}") except FileNotFoundError: - print('Could not determine jwql config version') + warnings.warn('Could not determine jwql config version')