[yt-svn] commit/yt: 5 new changesets

commits-noreply at bitbucket.org commits-noreply at bitbucket.org
Mon May 1 07:38:39 PDT 2017


5 new commits in yt:

https://bitbucket.org/yt_analysis/yt/commits/c66db6d2cf57/
Changeset:   c66db6d2cf57
Branch:      yt
User:        ngoldbaum
Date:        2017-04-20 22:54:03+00:00
Summary:     Updating install script for git transition
Affected #:  2 files

diff -r e0add337739c8d6744207145757215c1f7204863 -r c66db6d2cf57396fd613bf2dc5d04528c057d005 doc/install_script.sh
--- a/doc/install_script.sh
+++ b/doc/install_script.sh
@@ -30,7 +30,7 @@
 # INST_CONDA=0
 # INST_YT_SOURCE=1
 
-BRANCH="yt" # This is the branch to which we will forcibly update.
+BRANCH="yt" # This is the branch we will install from for source installs
 
 # What follows are some other options that you may or may not need to change.
 
@@ -44,11 +44,12 @@
 
 # These options can be set to customize the installation.
 
-INST_PY3=0          # Install Python 3 along with Python 2. If this is turned
+INST_PY3=1          # Install Python 3 instead of Python 2. If this is turned
                     # on, all Python packages (including yt) will be installed
-                    # in Python 3 (except Mercurial, which requires Python 2).
-INST_HG=1           # Install Mercurial or not?  If hg is not already
+                    # in Python 3.
+INST_GIT=1          # Install git or not?  If git is not already
                     # installed, yt cannot be installed from source.
+INT_HG=0            # Install Mercurial or not? Ignored if INST_CONDA=0.
 INST_EMBREE=0       # Install dependencies needed for Embree-accelerated 
                     # ray tracing
 
@@ -200,7 +201,7 @@
 {
     CONFIG_FILE=${DEST_DIR}/.yt_config
 
-    echo INST_HG=${INST_HG} > ${CONFIG_FILE}
+    echo INST_GIT=${INST_GIT} > ${CONFIG_FILE}
     echo INST_ZLIB=${INST_ZLIB} >> ${CONFIG_FILE}
     echo INST_BZLIB=${INST_BZLIB} >> ${CONFIG_FILE}
     echo INST_PNG=${INST_PNG} >> ${CONFIG_FILE}
@@ -566,9 +567,9 @@
 get_willwont ${INST_PY3}
 echo "be installing Python 3"
 
-printf "%-18s = %s so I " "INST_HG" "${INST_HG}"
-get_willwont ${INST_HG}
-echo "be installing Mercurial"
+printf "%-18s = %s so I " "INST_GIT" "${INST_GIT}"
+get_willwont ${INST_GIT}
+echo "be installing git"
 
 printf "%-18s = %s so I " "INST_EMBREE" "${INST_EMBREE}"
 get_willwont ${INST_EMBREE}
@@ -640,10 +641,12 @@
 echo "If you'd rather stop, maybe think things over, even grab a sandwich, "
 echo "hit Ctrl-C."
 echo
+
 if [ $INST_YT_SOURCE -ne 0 ]
 then
    host_specific
 fi
+
 if [ $INST_CONDA -eq 0 ]
 then
     if [ ${USED_CONFIG} ]
@@ -679,7 +682,7 @@
 
 if [ $INST_PY3 -eq 1 ]
 then
-     PYTHON_EXEC='python3.5'
+     PYTHON_EXEC='python3'
 else 
      PYTHON_EXEC='python2.7'
 fi
@@ -698,12 +701,7 @@
     [ ! -e $LIB/extracted ] && tar xfz $LIB.tar.gz
     touch $LIB/extracted
     BUILD_ARGS=""
-    if [[ $LIB =~ .*mercurial.* ]]
-    then
-        PYEXE="python2.7"
-    else
-        PYEXE=${PYTHON_EXEC}
-    fi
+    PYEXE=${PYTHON_EXEC}
     case $LIB in
         *h5py*)
             pushd $LIB &> /dev/null
@@ -836,10 +834,10 @@
     LAPACK='lapack-3.4.2'
     PNG='libpng-1.6.3'
     MATPLOTLIB='matplotlib-1.5.1'
-    MERCURIAL='mercurial-3.7.3'
+    GIT='git-2.12.2'
     NOSE='nose-1.3.7'
     NUMPY='numpy-1.11.0'
-    PYTHON_HGLIB='python-hglib-2.0'
+    GITPYTHON='GitPython-2.1.3'
     ROCKSTAR='rockstar-0.99.6'
     SCIPY='scipy-0.17.0'
     SQLITE='sqlite-autoconf-3071700'
@@ -867,10 +865,10 @@
     echo '8770214491e31f0a7a3efaade90eee7b0eb20a8a6ab635c5f854d78263f59a1849133c14ef5123d01023f0110cbb9fc6f818da053c01277914ae81473430a952  lapack-3.4.2.tar.gz' > lapack-3.4.2.tar.gz.sha512
     echo '887582e5a22e4cde338aa8fec7a89f6dd31f2f02b8842735f00f970f64582333fa03401cea6d01704083403c7e8b7ebc26655468ce930165673b33efa4bcd586  libpng-1.6.3.tar.gz' > libpng-1.6.3.tar.gz.sha512
     echo 'a0e78b5027a3a49cf8e77dc0d26f5f380dcd80f7b309b6121199acd5e1d94f48482864a9eee3bd397f7ac6f07fe1d3c21bf517217df3c72e8e3d105b7c2ae58e  matplotlib-1.5.1.tar.gz' > matplotlib-1.5.1.tar.gz.sha512
-    echo '7f9f97229e40c7092c16ccf227b19a08a9839d8ce19a9d057341fff75876bff32241ee9aa10eab293f779ea3e8a1d97577597187bd96251fb499cbb1075a82cf  mercurial-3.7.3.tar.gz' > mercurial-3.7.3.tar.gz.sha512
+    echo '67ce429436277c1fd64ee2a48326cdeec4a25a4f3bfa2dec84b5207752f8e09d5061c94dbd2c7f8bedc42f8df2142ed69b002d2d7d350cf6a40ac1e2736514e0  git-2.12.2.tar.gz' > git-2.12.2.tar.gz.sha512
     echo 'e65c914f621f8da06b9ab11a0ff2763d6e29b82ce2aaed56da0e3773dc899d9deb1f20015789d44c65a5dad7214520f5b659b3f8d7695fb207ad3f78e5cf1b62  nose-1.3.7.tar.gz' > nose-1.3.7.tar.gz.sha512
     echo '92c1889397ad013e25da3a0657fc01e787d528fc19c29cc2acd286c3f07d41b984252583457b1b9259fc303afbe9694565cdcf5752eb4ecb950cc7a99ec1ad8b  numpy-1.11.0.tar.gz' > numpy-1.11.0.tar.gz.sha512
-    echo '647cc82424783efc3d74540e34976af66acc35fc36d66afba169508946cc62027910c7e41dc9d11ec88c15d6b1e113ce22c2781711ea324de58db3b24d5079c4  python-hglib-2.0.tar.gz' > python-hglib-2.0.tar.gz.sha512
+    echo '918ff1765a85a818619165c2bcbb0d417f35c979c2f42f1bb7e41636696c0cb4d6837725f3655fbdfebea966476d1255ee18adabe9ed5536455b63336a1f399d  GitPython-2.1.3.tar.gz' > GitPython-2.1.3.tar.gz.sha512
     echo 'de6409d75a3ff3cf1e5391d3b09126f0bc7e1a40a15f9bee244195638fe2f8481fca032896d8534623e6122ff59aaf669664e27ff89cf1b094a5ce7312f220b7  scipy-0.17.0.tar.gz' > scipy-0.17.0.tar.gz.sha512
     echo '96f3e51b46741450bc6b63779c10ebb4a7066860fe544385d64d1eda52592e376a589ef282ace2e1df73df61c10eab1a0d793abbdaf770e60289494d4bf3bcb4  sqlite-autoconf-3071700.tar.gz' > sqlite-autoconf-3071700.tar.gz.sha512
     echo '977db6e9bc6a5918cceb255981a57e85e7060c0922aefd2968b004d25d704e25a5cb5bbe09eb387e8695581e23e2825d9c40310068fe25ece7e9c23037a21f39  sympy-1.0.tar.gz' > sympy-1.0.tar.gz.sha512
@@ -887,16 +885,20 @@
     [ $INST_SCIPY -eq 1 ] && get_ytproject $SCIPY.tar.gz
     [ $INST_SCIPY -eq 1 ] && get_ytproject blas.tar.gz
     [ $INST_SCIPY -eq 1 ] && get_ytproject $LAPACK.tar.gz
-    [ $INST_HG -eq 1 ] && get_ytproject $MERCURIAL.tar.gz
-    [ $INST_PY3 -eq 1 ] && get_ytproject $PYTHON3.tgz
+    [ $INST_GIT -eq 1 ] && get_ytproject $GIT.tar.gz
+    if [ $INST_PY3 -eq 1 ]
+    then
+        get_ytproject $PYTHON3.tgz
+    else
+        get_ytproject $PYTHON2.tgz
+    fi
     [ $INST_H5PY -eq 1 ] && get_ytproject $H5PY.tar.gz
     [ $INST_NOSE -eq 1 ] && get_ytproject $NOSE.tar.gz
     [ $INST_ASTROPY -eq 1 ] && get_ytproject $ASTROPY.tar.gz
-    get_ytproject $PYTHON2.tgz
     get_ytproject $NUMPY.tar.gz
     get_ytproject $MATPLOTLIB.tar.gz
     get_ytproject $CYTHON.tar.gz
-    get_ytproject $PYTHON_HGLIB.tar.gz
+    get_ytproject $GITPYTHON.tar.gz
     get_ytproject $SYMPY.tar.gz
     get_ytproject $SETUPTOOLS.tar.gz
 
@@ -936,7 +938,7 @@
             cd $ZLIB
             ( ./configure --shared --prefix=${DEST_DIR}/ 2>&1 ) 1>> ${LOG_FILE} || do_exit
             ( make install 2>&1 ) 1>> ${LOG_FILE} || do_exit
-            ( make clean 2>&1) 1>> ${LOG_FILE} || do_exit
+            ( make clean 2>&1 ) 1>> ${LOG_FILE} || do_exit
             touch done
             cd ..
         fi
@@ -1016,37 +1018,11 @@
         fi
     fi
 
-    if [ ! -e $PYTHON2/done ]
-    then
-        echo "Installing Python 2. This may take a while, but don't worry. yt loves you."
-        [ ! -e $PYTHON2 ] && tar xfz $PYTHON2.tgz
-        cd $PYTHON2
-        ( ./configure --prefix=${DEST_DIR}/ ${PYCONF_ARGS} 2>&1 ) 1>> ${LOG_FILE} || do_exit
-        
-        ( make ${MAKE_PROCS} 2>&1 ) 1>> ${LOG_FILE} || do_exit
-        ( make install 2>&1 ) 1>> ${LOG_FILE} || do_exit
-        ( ln -sf ${DEST_DIR}/bin/python2.7 ${DEST_DIR}/bin/pyyt 2>&1 ) 1>> ${LOG_FILE}
-        ( make clean 2>&1) 1>> ${LOG_FILE} || do_exit
-        touch done
-        cd ..
-    fi
-
-    ( ${DEST_DIR}/bin/python -c "import _ssl" 2>&1 ) 1>> ${LOG_FILE}
-    RESULT=$?
-    if  [ $RESULT -ne 0 ]
-    then
-        echo "Unable to import the python SSL bindings."
-        echo "This means that OpenSSL is not installed or your system's OpenSSL"
-        echo "installation is out of date."
-        echo "Please install OpenSSL or set INST_CONDA=1"
-        do_exit
-    fi
-
     if [ $INST_PY3 -eq 1 ]
     then
         if [ ! -e $PYTHON3/done ]
         then
-            echo "Installing Python 3. Because two Pythons are better than one."
+            echo "Installing Python 3"
             [ ! -e $PYTHON3 ] && tar xfz $PYTHON3.tgz
             cd $PYTHON3
             ( ./configure --prefix=${DEST_DIR}/ ${PYCONF_ARGS} 2>&1 ) 1>> ${LOG_FILE} || do_exit
@@ -1060,6 +1036,31 @@
             touch done
             cd ..
         fi
+    else
+        if [ ! -e $PYTHON2/done ]
+        then
+            echo "Installing Python 2. This may take a while, but don't worry. yt loves you."
+            [ ! -e $PYTHON2 ] && tar xfz $PYTHON2.tgz
+            cd $PYTHON2
+            ( ./configure --prefix=${DEST_DIR}/ ${PYCONF_ARGS} 2>&1 ) 1>> ${LOG_FILE} || do_exit
+            ( make ${MAKE_PROCS} 2>&1 ) 1>> ${LOG_FILE} || do_exit
+            ( make install 2>&1 ) 1>> ${LOG_FILE} || do_exit
+            ( ln -sf ${DEST_DIR}/bin/python2.7 ${DEST_DIR}/bin/pyyt 2>&1 ) 1>> ${LOG_FILE}
+            ( make clean 2>&1) 1>> ${LOG_FILE} || do_exit
+            touch done
+            cd ..
+        fi
+    fi
+
+    ( ${DEST_DIR}/bin/python -c "import _ssl" 2>&1 ) 1>> ${LOG_FILE}
+    RESULT=$?
+    if  [ $RESULT -ne 0 ]
+    then
+        echo "Unable to import the python SSL bindings."
+        echo "This means that OpenSSL is not installed or your system's OpenSSL"
+        echo "installation is out of date."
+        echo "Please install OpenSSL or set INST_CONDA=1"
+        do_exit
     fi
 
     export PYTHONPATH=${DEST_DIR}/lib/${PYTHON_EXEC}/site-packages/
@@ -1067,17 +1068,23 @@
     # Install setuptools
     do_setup_py $SETUPTOOLS
 
-    if [ $INST_HG -eq 1 ]
+    if [ $INST_GIT -eq 1 ]
     then
-        do_setup_py $MERCURIAL
-        export HG_EXEC=${DEST_DIR}/bin/hg
+        [ ! -e $GIT ] && tar xfz $GIT.tar.gz
+        echo "Installing git"
+        cd $GIT
+        ( ./configure --prefix=${DEST_DIR}/ 2>&1 ) 1>> ${LOG_FILE} || do_exit
+        ( make install 2>&1 ) 1>> ${LOG_FILE} || do_exit
+        ( make clean 2>&1 ) 1>> ${LOG_FILE} || do_exit
+        touch done
+        cd ..
+        GIT_EXE=${DEST_DIR}/bin/git
     else
-        # We assume that hg can be found in the path.
-        if type -P hg &>/dev/null
+        if type -p git &>/dev/null
         then
-            export HG_EXEC=hg
+            GIT_EXE="git"
         else
-            echo "Cannot find mercurial.  Please set INST_HG=1."
+            echo "Cannot find git. Please set INST_GIT=1."
             do_exit
         fi
     fi
@@ -1090,20 +1097,14 @@
         elif [ -e $ORIG_PWD/../yt/mods.py ]
         then
             YT_DIR=`dirname $ORIG_PWD`
-        elif [ ! -e yt-hg ]
+        elif [ ! -e yt-git ]
         then
             echo "Cloning yt"
-            YT_DIR="$PWD/yt-hg/"
-            ( ${HG_EXEC} --debug clone https://bitbucket.org/yt_analysis/yt-supplemental/ 2>&1 ) 1>> ${LOG_FILE}
-            # Recently the hg server has had some issues with timeouts.  In lieu of
-            # a new webserver, we are now moving to a three-stage process.
-            # First we clone the repo, but only up to r0.
-            ( ${HG_EXEC} --debug clone https://bitbucket.org/yt_analysis/yt/ ./yt-hg 2>&1 ) 1>> ${LOG_FILE}
-            # Now we update to the branch we're interested in.
-            ( ${HG_EXEC} -R ${YT_DIR} up -C ${BRANCH} 2>&1 ) 1>> ${LOG_FILE}
-        elif [ -e yt-hg ]
+            YT_DIR="$PWD/yt-git/"
+            ( ${GIT_EXE} clone https://github.com/yt-project/yt/ ${YT_DIR} 2>&1 ) 1>> ${LOG_FILE}
+        elif [ -e yt-git ]
         then
-            YT_DIR="$PWD/yt-hg/"
+            YT_DIR="$PWD/yt-git/"
         fi
         echo Setting YT_DIR=${YT_DIR}
     fi
@@ -1206,7 +1207,7 @@
     then
         do_setup_py $ASTROPY
     fi
-    do_setup_py $PYTHON_HGLIB
+    do_setup_py $GITPYTHON
     do_setup_py $SYMPY
     [ $INST_PYX -eq 1 ] && do_setup_py $PYX
 
@@ -1220,11 +1221,9 @@
             echo "Building Rockstar"
             if [ ! -e rockstar ]
             then
-                ( hg clone http://bitbucket.org/MatthewTurk/rockstar 2>&1 ) 1>> ${LOG_FILE}
+                ( ${GIT_EXE} clone https://github.com/yt-project/rockstar 2>&1 ) 1>> ${LOG_FILE}
             fi
             cd rockstar
-            ( hg pull 2>&1 ) 1>> ${LOG_FILE}
-            ( hg up -C tip 2>&1 ) 1>> ${LOG_FILE}
             ( make lib 2>&1 ) 1>> ${LOG_FILE} || do_exit
             cp librockstar.so ${DEST_DIR}/lib
             ROCKSTAR_DIR=${DEST_DIR}/src/rockstar
@@ -1234,10 +1233,9 @@
         fi
     fi
     
-    echo "Doing yt update, wiping local changes and updating to branch ${BRANCH}"
     MY_PWD=`pwd`
     cd $YT_DIR
-    ( ${HG_EXEC} pull 2>1 && ${HG_EXEC} up -C 2>1 ${BRANCH} 2>&1 ) 1>> ${LOG_FILE}
+    ( ${GIT_EXE} pull 2>1 && ${GIT_EXE} checkout ${BRANCH} 2>&1 ) 1>> ${LOG_FILE}
 
     echo "Installing yt"
     [ $INST_PNG -eq 1 ] && echo $PNG_DIR > png.cfg
@@ -1300,12 +1298,12 @@
         echo
         echo "The source for yt is located at:"
         echo "    $YT_DIR"
-        if [ $INST_HG -eq 1 ]
+        if [ $INST_GIT -eq 1 ]
         then
             echo
-            echo "Mercurial has also been installed:"
+            echo "Git has also been installed:"
             echo
-            echo "$DEST_DIR/bin/hg"
+            echo "$GIT_EXE"
             echo
         fi
         echo
@@ -1399,6 +1397,11 @@
     YT_DEPS+=('jupyter')
     YT_DEPS+=('ipython')
     YT_DEPS+=('sphinx')
+    if [ ${INST_GIT} -eq 1 ]
+    then
+        YT_DEPS+=('git')
+        YT_DEPS+=('gitpython')
+    fi
     if [ $INST_H5PY -ne 0 ]
     then
         YT_DEPS+=('h5py')
@@ -1418,7 +1421,7 @@
         YT_DEPS+=('astropy')
     fi
     YT_DEPS+=('conda-build')
-    if [ $INST_PY3 -eq 0 ]
+    if [ $INST_PY3 -eq 0 ] && [ $INST_HG -eq 1 ]
     then
        YT_DEPS+=('mercurial')
     fi
@@ -1431,22 +1434,22 @@
     
     log_cmd ${DEST_DIR}/bin/conda update --yes conda
     
+    GIT_EXE=${DEST_DIR}/bin/git
+
     log_cmd echo "DEPENDENCIES" ${YT_DEPS[@]}
     for YT_DEP in "${YT_DEPS[@]}"; do
         echo "Installing $YT_DEP"
-        log_cmd ${DEST_DIR}/bin/conda install --yes ${YT_DEP}
+        log_cmd ${DEST_DIR}/bin/conda install -c conda-forge --yes ${YT_DEP}
     done
 
-    if [ $INST_PY3 -eq 1 ]
+    if [ $INST_PY3 -eq 1 ] && [ $INST_HG -eq 1 ]
     then
         echo "Installing mercurial"
         log_cmd ${DEST_DIR}/bin/conda create -y -n py27 python=2.7 mercurial
         log_cmd ln -s ${DEST_DIR}/envs/py27/bin/hg ${DEST_DIR}/bin
     fi
 
-    log_cmd ${DEST_DIR}/bin/pip install python-hglib
-
-    log_cmd ${DEST_DIR}/bin/hg clone https://bitbucket.org/yt_analysis/yt_conda ${DEST_DIR}/src/yt_conda
+    log_cmd ${GIT_EXE} clone https://github.com/yt-project/yt_conda ${DEST_DIR}/src/yt_conda
     
     if [ $INST_EMBREE -eq 1 ]
     then
@@ -1480,7 +1483,7 @@
     if [ $INST_ROCKSTAR -eq 1 ]
     then
         echo "Building Rockstar"
-        ( ${DEST_DIR}/bin/hg clone http://bitbucket.org/MatthewTurk/rockstar ${DEST_DIR}/src/rockstar/ 2>&1 ) 1>> ${LOG_FILE}
+        ( ${GIT_EXE} clone https://github.com/yt-project/rockstar ${DEST_DIR}/src/rockstar/ 2>&1 ) 1>> ${LOG_FILE}
         ROCKSTAR_PACKAGE=$(${DEST_DIR}/bin/conda build ${DEST_DIR}/src/yt_conda/rockstar --output)
         log_cmd ${DEST_DIR}/bin/conda build ${DEST_DIR}/src/yt_conda/rockstar
         log_cmd ${DEST_DIR}/bin/conda install $ROCKSTAR_PACKAGE
@@ -1504,9 +1507,9 @@
         log_cmd ${DEST_DIR}/bin/conda install -c conda-forge --yes yt
     else
         echo "Building yt from source"
-        YT_DIR="${DEST_DIR}/src/yt-hg"
-        log_cmd ${DEST_DIR}/bin/hg clone https://bitbucket.org/yt_analysis/yt ${YT_DIR}
-        log_cmd ${DEST_DIR}/bin/hg -R ${YT_DIR} up -C ${BRANCH}
+        YT_DIR="${DEST_DIR}/src/yt-git"
+        log_cmd ${GIT_EXE} clone https://github.com/yt-project/yt ${YT_DIR}
+        log_cmd ${GIT_EXE} -C ${YT_DIR} checkout ${BRANCH}
         if [ $INST_EMBREE -eq 1 ]
         then
             echo $DEST_DIR > ${YT_DIR}/embree.cfg

diff -r e0add337739c8d6744207145757215c1f7204863 -r c66db6d2cf57396fd613bf2dc5d04528c057d005 tests/test_install_script.py
--- a/tests/test_install_script.py
+++ b/tests/test_install_script.py
@@ -8,7 +8,7 @@
 
 # dependencies that are always installed
 REQUIRED_DEPS = [
-    'mercurial',
+    'git',
     'jupyter',
     'numpy',
     'matplotlib',
@@ -17,12 +17,11 @@
     'nose',
     'sympy',
     'setuptools',
-    'hglib'
 ]
 
 # dependencies that aren't installed by default
 OPTIONAL_DEPS = [
-    'unstructured',
+    'embree',
     'pyx',
     'rockstar',
     'scipy',
@@ -31,17 +30,18 @@
 
 # dependencies that are only installable when yt is built from source
 YT_SOURCE_ONLY_DEPS = [
-    'unstructured',
+    'embree',
     'rockstar'
 ]
 
-# dependencies that are only installable when yt is built from source under conda
+# dependencies that are only installable when yt is built from source under 
+# conda
 YT_SOURCE_CONDA_ONLY_DEPS = [
-    'unstructured'
+    'embree'
 ]
 
 DEPENDENCY_IMPORT_TESTS = {
-    'unstructured': "from yt.utilities.lib import mesh_traversal",
+    'embree': "from yt.utilities.lib import mesh_traversal",
     'rockstar': ("from yt.analysis_modules.halo_finding.rockstar "
                  "import rockstar_interface")
 }
@@ -60,7 +60,7 @@
     finally:
         if len(output.splitlines()) > 25:
             print ('truncated output:')
-            print ('\n'.join((output.splitlines())[-25:]))
+            print ('\n'.join((output.decode().splitlines())[-25:]))
         else:
             print (output)
 
@@ -119,10 +119,10 @@
             continue
         if conda is False and dep in YT_SOURCE_CONDA_ONLY_DEPS:
             continue
-        elif dep == 'mercurial':
-            hg_path = os.sep.join([yt_dir, 'bin', 'hg'])
-            call_unix_command('{} --version'.format(hg_path))
-        elif dep in DEPENDENCY_IMPORT_TESTS:
+        if dep == 'git':
+            git_path = os.sep.join([yt_dir, 'bin', 'git'])
+            call_unix_command('{} --version'.format(git_path))
+        if dep in DEPENDENCY_IMPORT_TESTS:
             cmd = "{} -c '{}'"
             if dep == 'rockstar':
                 cmd = 'LD_LIBRARY_PATH={} '.format(


https://bitbucket.org/yt_analysis/yt/commits/e3ce646a54ac/
Changeset:   e3ce646a54ac
Branch:      yt
User:        ngoldbaum
Date:        2017-04-21 01:02:27+00:00
Summary:     Don't bother compiling git for source installs
Affected #:  1 file

diff -r c66db6d2cf57396fd613bf2dc5d04528c057d005 -r e3ce646a54ac2a1acc20afcff3bfbca22e16599a doc/install_script.sh
--- a/doc/install_script.sh
+++ b/doc/install_script.sh
@@ -47,8 +47,8 @@
 INST_PY3=1          # Install Python 3 instead of Python 2. If this is turned
                     # on, all Python packages (including yt) will be installed
                     # in Python 3.
-INST_GIT=1          # Install git or not?  If git is not already
-                    # installed, yt cannot be installed from source.
+INST_GIT=1          # Install git or not?  If git is not already installed, yt
+                    # cannot be installed from source. Ignored if INST_CONDA=0
 INT_HG=0            # Install Mercurial or not? Ignored if INST_CONDA=0.
 INST_EMBREE=0       # Install dependencies needed for Embree-accelerated 
                     # ray tracing
@@ -149,6 +149,10 @@
         echo "Please set INST_YT_SOURCE to 1 and re-run."
         exit 1
     fi
+    if [ $INST_GIT -eq 1 ]
+    then
+        INST_GIT=0
+    fi
     DEST_SUFFIX="yt-`uname -m`"
 fi
 
@@ -398,9 +402,10 @@
         echo "  * gcc-{,c++,gfortran}"
         echo "  * make"
         echo "  * patch"
+        echo "  * git"
         echo
         echo "You can accomplish this by executing:"
-        echo "$ sudo yum install gcc gcc-c++ gcc-gfortran make patch zip"
+        echo "$ sudo yum install gcc gcc-c++ gcc-gfortran make patch zip git"
         echo "$ sudo yum install ncurses-devel uuid-devel openssl-devel readline-devel"
     fi
     if [ -f /etc/SuSE-release ] && [ `grep --count SUSE /etc/SuSE-release` -gt 0 ]
@@ -414,11 +419,12 @@
         echo "  * libuuid-devel"
         echo "  * zip"
         echo "  * gcc-c++"
+        echo "  * git"
         echo
         echo "You can accomplish this by executing:"
         echo
         echo "$ sudo zypper install -t pattern devel_C_C++"
-        echo "$ sudo zypper install gcc-c++ libopenssl-devel libuuid-devel zip"
+        echo "$ sudo zypper install git-core gcc-c++ libopenssl-devel libuuid-devel zip"
         echo
         echo "I am also setting special configure arguments to Python to"
         echo "specify control lib/lib64 issues."
@@ -438,10 +444,11 @@
         echo "  * uuid-dev"
         echo "  * libfreetype6-dev"
         echo "  * tk-dev"
+        echo "  * git"
         echo
         echo "You can accomplish this by executing:"
         echo
-        echo "$ sudo apt-get install libssl-dev build-essential libncurses5 libncurses5-dev zip uuid-dev libfreetype6-dev tk-dev"
+        echo "$ sudo apt-get install libssl-dev build-essential libncurses5 libncurses5-dev zip uuid-dev libfreetype6-dev tk-dev git"
         echo
         echo
         echo " Additionally, if you want to put yt's lib dir in your LD_LIBRARY_PATH"
@@ -835,6 +842,8 @@
     PNG='libpng-1.6.3'
     MATPLOTLIB='matplotlib-1.5.1'
     GIT='git-2.12.2'
+    LIBCURL='curl-7.54.0'
+    EXPAT='expat-2.2.0'
     NOSE='nose-1.3.7'
     NUMPY='numpy-1.11.0'
     GITPYTHON='GitPython-2.1.3'
@@ -869,6 +878,8 @@
     echo 'e65c914f621f8da06b9ab11a0ff2763d6e29b82ce2aaed56da0e3773dc899d9deb1f20015789d44c65a5dad7214520f5b659b3f8d7695fb207ad3f78e5cf1b62  nose-1.3.7.tar.gz' > nose-1.3.7.tar.gz.sha512
     echo '92c1889397ad013e25da3a0657fc01e787d528fc19c29cc2acd286c3f07d41b984252583457b1b9259fc303afbe9694565cdcf5752eb4ecb950cc7a99ec1ad8b  numpy-1.11.0.tar.gz' > numpy-1.11.0.tar.gz.sha512
     echo '918ff1765a85a818619165c2bcbb0d417f35c979c2f42f1bb7e41636696c0cb4d6837725f3655fbdfebea966476d1255ee18adabe9ed5536455b63336a1f399d  GitPython-2.1.3.tar.gz' > GitPython-2.1.3.tar.gz.sha512
+    echo '3e3af56373d223cfe0d434a305254fadaa6308aac85fae053fd31abfaa014f66bdcc921039a2a1c1650559f37dd056e5839e284f5022586db9cdff5662ee0b8b  expat-2.2.0.tar.gz' > expat-2.2.0.tar.gz.sha512
+    echo '57f73a4ffece65f4e12e30b1d4be4f54f434693ba64d32eca0da036830389854b699a6e0ad6c3d9e847eab73981de6d8ebdb1820cc8a40a5d163aec37ab554aa  curl-7.54.0.tar.gz' > curl-7.54.0.tar.gz.sha512
     echo 'de6409d75a3ff3cf1e5391d3b09126f0bc7e1a40a15f9bee244195638fe2f8481fca032896d8534623e6122ff59aaf669664e27ff89cf1b094a5ce7312f220b7  scipy-0.17.0.tar.gz' > scipy-0.17.0.tar.gz.sha512
     echo '96f3e51b46741450bc6b63779c10ebb4a7066860fe544385d64d1eda52592e376a589ef282ace2e1df73df61c10eab1a0d793abbdaf770e60289494d4bf3bcb4  sqlite-autoconf-3071700.tar.gz' > sqlite-autoconf-3071700.tar.gz.sha512
     echo '977db6e9bc6a5918cceb255981a57e85e7060c0922aefd2968b004d25d704e25a5cb5bbe09eb387e8695581e23e2825d9c40310068fe25ece7e9c23037a21f39  sympy-1.0.tar.gz' > sympy-1.0.tar.gz.sha512
@@ -885,7 +896,6 @@
     [ $INST_SCIPY -eq 1 ] && get_ytproject $SCIPY.tar.gz
     [ $INST_SCIPY -eq 1 ] && get_ytproject blas.tar.gz
     [ $INST_SCIPY -eq 1 ] && get_ytproject $LAPACK.tar.gz
-    [ $INST_GIT -eq 1 ] && get_ytproject $GIT.tar.gz
     if [ $INST_PY3 -eq 1 ]
     then
         get_ytproject $PYTHON3.tgz
@@ -1068,25 +1078,12 @@
     # Install setuptools
     do_setup_py $SETUPTOOLS
 
-    if [ $INST_GIT -eq 1 ]
+    if type -p git &>/dev/null
     then
-        [ ! -e $GIT ] && tar xfz $GIT.tar.gz
-        echo "Installing git"
-        cd $GIT
-        ( ./configure --prefix=${DEST_DIR}/ 2>&1 ) 1>> ${LOG_FILE} || do_exit
-        ( make install 2>&1 ) 1>> ${LOG_FILE} || do_exit
-        ( make clean 2>&1 ) 1>> ${LOG_FILE} || do_exit
-        touch done
-        cd ..
-        GIT_EXE=${DEST_DIR}/bin/git
+        GIT_EXE="git"
     else
-        if type -p git &>/dev/null
-        then
-            GIT_EXE="git"
-        else
-            echo "Cannot find git. Please set INST_GIT=1."
-            do_exit
-        fi
+        echo "Cannot find git. Please install git."
+        do_exit
     fi
 
     if [ -z "$YT_DIR" ]
@@ -1298,14 +1295,6 @@
         echo
         echo "The source for yt is located at:"
         echo "    $YT_DIR"
-        if [ $INST_GIT -eq 1 ]
-        then
-            echo
-            echo "Git has also been installed:"
-            echo
-            echo "$GIT_EXE"
-            echo
-        fi
         echo
         echo "For support, see the website and join the mailing list:"
         echo


https://bitbucket.org/yt_analysis/yt/commits/7ccb203e1125/
Changeset:   7ccb203e1125
Branch:      yt
User:        ngoldbaum
Date:        2017-04-21 01:16:08+00:00
Summary:     don't download curl, expat and git
Affected #:  1 file

diff -r e3ce646a54ac2a1acc20afcff3bfbca22e16599a -r 7ccb203e11252c4b520c7c2e687e1ac3db67948f doc/install_script.sh
--- a/doc/install_script.sh
+++ b/doc/install_script.sh
@@ -49,7 +49,7 @@
                     # in Python 3.
 INST_GIT=1          # Install git or not?  If git is not already installed, yt
                     # cannot be installed from source. Ignored if INST_CONDA=0
-INT_HG=0            # Install Mercurial or not? Ignored if INST_CONDA=0.
+INST_HG=0           # Install Mercurial or not? Ignored if INST_CONDA=0.
 INST_EMBREE=0       # Install dependencies needed for Embree-accelerated 
                     # ray tracing
 
@@ -841,9 +841,6 @@
     LAPACK='lapack-3.4.2'
     PNG='libpng-1.6.3'
     MATPLOTLIB='matplotlib-1.5.1'
-    GIT='git-2.12.2'
-    LIBCURL='curl-7.54.0'
-    EXPAT='expat-2.2.0'
     NOSE='nose-1.3.7'
     NUMPY='numpy-1.11.0'
     GITPYTHON='GitPython-2.1.3'
@@ -874,12 +871,9 @@
     echo '8770214491e31f0a7a3efaade90eee7b0eb20a8a6ab635c5f854d78263f59a1849133c14ef5123d01023f0110cbb9fc6f818da053c01277914ae81473430a952  lapack-3.4.2.tar.gz' > lapack-3.4.2.tar.gz.sha512
     echo '887582e5a22e4cde338aa8fec7a89f6dd31f2f02b8842735f00f970f64582333fa03401cea6d01704083403c7e8b7ebc26655468ce930165673b33efa4bcd586  libpng-1.6.3.tar.gz' > libpng-1.6.3.tar.gz.sha512
     echo 'a0e78b5027a3a49cf8e77dc0d26f5f380dcd80f7b309b6121199acd5e1d94f48482864a9eee3bd397f7ac6f07fe1d3c21bf517217df3c72e8e3d105b7c2ae58e  matplotlib-1.5.1.tar.gz' > matplotlib-1.5.1.tar.gz.sha512
-    echo '67ce429436277c1fd64ee2a48326cdeec4a25a4f3bfa2dec84b5207752f8e09d5061c94dbd2c7f8bedc42f8df2142ed69b002d2d7d350cf6a40ac1e2736514e0  git-2.12.2.tar.gz' > git-2.12.2.tar.gz.sha512
     echo 'e65c914f621f8da06b9ab11a0ff2763d6e29b82ce2aaed56da0e3773dc899d9deb1f20015789d44c65a5dad7214520f5b659b3f8d7695fb207ad3f78e5cf1b62  nose-1.3.7.tar.gz' > nose-1.3.7.tar.gz.sha512
     echo '92c1889397ad013e25da3a0657fc01e787d528fc19c29cc2acd286c3f07d41b984252583457b1b9259fc303afbe9694565cdcf5752eb4ecb950cc7a99ec1ad8b  numpy-1.11.0.tar.gz' > numpy-1.11.0.tar.gz.sha512
     echo '918ff1765a85a818619165c2bcbb0d417f35c979c2f42f1bb7e41636696c0cb4d6837725f3655fbdfebea966476d1255ee18adabe9ed5536455b63336a1f399d  GitPython-2.1.3.tar.gz' > GitPython-2.1.3.tar.gz.sha512
-    echo '3e3af56373d223cfe0d434a305254fadaa6308aac85fae053fd31abfaa014f66bdcc921039a2a1c1650559f37dd056e5839e284f5022586db9cdff5662ee0b8b  expat-2.2.0.tar.gz' > expat-2.2.0.tar.gz.sha512
-    echo '57f73a4ffece65f4e12e30b1d4be4f54f434693ba64d32eca0da036830389854b699a6e0ad6c3d9e847eab73981de6d8ebdb1820cc8a40a5d163aec37ab554aa  curl-7.54.0.tar.gz' > curl-7.54.0.tar.gz.sha512
     echo 'de6409d75a3ff3cf1e5391d3b09126f0bc7e1a40a15f9bee244195638fe2f8481fca032896d8534623e6122ff59aaf669664e27ff89cf1b094a5ce7312f220b7  scipy-0.17.0.tar.gz' > scipy-0.17.0.tar.gz.sha512
     echo '96f3e51b46741450bc6b63779c10ebb4a7066860fe544385d64d1eda52592e376a589ef282ace2e1df73df61c10eab1a0d793abbdaf770e60289494d4bf3bcb4  sqlite-autoconf-3071700.tar.gz' > sqlite-autoconf-3071700.tar.gz.sha512
     echo '977db6e9bc6a5918cceb255981a57e85e7060c0922aefd2968b004d25d704e25a5cb5bbe09eb387e8695581e23e2825d9c40310068fe25ece7e9c23037a21f39  sympy-1.0.tar.gz' > sympy-1.0.tar.gz.sha512


https://bitbucket.org/yt_analysis/yt/commits/7a0095d18d44/
Changeset:   7a0095d18d44
Branch:      yt
User:        ngoldbaum
Date:        2017-04-21 01:40:20+00:00
Summary:     install from the master branch
Affected #:  1 file

diff -r 7ccb203e11252c4b520c7c2e687e1ac3db67948f -r 7a0095d18d446c2dc6405ae9cd2221d0f772ab2d doc/install_script.sh
--- a/doc/install_script.sh
+++ b/doc/install_script.sh
@@ -30,7 +30,7 @@
 # INST_CONDA=0
 # INST_YT_SOURCE=1
 
-BRANCH="yt" # This is the branch we will install from for source installs
+BRANCH="master" # This is the branch we will install from for source installs
 
 # What follows are some other options that you may or may not need to change.
 


https://bitbucket.org/yt_analysis/yt/commits/aad9958444e0/
Changeset:   aad9958444e0
Branch:      yt
User:        ngoldbaum
Date:        2017-05-01 14:38:35+00:00
Summary:     Merged in ngoldbaum/yt (pull request #2587)

Updating install script for git transition

Approved-by: Alexander Lindsay <al007 at illinois.edu>
Affected #:  2 files

diff -r 27fd24ed75b89e653ddf3b1c9c76c742b51130dc -r aad9958444e0d2671cf9983f8fae48a12fac23d7 doc/install_script.sh
--- a/doc/install_script.sh
+++ b/doc/install_script.sh
@@ -30,7 +30,7 @@
 # INST_CONDA=0
 # INST_YT_SOURCE=1
 
-BRANCH="yt" # This is the branch to which we will forcibly update.
+BRANCH="master" # This is the branch we will install from for source installs
 
 # What follows are some other options that you may or may not need to change.
 
@@ -44,11 +44,12 @@
 
 # These options can be set to customize the installation.
 
-INST_PY3=0          # Install Python 3 along with Python 2. If this is turned
+INST_PY3=1          # Install Python 3 instead of Python 2. If this is turned
                     # on, all Python packages (including yt) will be installed
-                    # in Python 3 (except Mercurial, which requires Python 2).
-INST_HG=1           # Install Mercurial or not?  If hg is not already
-                    # installed, yt cannot be installed from source.
+                    # in Python 3.
+INST_GIT=1          # Install git or not?  If git is not already installed, yt
+                    # cannot be installed from source. Ignored if INST_CONDA=0
+INST_HG=0           # Install Mercurial or not? Ignored if INST_CONDA=0.
 INST_EMBREE=0       # Install dependencies needed for Embree-accelerated 
                     # ray tracing
 
@@ -148,6 +149,10 @@
         echo "Please set INST_YT_SOURCE to 1 and re-run."
         exit 1
     fi
+    if [ $INST_GIT -eq 1 ]
+    then
+        INST_GIT=0
+    fi
     DEST_SUFFIX="yt-`uname -m`"
 fi
 
@@ -200,7 +205,7 @@
 {
     CONFIG_FILE=${DEST_DIR}/.yt_config
 
-    echo INST_HG=${INST_HG} > ${CONFIG_FILE}
+    echo INST_GIT=${INST_GIT} > ${CONFIG_FILE}
     echo INST_ZLIB=${INST_ZLIB} >> ${CONFIG_FILE}
     echo INST_BZLIB=${INST_BZLIB} >> ${CONFIG_FILE}
     echo INST_PNG=${INST_PNG} >> ${CONFIG_FILE}
@@ -397,9 +402,10 @@
         echo "  * gcc-{,c++,gfortran}"
         echo "  * make"
         echo "  * patch"
+        echo "  * git"
         echo
         echo "You can accomplish this by executing:"
-        echo "$ sudo yum install gcc gcc-c++ gcc-gfortran make patch zip"
+        echo "$ sudo yum install gcc gcc-c++ gcc-gfortran make patch zip git"
         echo "$ sudo yum install ncurses-devel uuid-devel openssl-devel readline-devel"
     fi
     if [ -f /etc/SuSE-release ] && [ `grep --count SUSE /etc/SuSE-release` -gt 0 ]
@@ -413,11 +419,12 @@
         echo "  * libuuid-devel"
         echo "  * zip"
         echo "  * gcc-c++"
+        echo "  * git"
         echo
         echo "You can accomplish this by executing:"
         echo
         echo "$ sudo zypper install -t pattern devel_C_C++"
-        echo "$ sudo zypper install gcc-c++ libopenssl-devel libuuid-devel zip"
+        echo "$ sudo zypper install git-core gcc-c++ libopenssl-devel libuuid-devel zip"
         echo
         echo "I am also setting special configure arguments to Python to"
         echo "specify control lib/lib64 issues."
@@ -437,10 +444,11 @@
         echo "  * uuid-dev"
         echo "  * libfreetype6-dev"
         echo "  * tk-dev"
+        echo "  * git"
         echo
         echo "You can accomplish this by executing:"
         echo
-        echo "$ sudo apt-get install libssl-dev build-essential libncurses5 libncurses5-dev zip uuid-dev libfreetype6-dev tk-dev"
+        echo "$ sudo apt-get install libssl-dev build-essential libncurses5 libncurses5-dev zip uuid-dev libfreetype6-dev tk-dev git"
         echo
         echo
         echo " Additionally, if you want to put yt's lib dir in your LD_LIBRARY_PATH"
@@ -566,9 +574,9 @@
 get_willwont ${INST_PY3}
 echo "be installing Python 3"
 
-printf "%-18s = %s so I " "INST_HG" "${INST_HG}"
-get_willwont ${INST_HG}
-echo "be installing Mercurial"
+printf "%-18s = %s so I " "INST_GIT" "${INST_GIT}"
+get_willwont ${INST_GIT}
+echo "be installing git"
 
 printf "%-18s = %s so I " "INST_EMBREE" "${INST_EMBREE}"
 get_willwont ${INST_EMBREE}
@@ -640,10 +648,12 @@
 echo "If you'd rather stop, maybe think things over, even grab a sandwich, "
 echo "hit Ctrl-C."
 echo
+
 if [ $INST_YT_SOURCE -ne 0 ]
 then
    host_specific
 fi
+
 if [ $INST_CONDA -eq 0 ]
 then
     if [ ${USED_CONFIG} ]
@@ -679,7 +689,7 @@
 
 if [ $INST_PY3 -eq 1 ]
 then
-     PYTHON_EXEC='python3.5'
+     PYTHON_EXEC='python3'
 else 
      PYTHON_EXEC='python2.7'
 fi
@@ -698,12 +708,7 @@
     [ ! -e $LIB/extracted ] && tar xfz $LIB.tar.gz
     touch $LIB/extracted
     BUILD_ARGS=""
-    if [[ $LIB =~ .*mercurial.* ]]
-    then
-        PYEXE="python2.7"
-    else
-        PYEXE=${PYTHON_EXEC}
-    fi
+    PYEXE=${PYTHON_EXEC}
     case $LIB in
         *h5py*)
             pushd $LIB &> /dev/null
@@ -836,10 +841,9 @@
     LAPACK='lapack-3.4.2'
     PNG='libpng-1.6.3'
     MATPLOTLIB='matplotlib-1.5.1'
-    MERCURIAL='mercurial-3.7.3'
     NOSE='nose-1.3.7'
     NUMPY='numpy-1.11.0'
-    PYTHON_HGLIB='python-hglib-2.0'
+    GITPYTHON='GitPython-2.1.3'
     ROCKSTAR='rockstar-0.99.6'
     SCIPY='scipy-0.17.0'
     SQLITE='sqlite-autoconf-3071700'
@@ -867,10 +871,9 @@
     echo '8770214491e31f0a7a3efaade90eee7b0eb20a8a6ab635c5f854d78263f59a1849133c14ef5123d01023f0110cbb9fc6f818da053c01277914ae81473430a952  lapack-3.4.2.tar.gz' > lapack-3.4.2.tar.gz.sha512
     echo '887582e5a22e4cde338aa8fec7a89f6dd31f2f02b8842735f00f970f64582333fa03401cea6d01704083403c7e8b7ebc26655468ce930165673b33efa4bcd586  libpng-1.6.3.tar.gz' > libpng-1.6.3.tar.gz.sha512
     echo 'a0e78b5027a3a49cf8e77dc0d26f5f380dcd80f7b309b6121199acd5e1d94f48482864a9eee3bd397f7ac6f07fe1d3c21bf517217df3c72e8e3d105b7c2ae58e  matplotlib-1.5.1.tar.gz' > matplotlib-1.5.1.tar.gz.sha512
-    echo '7f9f97229e40c7092c16ccf227b19a08a9839d8ce19a9d057341fff75876bff32241ee9aa10eab293f779ea3e8a1d97577597187bd96251fb499cbb1075a82cf  mercurial-3.7.3.tar.gz' > mercurial-3.7.3.tar.gz.sha512
     echo 'e65c914f621f8da06b9ab11a0ff2763d6e29b82ce2aaed56da0e3773dc899d9deb1f20015789d44c65a5dad7214520f5b659b3f8d7695fb207ad3f78e5cf1b62  nose-1.3.7.tar.gz' > nose-1.3.7.tar.gz.sha512
     echo '92c1889397ad013e25da3a0657fc01e787d528fc19c29cc2acd286c3f07d41b984252583457b1b9259fc303afbe9694565cdcf5752eb4ecb950cc7a99ec1ad8b  numpy-1.11.0.tar.gz' > numpy-1.11.0.tar.gz.sha512
-    echo '647cc82424783efc3d74540e34976af66acc35fc36d66afba169508946cc62027910c7e41dc9d11ec88c15d6b1e113ce22c2781711ea324de58db3b24d5079c4  python-hglib-2.0.tar.gz' > python-hglib-2.0.tar.gz.sha512
+    echo '918ff1765a85a818619165c2bcbb0d417f35c979c2f42f1bb7e41636696c0cb4d6837725f3655fbdfebea966476d1255ee18adabe9ed5536455b63336a1f399d  GitPython-2.1.3.tar.gz' > GitPython-2.1.3.tar.gz.sha512
     echo 'de6409d75a3ff3cf1e5391d3b09126f0bc7e1a40a15f9bee244195638fe2f8481fca032896d8534623e6122ff59aaf669664e27ff89cf1b094a5ce7312f220b7  scipy-0.17.0.tar.gz' > scipy-0.17.0.tar.gz.sha512
     echo '96f3e51b46741450bc6b63779c10ebb4a7066860fe544385d64d1eda52592e376a589ef282ace2e1df73df61c10eab1a0d793abbdaf770e60289494d4bf3bcb4  sqlite-autoconf-3071700.tar.gz' > sqlite-autoconf-3071700.tar.gz.sha512
     echo '977db6e9bc6a5918cceb255981a57e85e7060c0922aefd2968b004d25d704e25a5cb5bbe09eb387e8695581e23e2825d9c40310068fe25ece7e9c23037a21f39  sympy-1.0.tar.gz' > sympy-1.0.tar.gz.sha512
@@ -887,16 +890,19 @@
     [ $INST_SCIPY -eq 1 ] && get_ytproject $SCIPY.tar.gz
     [ $INST_SCIPY -eq 1 ] && get_ytproject blas.tar.gz
     [ $INST_SCIPY -eq 1 ] && get_ytproject $LAPACK.tar.gz
-    [ $INST_HG -eq 1 ] && get_ytproject $MERCURIAL.tar.gz
-    [ $INST_PY3 -eq 1 ] && get_ytproject $PYTHON3.tgz
+    if [ $INST_PY3 -eq 1 ]
+    then
+        get_ytproject $PYTHON3.tgz
+    else
+        get_ytproject $PYTHON2.tgz
+    fi
     [ $INST_H5PY -eq 1 ] && get_ytproject $H5PY.tar.gz
     [ $INST_NOSE -eq 1 ] && get_ytproject $NOSE.tar.gz
     [ $INST_ASTROPY -eq 1 ] && get_ytproject $ASTROPY.tar.gz
-    get_ytproject $PYTHON2.tgz
     get_ytproject $NUMPY.tar.gz
     get_ytproject $MATPLOTLIB.tar.gz
     get_ytproject $CYTHON.tar.gz
-    get_ytproject $PYTHON_HGLIB.tar.gz
+    get_ytproject $GITPYTHON.tar.gz
     get_ytproject $SYMPY.tar.gz
     get_ytproject $SETUPTOOLS.tar.gz
 
@@ -936,7 +942,7 @@
             cd $ZLIB
             ( ./configure --shared --prefix=${DEST_DIR}/ 2>&1 ) 1>> ${LOG_FILE} || do_exit
             ( make install 2>&1 ) 1>> ${LOG_FILE} || do_exit
-            ( make clean 2>&1) 1>> ${LOG_FILE} || do_exit
+            ( make clean 2>&1 ) 1>> ${LOG_FILE} || do_exit
             touch done
             cd ..
         fi
@@ -1016,37 +1022,11 @@
         fi
     fi
 
-    if [ ! -e $PYTHON2/done ]
-    then
-        echo "Installing Python 2. This may take a while, but don't worry. yt loves you."
-        [ ! -e $PYTHON2 ] && tar xfz $PYTHON2.tgz
-        cd $PYTHON2
-        ( ./configure --prefix=${DEST_DIR}/ ${PYCONF_ARGS} 2>&1 ) 1>> ${LOG_FILE} || do_exit
-        
-        ( make ${MAKE_PROCS} 2>&1 ) 1>> ${LOG_FILE} || do_exit
-        ( make install 2>&1 ) 1>> ${LOG_FILE} || do_exit
-        ( ln -sf ${DEST_DIR}/bin/python2.7 ${DEST_DIR}/bin/pyyt 2>&1 ) 1>> ${LOG_FILE}
-        ( make clean 2>&1) 1>> ${LOG_FILE} || do_exit
-        touch done
-        cd ..
-    fi
-
-    ( ${DEST_DIR}/bin/python -c "import _ssl" 2>&1 ) 1>> ${LOG_FILE}
-    RESULT=$?
-    if  [ $RESULT -ne 0 ]
-    then
-        echo "Unable to import the python SSL bindings."
-        echo "This means that OpenSSL is not installed or your system's OpenSSL"
-        echo "installation is out of date."
-        echo "Please install OpenSSL or set INST_CONDA=1"
-        do_exit
-    fi
-
     if [ $INST_PY3 -eq 1 ]
     then
         if [ ! -e $PYTHON3/done ]
         then
-            echo "Installing Python 3. Because two Pythons are better than one."
+            echo "Installing Python 3"
             [ ! -e $PYTHON3 ] && tar xfz $PYTHON3.tgz
             cd $PYTHON3
             ( ./configure --prefix=${DEST_DIR}/ ${PYCONF_ARGS} 2>&1 ) 1>> ${LOG_FILE} || do_exit
@@ -1060,6 +1040,31 @@
             touch done
             cd ..
         fi
+    else
+        if [ ! -e $PYTHON2/done ]
+        then
+            echo "Installing Python 2. This may take a while, but don't worry. yt loves you."
+            [ ! -e $PYTHON2 ] && tar xfz $PYTHON2.tgz
+            cd $PYTHON2
+            ( ./configure --prefix=${DEST_DIR}/ ${PYCONF_ARGS} 2>&1 ) 1>> ${LOG_FILE} || do_exit
+            ( make ${MAKE_PROCS} 2>&1 ) 1>> ${LOG_FILE} || do_exit
+            ( make install 2>&1 ) 1>> ${LOG_FILE} || do_exit
+            ( ln -sf ${DEST_DIR}/bin/python2.7 ${DEST_DIR}/bin/pyyt 2>&1 ) 1>> ${LOG_FILE}
+            ( make clean 2>&1) 1>> ${LOG_FILE} || do_exit
+            touch done
+            cd ..
+        fi
+    fi
+
+    ( ${DEST_DIR}/bin/python -c "import _ssl" 2>&1 ) 1>> ${LOG_FILE}
+    RESULT=$?
+    if  [ $RESULT -ne 0 ]
+    then
+        echo "Unable to import the python SSL bindings."
+        echo "This means that OpenSSL is not installed or your system's OpenSSL"
+        echo "installation is out of date."
+        echo "Please install OpenSSL or set INST_CONDA=1"
+        do_exit
     fi
 
     export PYTHONPATH=${DEST_DIR}/lib/${PYTHON_EXEC}/site-packages/
@@ -1067,19 +1072,12 @@
     # Install setuptools
     do_setup_py $SETUPTOOLS
 
-    if [ $INST_HG -eq 1 ]
+    if type -p git &>/dev/null
     then
-        do_setup_py $MERCURIAL
-        export HG_EXEC=${DEST_DIR}/bin/hg
+        GIT_EXE="git"
     else
-        # We assume that hg can be found in the path.
-        if type -P hg &>/dev/null
-        then
-            export HG_EXEC=hg
-        else
-            echo "Cannot find mercurial.  Please set INST_HG=1."
-            do_exit
-        fi
+        echo "Cannot find git. Please install git."
+        do_exit
     fi
 
     if [ -z "$YT_DIR" ]
@@ -1090,20 +1088,14 @@
         elif [ -e $ORIG_PWD/../yt/mods.py ]
         then
             YT_DIR=`dirname $ORIG_PWD`
-        elif [ ! -e yt-hg ]
+        elif [ ! -e yt-git ]
         then
             echo "Cloning yt"
-            YT_DIR="$PWD/yt-hg/"
-            ( ${HG_EXEC} --debug clone https://bitbucket.org/yt_analysis/yt-supplemental/ 2>&1 ) 1>> ${LOG_FILE}
-            # Recently the hg server has had some issues with timeouts.  In lieu of
-            # a new webserver, we are now moving to a three-stage process.
-            # First we clone the repo, but only up to r0.
-            ( ${HG_EXEC} --debug clone https://bitbucket.org/yt_analysis/yt/ ./yt-hg 2>&1 ) 1>> ${LOG_FILE}
-            # Now we update to the branch we're interested in.
-            ( ${HG_EXEC} -R ${YT_DIR} up -C ${BRANCH} 2>&1 ) 1>> ${LOG_FILE}
-        elif [ -e yt-hg ]
+            YT_DIR="$PWD/yt-git/"
+            ( ${GIT_EXE} clone https://github.com/yt-project/yt/ ${YT_DIR} 2>&1 ) 1>> ${LOG_FILE}
+        elif [ -e yt-git ]
         then
-            YT_DIR="$PWD/yt-hg/"
+            YT_DIR="$PWD/yt-git/"
         fi
         echo Setting YT_DIR=${YT_DIR}
     fi
@@ -1206,7 +1198,7 @@
     then
         do_setup_py $ASTROPY
     fi
-    do_setup_py $PYTHON_HGLIB
+    do_setup_py $GITPYTHON
     do_setup_py $SYMPY
     [ $INST_PYX -eq 1 ] && do_setup_py $PYX
 
@@ -1220,11 +1212,9 @@
             echo "Building Rockstar"
             if [ ! -e rockstar ]
             then
-                ( hg clone http://bitbucket.org/MatthewTurk/rockstar 2>&1 ) 1>> ${LOG_FILE}
+                ( ${GIT_EXE} clone https://github.com/yt-project/rockstar 2>&1 ) 1>> ${LOG_FILE}
             fi
             cd rockstar
-            ( hg pull 2>&1 ) 1>> ${LOG_FILE}
-            ( hg up -C tip 2>&1 ) 1>> ${LOG_FILE}
             ( make lib 2>&1 ) 1>> ${LOG_FILE} || do_exit
             cp librockstar.so ${DEST_DIR}/lib
             ROCKSTAR_DIR=${DEST_DIR}/src/rockstar
@@ -1234,10 +1224,9 @@
         fi
     fi
     
-    echo "Doing yt update, wiping local changes and updating to branch ${BRANCH}"
     MY_PWD=`pwd`
     cd $YT_DIR
-    ( ${HG_EXEC} pull 2>1 && ${HG_EXEC} up -C 2>1 ${BRANCH} 2>&1 ) 1>> ${LOG_FILE}
+    ( ${GIT_EXE} pull 2>1 && ${GIT_EXE} checkout ${BRANCH} 2>&1 ) 1>> ${LOG_FILE}
 
     echo "Installing yt"
     [ $INST_PNG -eq 1 ] && echo $PNG_DIR > png.cfg
@@ -1300,14 +1289,6 @@
         echo
         echo "The source for yt is located at:"
         echo "    $YT_DIR"
-        if [ $INST_HG -eq 1 ]
-        then
-            echo
-            echo "Mercurial has also been installed:"
-            echo
-            echo "$DEST_DIR/bin/hg"
-            echo
-        fi
         echo
         echo "For support, see the website and join the mailing list:"
         echo
@@ -1399,6 +1380,11 @@
     YT_DEPS+=('jupyter')
     YT_DEPS+=('ipython')
     YT_DEPS+=('sphinx')
+    if [ ${INST_GIT} -eq 1 ]
+    then
+        YT_DEPS+=('git')
+        YT_DEPS+=('gitpython')
+    fi
     if [ $INST_H5PY -ne 0 ]
     then
         YT_DEPS+=('h5py')
@@ -1418,7 +1404,7 @@
         YT_DEPS+=('astropy')
     fi
     YT_DEPS+=('conda-build')
-    if [ $INST_PY3 -eq 0 ]
+    if [ $INST_PY3 -eq 0 ] && [ $INST_HG -eq 1 ]
     then
        YT_DEPS+=('mercurial')
     fi
@@ -1431,22 +1417,22 @@
     
     log_cmd ${DEST_DIR}/bin/conda update --yes conda
     
+    GIT_EXE=${DEST_DIR}/bin/git
+
     log_cmd echo "DEPENDENCIES" ${YT_DEPS[@]}
     for YT_DEP in "${YT_DEPS[@]}"; do
         echo "Installing $YT_DEP"
-        log_cmd ${DEST_DIR}/bin/conda install --yes ${YT_DEP}
+        log_cmd ${DEST_DIR}/bin/conda install -c conda-forge --yes ${YT_DEP}
     done
 
-    if [ $INST_PY3 -eq 1 ]
+    if [ $INST_PY3 -eq 1 ] && [ $INST_HG -eq 1 ]
     then
         echo "Installing mercurial"
         log_cmd ${DEST_DIR}/bin/conda create -y -n py27 python=2.7 mercurial
         log_cmd ln -s ${DEST_DIR}/envs/py27/bin/hg ${DEST_DIR}/bin
     fi
 
-    log_cmd ${DEST_DIR}/bin/pip install python-hglib
-
-    log_cmd ${DEST_DIR}/bin/hg clone https://bitbucket.org/yt_analysis/yt_conda ${DEST_DIR}/src/yt_conda
+    log_cmd ${GIT_EXE} clone https://github.com/yt-project/yt_conda ${DEST_DIR}/src/yt_conda
     
     if [ $INST_EMBREE -eq 1 ]
     then
@@ -1480,7 +1466,7 @@
     if [ $INST_ROCKSTAR -eq 1 ]
     then
         echo "Building Rockstar"
-        ( ${DEST_DIR}/bin/hg clone http://bitbucket.org/MatthewTurk/rockstar ${DEST_DIR}/src/rockstar/ 2>&1 ) 1>> ${LOG_FILE}
+        ( ${GIT_EXE} clone https://github.com/yt-project/rockstar ${DEST_DIR}/src/rockstar/ 2>&1 ) 1>> ${LOG_FILE}
         ROCKSTAR_PACKAGE=$(${DEST_DIR}/bin/conda build ${DEST_DIR}/src/yt_conda/rockstar --output)
         log_cmd ${DEST_DIR}/bin/conda build ${DEST_DIR}/src/yt_conda/rockstar
         log_cmd ${DEST_DIR}/bin/conda install $ROCKSTAR_PACKAGE
@@ -1504,9 +1490,9 @@
         log_cmd ${DEST_DIR}/bin/conda install -c conda-forge --yes yt
     else
         echo "Building yt from source"
-        YT_DIR="${DEST_DIR}/src/yt-hg"
-        log_cmd ${DEST_DIR}/bin/hg clone https://bitbucket.org/yt_analysis/yt ${YT_DIR}
-        log_cmd ${DEST_DIR}/bin/hg -R ${YT_DIR} up -C ${BRANCH}
+        YT_DIR="${DEST_DIR}/src/yt-git"
+        log_cmd ${GIT_EXE} clone https://github.com/yt-project/yt ${YT_DIR}
+        log_cmd ${GIT_EXE} -C ${YT_DIR} checkout ${BRANCH}
         if [ $INST_EMBREE -eq 1 ]
         then
             echo $DEST_DIR > ${YT_DIR}/embree.cfg

diff -r 27fd24ed75b89e653ddf3b1c9c76c742b51130dc -r aad9958444e0d2671cf9983f8fae48a12fac23d7 tests/test_install_script.py
--- a/tests/test_install_script.py
+++ b/tests/test_install_script.py
@@ -8,7 +8,7 @@
 
 # dependencies that are always installed
 REQUIRED_DEPS = [
-    'mercurial',
+    'git',
     'jupyter',
     'numpy',
     'matplotlib',
@@ -17,12 +17,11 @@
     'nose',
     'sympy',
     'setuptools',
-    'hglib'
 ]
 
 # dependencies that aren't installed by default
 OPTIONAL_DEPS = [
-    'unstructured',
+    'embree',
     'pyx',
     'rockstar',
     'scipy',
@@ -31,17 +30,18 @@
 
 # dependencies that are only installable when yt is built from source
 YT_SOURCE_ONLY_DEPS = [
-    'unstructured',
+    'embree',
     'rockstar'
 ]
 
-# dependencies that are only installable when yt is built from source under conda
+# dependencies that are only installable when yt is built from source under 
+# conda
 YT_SOURCE_CONDA_ONLY_DEPS = [
-    'unstructured'
+    'embree'
 ]
 
 DEPENDENCY_IMPORT_TESTS = {
-    'unstructured': "from yt.utilities.lib import mesh_traversal",
+    'embree': "from yt.utilities.lib import mesh_traversal",
     'rockstar': ("from yt.analysis_modules.halo_finding.rockstar "
                  "import rockstar_interface")
 }
@@ -60,7 +60,7 @@
     finally:
         if len(output.splitlines()) > 25:
             print ('truncated output:')
-            print ('\n'.join((output.splitlines())[-25:]))
+            print ('\n'.join((output.decode().splitlines())[-25:]))
         else:
             print (output)
 
@@ -119,10 +119,10 @@
             continue
         if conda is False and dep in YT_SOURCE_CONDA_ONLY_DEPS:
             continue
-        elif dep == 'mercurial':
-            hg_path = os.sep.join([yt_dir, 'bin', 'hg'])
-            call_unix_command('{} --version'.format(hg_path))
-        elif dep in DEPENDENCY_IMPORT_TESTS:
+        if dep == 'git':
+            git_path = os.sep.join([yt_dir, 'bin', 'git'])
+            call_unix_command('{} --version'.format(git_path))
+        if dep in DEPENDENCY_IMPORT_TESTS:
             cmd = "{} -c '{}'"
             if dep == 'rockstar':
                 cmd = 'LD_LIBRARY_PATH={} '.format(

Repository URL: https://bitbucket.org/yt_analysis/yt/

--

This is a commit notification from bitbucket.org. You are receiving
this because you have the service enabled, addressing the recipient of
this email.



More information about the yt-svn mailing list