]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
qa/workunits: python -> python3 throughout 32359/head
authorSage Weil <sage@redhat.com>
Thu, 19 Dec 2019 18:38:03 +0000 (12:38 -0600)
committerSage Weil <sage@redhat.com>
Thu, 19 Dec 2019 18:38:47 +0000 (12:38 -0600)
Signed-off-by: Sage Weil <sage@redhat.com>
qa/workunits/cephtool/test.sh
qa/workunits/fs/misc/rstats.sh
qa/workunits/fs/snaps/snaptest-snap-rename.sh
qa/workunits/mon/caps.py
qa/workunits/mon/ping.py
qa/workunits/mon/test_mon_config_key.py
qa/workunits/rados/test_large_omap_detection.py
qa/workunits/rbd/notify_master.sh
qa/workunits/rbd/notify_slave.sh
qa/workunits/rbd/test_lock_fence.sh

index 0733139117baa62555e8bcc30b62b12c1cfa30be..d30fb3badae11e81321e92fe8a387a27b0f589b1 100755 (executable)
@@ -798,7 +798,7 @@ function wait_mds_active()
 function get_mds_gids()
 {
     fs_name=$1
-    ceph fs get $fs_name --format=json | python -c "import json; import sys; print ' '.join([m['gid'].__str__() for m in json.load(sys.stdin)['mdsmap']['info'].values()])"
+    ceph fs get $fs_name --format=json | python3 -c "import json; import sys; print(' '.join([m['gid'].__str__() for m in json.load(sys.stdin)['mdsmap']['info'].values()]))"
 }
 
 function fail_all_mds()
@@ -819,7 +819,7 @@ function fail_all_mds()
 
 function remove_all_fs()
 {
-  existing_fs=$(ceph fs ls --format=json | python -c "import json; import sys; print ' '.join([fs['name'] for fs in json.load(sys.stdin)])")
+  existing_fs=$(ceph fs ls --format=json | python3 -c "import json; import sys; print(' '.join([fs['name'] for fs in json.load(sys.stdin)]))")
   for fs_name in $existing_fs ; do
       echo "Removing fs ${fs_name}..."
       fail_all_mds $fs_name
index 4c32edb234fc20260e43ed3e3d9adc806f5689ff..e6b3eddf287e8dff26e7e1332ea56cba93a99cbb 100755 (executable)
@@ -33,7 +33,7 @@ check_rctime() {
 # does not notify ceph-fuse about it. Use fsync(3) instead.
 fsync_path() {
        cmd="import os; fd=os.open(\"$1\", os.O_RDONLY); os.fsync(fd); os.close(fd)"
-       python -c "$cmd"
+       python3 -c "$cmd"
 }
 
 set -e
index 414ba0e35ef486b53f7961f3a6b2ba11e680d958..9301a2963775ea7956efdc3abea6693d9fa622ea 100755 (executable)
@@ -22,9 +22,9 @@ expect_failure mv d1/d2/.snap/_foo_* d1/d2/.snap/_foo_1
 # can't rename snapshot to different directroy
 expect_failure mv d1/d2/.snap/bar d1/.snap/
 # can't overwrite existing snapshot
-expect_failure python -c "import os; os.rename('d1/d3/.snap/foo', 'd1/d3/.snap/bar')"
+expect_failure python3 -c "import os; os.rename('d1/d3/.snap/foo', 'd1/d3/.snap/bar')"
 # can't move snaphost out of snapdir
-expect_failure python -c "import os; os.rename('d1/.snap/foo', 'd1/foo')"
+expect_failure python3 -c "import os; os.rename('d1/.snap/foo', 'd1/foo')"
 
 rmdir d1/.snap/foo
 rmdir d1/d2/.snap/bar
index 20bb9e912dca8909d7db8b3c8db3dd6251f2a10a..f20aa6264e54ab501a9f789a6b6c662b9881005f 100644 (file)
@@ -1,4 +1,4 @@
-#!/usr/bin/python
+#!/usr/bin/python3
 
 from __future__ import print_function
 
index 1773c7369317d0d88fa57cfa4a77e5597aa7d712..a745976824d8a29cfc9e46404b28193163a591fe 100755 (executable)
@@ -1,4 +1,4 @@
-#!/usr/bin/python
+#!/usr/bin/python3
 
 import json
 import shlex
index c0cb8299d9554ee1457f5db79397750de5742c79..285d1f4cea6ad28ce8e534a3f97907aeecf44faa 100755 (executable)
@@ -1,4 +1,4 @@
-#!/usr/bin/python
+#!/usr/bin/python3
 #
 # test_mon_config_key - Test 'ceph config-key' interface
 #
index 7b09dfd9071878d1aff259d20824a53a9a411b43..84e08088a4a59da107f6c1582854f7a7281e42b9 100755 (executable)
@@ -1,4 +1,4 @@
-#!/usr/bin/python
+#!/usr/bin/python3
 # -*- mode:python -*-
 # vim: ts=4 sw=4 smarttab expandtab
 #
index 6ebea31ec8055947820987299b4355a856a25173..99ccd74db2d07621c0b4c36e0d8ec5ad9ddaf878 100755 (executable)
@@ -1,5 +1,5 @@
 #!/bin/sh -ex
 
 relpath=$(dirname $0)/../../../src/test/librbd
-python $relpath/test_notify.py master
+python3 $relpath/test_notify.py master
 exit 0
index ea66161aefa249bb86e44b5e4b60204884646fac..7f49a0c7d06dbf92216ef8cd8e6e5cf07feb59f5 100755 (executable)
@@ -1,5 +1,5 @@
 #!/bin/sh -ex
 
 relpath=$(dirname $0)/../../../src/test/librbd
-python $relpath/test_notify.py slave
+python3 $relpath/test_notify.py slave
 exit 0
index e425e161d00284d61737d527a570ff85389bee07..fd8fa6347d224f67a2b88a134276881b495f97d0 100755 (executable)
@@ -10,7 +10,7 @@ RBDRW=$RELPATH/rbdrw.py
 rbd create $IMAGE --size 10 --image-format 2 --image-shared || exit 1
 
 # rbdrw loops doing I/O to $IMAGE after locking with lockid $LOCKID
-python $RBDRW $IMAGE $LOCKID &
+python3 $RBDRW $IMAGE $LOCKID &
 iochild=$!
 
 # give client time to lock and start reading/writing