Skip to content

Commit 74dbc41

Browse files
committed
Review updates
1 parent d6a5c88 commit 74dbc41

File tree

1 file changed

+9
-10
lines changed

1 file changed

+9
-10
lines changed

pyperf/pyperf_run

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ PATH="${PATH}:/usr/local/bin"
44
export PATH
55
python_pkgs=""
66
python_exec=""
7-
PYPERF_VERSION=1.0.4
7+
PYPERF_VERSION="1.0.4"
88
#
99
# To make sure.
1010
#
@@ -17,7 +17,7 @@ exit_out()
1717
usage()
1818
{
1919
echo "$1 Usage:"
20-
echo "--pyperf_version <vers number>: Versionof pyperf to run, default is $PYPERF_VERSION."
20+
echo "--pyperf_version <vers number>: Version of pyperf to run, default is $PYPERF_VERSION."
2121
echo "--python_exec_path: Python to set via alternatives"
2222
echo "--python_pkgs: comma seprated list of python packages to install"
2323
source test_tools/general_setup --usage
@@ -252,6 +252,13 @@ done
252252

253253
if [ $to_pbench -eq 0 ]; then
254254
rm -rf pyperformance
255+
#
256+
# Install pip/pip3
257+
#
258+
python3 -m ensurepip --upgrade
259+
if [[ $? -ne 0 ]]; then
260+
exit_out "Failed: python3 -m ensurepip --upgrade" 1
261+
fi
255262
python3 -m pip install pyperformance==$PYPERF_VERSION
256263
if [ $? -ne 0 ]; then
257264
exit_out "python3 -m pip install pyperformance==$PYPERF_VERSION: failed" 1
@@ -271,14 +278,6 @@ if [ $to_pbench -eq 0 ]; then
271278
alternatives --remove-all python
272279
alternatives --install /usr/bin/python python $python_exec 1
273280
fi
274-
#
275-
# Install pip/pip3
276-
#
277-
wget https://bootstrap.pypa.io/get-pip.py
278-
if [[ $? -ne 0 ]]; then
279-
exit_out "Failed: wget https://bootstrap.pypa.io/get-pip.py" 1
280-
fi
281-
python3 ./get-pip.py
282281
pip3_install psutil
283282
pip3_install packaging
284283
pip3_install pyparsing

0 commit comments

Comments
 (0)