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
22 changes: 11 additions & 11 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,22 +3,22 @@ matrix:
include:
- name: "Python 2.7, TEST_CONDA=0"
env: SLYCOT_PYTHON_VERSION=2.7 TEST_CONDA=0
- name: "Python 2.7, TEST_CONDA=1"
- name: "Python 2.7, TEST_CONDA=1"
env: SLYCOT_PYTHON_VERSION=2.7 TEST_CONDA=1

- name: "Python 3.5, TEST_CONDA=0"
env: SLYCOT_PYTHON_VERSION=3.7 TEST_CONDA=0
- name: "Python 3.5, TEST_CONDA=1"
env: SLYCOT_PYTHON_VERSION=3.7 TEST_CONDA=1
env: SLYCOT_PYTHON_VERSION=3.5 TEST_CONDA=0
- name: "Python 3.5, TEST_CONDA=1"
env: SLYCOT_PYTHON_VERSION=3.5 TEST_CONDA=1

- name: "Python 3.6, TEST_CONDA=0"
env: SLYCOT_PYTHON_VERSION=3.7 TEST_CONDA=0
- name: "Python 3.6, TEST_CONDA=1"
env: SLYCOT_PYTHON_VERSION=3.7 TEST_CONDA=1
env: SLYCOT_PYTHON_VERSION=3.6 TEST_CONDA=0
- name: "Python 3.6, TEST_CONDA=1"
env: SLYCOT_PYTHON_VERSION=3.6 TEST_CONDA=1

- name: "Python 3.7, TEST_CONDA=0"
env: SLYCOT_PYTHON_VERSION=3.7 TEST_CONDA=0
- name: "Python 3.7, TEST_CONDA=1"
- name: "Python 3.7, TEST_CONDA=1"
env: SLYCOT_PYTHON_VERSION=3.7 TEST_CONDA=1

before_install:
Expand Down Expand Up @@ -54,7 +54,7 @@ install:
# Set up a test environment for testing everything out
- conda create -q -n test-environment python="$SLYCOT_PYTHON_VERSION" pip coverage nose numpy openblas
- source activate test-environment

#
# Make sure that fortran compiler can find conda libraries
#
Expand All @@ -66,8 +66,8 @@ install:
conda install -c conda-forge scikit-build >=0.8.0 ;
fi
#
# Install the slycot package (two ways, to improve robustness). For the
# conda version, need to install lapack from conda-forge (no way to specify
# Install the slycot package (two ways, to improve robustness). For the
# conda version, need to install lapack from conda-forge (no way to specify
# this in the recipe).
# add the conda-forge channel to the config, otherwise openblas or
# lapack cannot be found in the check
Expand Down
15 changes: 12 additions & 3 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -150,10 +150,19 @@ def get_version_info(srcdir=None):
(ISRELEASED and 'yes') or 'no')
elif os.path.exists('setup.cfg'):
# valid distribution
setupcfg = configparser.ConfigParser()
setupcfg = configparser.ConfigParser(allow_no_value=True)
setupcfg.read('setup.cfg')
FULLVERSION = setupcfg['metadata'].get('version', 'Unknown')
GIT_REVISION = setupcfg['metadata'].get('gitrevision', '')

FULLVERSION = setupcfg.get(section='metadata', option='version')

if FULLVERSION is None:
FULLVERSION = "Unknown"

GIT_REVISION = setupcfg.get(section='metadata', option='gitrevision')

if GIT_REVISION is None:
GIT_REVISION = ""

return FULLVERSION, GIT_REVISION
else:

Expand Down