11522 illumos-gate has some runtime dependencies on Python 2.7

Review Request #2489 — Created Jan. 15, 2020 and updated — Latest diff uploaded

alp
illumos-gate
11522, 12192
general

There are two issues - 1) illumos-gate still has runtime dependencies on Python 2.7 and 2) some python 3 modules don't work as expected

Testing done:
1) Built gate with BUILDPY2='#'
- pyzfs.py and /opt/test-runner/bin/run have python3.5 shebang
- /opt/util-tests/bin/utiltest passes (when /opt/util-tests/runfiles/openindiana.run symlink to default.run is created)
- the following commands
/usr/lib/zfs/pyzfs.py allow user mount rpool/export/home/userhome
/usr/lib/zfs/pyzfs.py allow rpool/export/home/userhome
/usr/lib/zfs/pyzfs.py unallow user mount rpool/export/home/userhome
work
- Run the following with Python 3.5
import libbe_py as be
be.beCopy('test', 'illumos-py3',None, None, {'ru.rsu.cc:test':'value'})

New BE is created, zfs dataset has ru.rsu.cc:test property set to value.

2) Built gate with unset BUILDPY2, BUILDPY3
- pyzfs.py and /opt/test-runner/bin/run have python2.7 shebang
- /opt/util-tests/bin/utiltest passes (when /opt/util-tests/runfiles/openindiana.run symlink to default.run is created)
- the following commands
/usr/lib/zfs/pyzfs.py allow user mount rpool/export/home/userhome
/usr/lib/zfs/pyzfs.py allow rpool/export/home/userhome
/usr/lib/zfs/pyzfs.py unallow user mount rpool/export/home/userhome
work
- Run the following with Python 2.7
import libbe_py as be
be.beCopy('test2', 'illumos-py3',None, None, {'ru.rsu.cc:test2':'value2'})

New BE is created, zfs dataset has ru.rsu.cc:test2 property set to value2.

Loading...