X-Git-Url: https://arthur.barton.de/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=lib%2Fbup%2Fcompat.py;fp=lib%2Fbup%2Fcompat.py;h=39dd81063e25b84246129af00ca9165e0ed27c4f;hb=073f1e521cdfc39d302eaeac49745b1f1a25a1c0;hp=1ed2d0f70c9fc18f7afc2011a2e55381aa047ca4;hpb=dd5351bd3ca731fa5caada713ce522af84edef58;p=bup.git diff --git a/lib/bup/compat.py b/lib/bup/compat.py index 1ed2d0f..39dd810 100644 --- a/lib/bup/compat.py +++ b/lib/bup/compat.py @@ -16,6 +16,7 @@ if py3: from os import environb as environ from os import fsdecode, fsencode from shlex import quote + ModuleNotFoundError = ModuleNotFoundError input = input range = range str_type = str @@ -64,6 +65,8 @@ if py3: else: # Python 2 + ModuleNotFoundError = ImportError + def fsdecode(x): return x