MuntashirAkon/AppManager · error · IllegalArgumentException
Invalid format: isHidden not found
Error message
Invalid format: isHidden not found
What it means
MagiskDenyListRule's constructor reads the isHidden (enabled) boolean token after the package/process tokens. If the tokenizer has no more elements, it throws this IllegalArgumentException because a MAGISK_DENY_LIST rule is incomplete without the isHidden field.
Solutions
- Ensure the flattened string includes a "true"/"false" isHidden token after package and process names
- Check token count before constructing the rule and reject short strings
- Regenerate the rule export from the current AppManager version
- Catch IllegalArgumentException during import and skip/report malformed entries
Example fix
// before
new MagiskDenyListRule(pkg, proc, new StringTokenizer("com.example\tcom.example\tsub")); // throws
// after
new MagiskDenyListRule(pkg, proc, new StringTokenizer("com.example\tcom.example\tsub\tfalse\tfalse")); Defensive patterns
Strategy: validation
Validate before calling
String[] p = line.split("\t");
if (p.length < 3) throw new IllegalArgumentException("MAGISK_DENY_LIST rule needs isHidden");
Boolean.parseBoolean(p[2]); Type guard
boolean isParsableDenyListRule(String line) { String[] p = line.split("\t"); return p.length >= 3 && (p[2].equals("true") || p[2].equals("false")); } Try / catch
try { new MagiskDenyListRule(pkg, proc, tokenizer); } catch (IllegalArgumentException e) { skipRule(line, e); } Prevention
- Confirm the token order: package, process, isHidden, isIsolated
- Check tokenizer count before constructing rules from user-supplied files
- Re-export rules after AppManager version upgrades to match the current format
When it happens
Trigger: new MagiskDenyListRule(packageName, processName, tokenizer) invoked with a tokenizer that ran out of tokens before the isHidden boolean, i.e. the flattened string lacks the third field.
Common situations: Truncated or hand-edited deny-list rule exports, imports of rules from older AppManager versions with fewer fields, or wrong delimiter handling dropping tokens.
Understand the failure class
Background: "Invalid ... format", "must be in format X", "does not look like a ..." — invalid argument format errors across CLI tools and libraries — this error's family across 17 libraries.
Related errors
- Invalid format: isHidden not found
- Invalid format: freeze_type not found
- Invalid format: isGranted not found
- Invalid format: isGranted not found
- Invalid format: name not found
AI-assisted analysis of MuntashirAkon/AppManager@0152f468fc (2026-09-12).
Data as JSON: /api/errors/be770cc7e4ecfa9b.
Report an issue: GitHub.
Appendix: source
Thrown at app/src/main/java/io/github/muntashirakon/AppManager/rules/struct/MagiskDenyListRule.java:29
import io.github.muntashirakon.AppManager.rules.RuleType;
public class MagiskDenyListRule extends RuleEntry {
@NonNull
private final MagiskProcess mMagiskProcess;
public MagiskDenyListRule(@NonNull MagiskProcess magiskProcess) {
super(magiskProcess.packageName, magiskProcess.name, RuleType.MAGISK_DENY_LIST);
mMagiskProcess = magiskProcess;
}
public MagiskDenyListRule(@NonNull String packageName, @NonNull String processName, @NonNull StringTokenizer tokenizer)
throws IllegalArgumentException {
super(packageName, processName, RuleType.MAGISK_DENY_LIST);
mMagiskProcess = new MagiskProcess(packageName, name);
mMagiskProcess.setAppZygote(name.endsWith("_zygote"));
if (tokenizer.hasMoreElements()) {
mMagiskProcess.setEnabled(Boolean.parseBoolean(tokenizer.nextElement().toString()));
} else throw new IllegalArgumentException("Invalid format: isHidden not found");
if (tokenizer.hasMoreElements()) {
mMagiskProcess.setIsolatedProcess(Boolean.parseBoolean(tokenizer.nextElement().toString()));
}
}
public String getProcessName() {
return name;
}
@NonNull
public MagiskProcess getMagiskProcess() {
return mMagiskProcess;
}
@NonNull
@Override
public String toString() {
return "MagiskDenyListRule{" +View on GitHub (pinned to 0152f468fc)