Open majorcrash opened 5 years ago
To make it work with python3.7 modify this line. Line 55:
for seg in pvs.split("\n"):
Replace:
for seg in pvs.decode().split("\n"):
that's not enough to make pvshrink python compatible, there are other errors
after some search i found a version which seems to correctly being ported to python3 and which apparently also still works with python2 :
https://github.com/sensimple-contrib/pvshrink
these are the 2 commits which make it python2 compatible:
https://github.com/sensimple-contrib/pvshrink/commits?author=jsalatiel
could you apply those to your version @pdw-mb ?
what about submitting this upstream to the lvm2 project at http://sourceware.org/lvm2/ ?
this is a very useful tool !
nice! thanks !
This deserves a PR! #3
On Ubuntu 18.04
!/usr/bin/python2.7