Bug 13436

Summary: ltp RDEPENDS on python2 not python3
Product: [Build System, Metadata & Runtime] OE-Core Reporter: Ross Burton <ross.burton>
Component: oe-core otherAssignee: Alexander Kanavin <alex.kanavin>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: Medium+ CC: randy.macleod, richard.purdie, yi.zhao
Version: 0.0.0   
Target Milestone: 2.8 M3   
Hardware: x86   
OS: Multiple   
Whiteboard:
OS type for building Yocto: --- Type of Regression: ---
Verified: Documentation change: No (bug/feature does not impact docs)

Description Ross Burton 2019-07-11 12:33:22 UTC
Python 2 is on the way out, but ltp RDEPENDS on it.  I think this is actually fairly trivial to fix.  Inside the ltp checkout:

$ git find-file \\.py|xargs head -q -n1|sort|uniq
#!/usr/bin/env python3

So all of the code is using python3 hashbangs already.

The only possible problem is hardcoded use of python not python3 (or the found python binary at configure time):

testcases/network/nfsv4/acl/runtest:rsh -n $REMOTEHOST python $PWD/create_users.py -u 50 -g 50
testcases/network/nfsv4/acl/runtest:python create_users.py -u 50 -g 50
testcases/network/nfsv4/acl/runtest:python test_long_acl.py -l $MAXLENGTH -p $NFSMNTDIR/lacl-testdir
testcases/network/nfsv4/acl/runtest:python setacl_stress.py -n 100 -u $USER_NB -g $GRP_NB -f $FILE_NB -p $NFSMNTDIR
testcases/network/nfsv4/acl/runtest:python cleanusers.py
testcases/network/nfsv4/acl/runtest:python cleangroups.py
testcases/network/nfsv4/acl/runtest:rsh -n $REMOTEHOST python $PWD/cleanusers.py
testcases/realtime/func/pi-tests/run_auto.sh:PYTHONPATH=../../  python parse-testpi1.py $LOG_FILE 2>&1 | tee -a $LOG_FILE
testcases/realtime/func/pi-tests/run_auto.sh:PYTHONPATH=../../  python parse-testpi2.py $LOG_FILE 2>&1 | tee -a $LOG_FILE
testcases/realtime/func/pi-tests/run_auto.sh:PYTHONPATH=../../  python parse-testpi1.py $LOG_FILE 2>&1 | tee -a $LOG_FILE

Are these actually used? Can we send a patch upstream to change these to python3?
Comment 1 Randy MacLeod 2019-08-29 14:53:28 UTC
Alex gets the bug since he has sent a patch. Please close once merged.