MuntashirAkon/AppManager · error · BackupException
Unsupported compression type: ${compressionType}
Error message
Unsupported compression type: ${compressionType} What it means
readPropFile() parses the app_apk_codec property of an OAndBackup prop file into a tar type; only GZIP and BZIP2 are accepted. Any other value (missing, empty, or an unsupported codec) throws BackupException("Unsupported compression type: ..."). This rejects prop files describing archives App Manager's TB format cannot handle.
Source
Thrown at app/src/main/java/io/github/muntashirakon/AppManager/backup/convert/TBConverter.java:395
metadataV2.label = prop.getProperty("app_label");
metadataV2.packageName = mPackageName;
metadataV2.versionName = prop.getProperty("app_version_name");
metadataV2.versionCode = Integer.parseInt(prop.getProperty("app_version_code"));
metadataV2.isSystem = "1".equals(prop.getProperty("app_is_system"));
metadataV2.isSplitApk = false;
metadataV2.splitConfigs = ArrayUtils.emptyArray(String.class);
metadataV2.hasRules = false;
metadataV2.backupTime = mBackupTime;
metadataV2.crypto = CryptoUtils.MODE_NO_ENCRYPTION; // We only support no encryption mode for TB backups
metadataV2.apkName = mPackageName + "-" + prop.getProperty("app_apk_md5") + ".apk";
metadataV2.userId = UserHandleHidden.myUserId();
// Compression type
String compressionType = prop.getProperty("app_apk_codec");
if ("GZIP".equals(compressionType)) {
metadataV2.tarType = TAR_GZIP;
} else if ("BZIP2".equals(compressionType)) {
metadataV2.tarType = TAR_BZIP2;
} else throw new BackupException("Unsupported compression type: " + compressionType);
// Flags
metadataV2.flags = new BackupFlags(BackupFlags.BACKUP_MULTIPLE);
try {
mFilesToBeDeleted.add(getDataFile(Paths.trimPathExtension(mPropFile.getName()), metadataV2.tarType));
// No error = data file exists
metadataV2.flags.addFlag(BackupFlags.BACKUP_INT_DATA);
if ("1".equals(prop.getProperty("has_external_data"))) {
metadataV2.flags.addFlag(BackupFlags.BACKUP_EXT_DATA);
}
metadataV2.flags.addFlag(BackupFlags.BACKUP_CACHE);
} catch (FileNotFoundException ignore) {
}
try {
mFilesToBeDeleted.add(getApkFile(metadataV2.apkName, metadataV2.tarType));
// No error = APK file exists
metadataV2.flags.addFlag(BackupFlags.BACKUP_APK_FILES);
} catch (FileNotFoundException ignore) {
}View on GitHub (pinned to 0152f468fc)
Solutions
- Set app_apk_codec=GZIP or BZIP2 in the prop file to match the actual archive encoding (recompress the tar if needed).
- Re-create the backup in OAndBackup using GZIP compression.
- Check the prop file was fully copied — a truncated file can drop the codec line.
- If the codec is genuinely unsupported, convert the archive externally to gzip/bzip2 first.
Example fix
# before (backup.properties) app_apk_codec=ZSTD # after app_apk_codec=GZIP # after repacking the .tar with gzip
Defensive patterns
Strategy: validation
Validate before calling
Properties prop = new Properties();
try (InputStream is = new FileInputStream(propFile)) { prop.load(is); }
String codec = prop.getProperty("app_apk_codec");
if (!"GZIP".equals(codec) && !"BZIP2".equals(codec))
throw new IllegalStateException("Unsupported app_apk_codec: " + codec); Try / catch
try {
converter.convert(backupDir);
} catch (BackupException e) {
if (e.getMessage() != null && e.getMessage().startsWith("Unsupported compression type")) {
// fix prop file / repack, then retry
} else throw e;
} Prevention
- Validate every prop file's app_apk_codec in a pre-flight pass over bulk backup imports.
- Ensure prop files are copied fully (verify sizes after MTP/adb pulls).
- Standardize source backups on GZIP.
When it happens
Trigger: Converting a backup whose prop file has app_apk_codec set to something other than GZIP or BZIP2 (e.g. NONE, ZSTD, LZ4, or an empty/missing value).
Common situations: OAndBackup configured with a different compression codec; very old or very new OAndBackup versions with additional codecs; hand-edited or truncated prop files losing the codec line.
Related errors
- Invalid compression type: ${tarType}
- Could not read the prop file
- Couldn't delete old file <inputFile>
- Could not delete <mBackupPath>
- Could not move <mTempBackupPath> to <mBackupPath>
AI-assisted analysis of MuntashirAkon/AppManager@0152f468fc (2026-09-12).
Data as JSON: /api/errors/2a3a830f7a15653f.
Report an issue: GitHub.