Skip to content

Commit 71d5954

Browse files
authored
Merge pull request #40 from rstoneback/develop
Update Documentation and Testing
2 parents b873309 + d700398 commit 71d5954

8 files changed

Lines changed: 62 additions & 35 deletions

File tree

.travis.yml

Lines changed: 40 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -3,41 +3,63 @@ dist: xenial
33
matrix:
44
include:
55
- python: 2.7
6+
services: xvfb
67
- python: 3.6
7-
- python: 3.7
8-
- python: 3.8
8+
dist: xenial
9+
services: xvfb
910

1011
addons:
1112
apt:
1213
packages:
1314
- gfortran
15+
- libncurses5-dev
1416

1517
before_install:
16-
- pip install pytest-cov
18+
- sudo apt-get update
19+
# We do this conditionally because it saves us some downloading if the
20+
# version is the same.
21+
- if [[ "$TRAVIS_PYTHON_VERSION" == "2.7" ]]; then
22+
wget https://repo.continuum.io/miniconda/Miniconda2-latest-Linux-x86_64.sh -O miniconda.sh;
23+
else
24+
wget https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh -O miniconda.sh;
25+
fi
26+
- bash miniconda.sh -b -p $HOME/miniconda
27+
- source "$HOME/miniconda/etc/profile.d/conda.sh"
28+
- hash -r
29+
- conda config --set always_yes True --set changeps1 False
30+
- conda update -q conda
31+
# Useful for debugging any issues with conda
32+
- conda info -a
33+
# Create conda test environment
34+
- conda create -q -n test-environment python=$TRAVIS_PYTHON_VERSION numpy scipy requests beautifulsoup4 lxml netCDF4 h5py nose pytest-cov pytest-ordering coveralls future
35+
- conda activate test-environment
36+
# Install version limited packages
37+
- conda install 'pandas>=0.23, <0.25'
38+
- conda install 'xarray<0.15'
39+
- conda install 'kiwisolver<1.2'
40+
# Dependencies not available through conda, install through pip
41+
- pip install madrigalWeb
42+
- pip install PyForecastTools
43+
- pip install pysatCDF >/dev/null
44+
# Get latest coveralls from pip, not conda
1745
- pip install coveralls
18-
- pip install future
19-
- pip install 'pandas<0.25'
20-
- pip install 'xarray<0.15'
21-
# Install version specific packages for 2.7 and 3.5
22-
- pip install matplotlib
46+
# set up data directory
47+
- mkdir /home/travis/build/pysatData
2348
- pip install apexpy
24-
- pip install numpy
25-
- pip install pysatCDF >/dev/null
49+
50+
# Prepare modified pysat install
2651
- cd ..
52+
- echo 'cloning pysat'
2753
- git clone https://github.com/pysat/pysat.git >/dev/null
28-
- cd ./pysat # set up data directory
54+
- echo 'installing pysat'
55+
- cd ./pysat
56+
# install pysat
2957
- git checkout develop
30-
- git pull origin develop
3158
- python setup.py install >/dev/null
32-
- cd ..
33-
34-
# set up data directory
35-
- mkdir /home/travis/build/pysatData
36-
- python -c 'import pysat; pysat.utils.set_data_dir("/home/travis/build/pysatData")'
59+
- cd ../OMMBV
3760

3861
install:
3962
# install OMMBV
40-
- cd ./OMMBV
4163
- python setup.py develop
4264

4365
# command to run tests

CHANGELOG.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,9 @@
22
All notable changes to this project will be documented in this file.
33
This project adheres to [Semantic Versioning](http://semver.org/).
44

5+
## [0.5.2] - 2020-06-04
6+
- Fixed bugs coupling the code repo to community services related to the name change from pysatMagvect to OMMBV
7+
58
## [0.5.0] - 2020-02-01
69
- Added community documents
710
- Implemented new algorithm for basis vectors. First system valid for multipole fields.

CONTRIBUTING.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,13 @@ contributions.
88
Short version
99
=============
1010

11-
* Submit bug reports and feature requests at `GitHub <https://github.com/pysat/pysatMagVect/issues>`_
11+
* Submit bug reports and feature requests at `GitHub <https://github.com/rstoneback/OMMBV/issues>`_
1212
* Make pull requests to the ``develop`` branch
1313

1414
Bug reports
1515
===========
1616

17-
When `reporting a bug <https://github.com/pysat/pysatMagVect/issues>`_ please
17+
When `reporting a bug <https://github.com/rstoneback/OMMBV/issues>`_ please
1818
include:
1919

2020
* Your operating system name and version
@@ -25,7 +25,7 @@ Feature requests and feedback
2525
=============================
2626

2727
The best way to send feedback is to file an issue at
28-
`GitHub <https://github.com/pysat/pysatMagVect/issues>`_.
28+
`GitHub <https://github.com/rstoneback/OMMBV/issues>`_.
2929

3030
If you are proposing a feature:
3131

@@ -39,7 +39,7 @@ Development
3939

4040
To set up `pysat` for local development:
4141

42-
1. `Fork pysat on GitHub <https://github.com/pysat/pysatMagVect/fork>`_.
42+
1. `Fork pysat on GitHub <https://github.com/rstoneback/OMMBV/fork>`_.
4343
2. Clone your fork locally::
4444

4545
git clone git@github.com:your_name_here/pysatMagVect.git
@@ -49,7 +49,7 @@ To set up `pysat` for local development:
4949
git checkout -b name-of-your-bugfix-or-feature
5050

5151
Now you can make your changes locally. Tests should be added to the
52-
appropriately named file in ``pysatMagVect/tests``.
52+
appropriately named file in ``OMMBV/tests``.
5353

5454
4. When you're done making changes, run all the checks to ensure that nothing
5555
is broken on your local system::

OMMBV/_core.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -110,9 +110,10 @@ def geodetic_to_ecef(latitude, longitude, altitude):
110110

111111
return x, y, z
112112

113-
114-
ecef_to_geodetic = OMMBV.fortran_coords.ecef_to_geodetic
115-
113+
try:
114+
ecef_to_geodetic = OMMBV.fortran_coords.ecef_to_geodetic
115+
except AttributeError:
116+
print('Unable to use Fortran version of ecef_to_geodetic. Please check installation.')
116117

117118
def python_ecef_to_geodetic(x, y, z, method=None):
118119
"""Convert ECEF into Geodetic WGS84 coordinates

OMMBV/version.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
0.5.1
1+
0.5.2

docs/api.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22
API
33
===
44

5-
.. automodule:: pysatMagVect._core
5+
.. automodule:: OMMBV._core
66
:members:
77

8-
.. automodule:: pysatMagVect.satellite
8+
.. automodule:: OMMBV.satellite
99
:members:

docs/conf.py

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -30,11 +30,12 @@ class Mock(MagicMock):
3030
def __getattr__(cls, name):
3131
return MagicMock()
3232

33-
MOCK_MODULES = ['OMMBV.igrf', 'scipy', 'scipy.integrate', 'numpy', 'datetime', 'pysat']
33+
MOCK_MODULES = ['OMMBV.igrf', 'OMMBV.fortran_coords', 'OMMBV.fortran_coords.ecef_to_geodetic',
34+
'scipy', 'scipy.integrate', 'numpy', 'datetime', 'pysat']
3435
sys.modules.update((mod_name, Mock()) for mod_name in MOCK_MODULES)
3536

3637
#print sys.path
37-
import pysatMagVect
38+
import OMMBV
3839
#print pysat.__path__
3940

4041

@@ -87,9 +88,9 @@ def __getattr__(cls, name):
8788
# built documents.
8889
#
8990
# The short X.Y version.
90-
version = pysatMagVect.__version__[::-1].partition('.')[2][::-1]
91+
version = OMMBV.__version__[::-1].partition('.')[2][::-1]
9192
# The full version, including alpha/beta/rc tags.
92-
release = pysatMagVect.__version__
93+
release = OMMBV.__version__
9394

9495
# The language for content autogenerated by Sphinx. Refer to documentation
9596
# for a list of supported languages.

docs/index.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33
You can adapt this file completely to your liking, but it should at least
44
contain the root `toctree` directive.
55
6-
Welcome to pysatMagVect's documentation!
7-
========================================
6+
Welcome to OMMBV's documentation!
7+
=================================
88

99
.. toctree::
1010
:maxdepth: 2

0 commit comments

Comments
 (0)