BCUninstaller/Bulk-Crap-Uninstaller · error · Exception
{canonicalName} is not a recognized or allowed app name
Error message
{canonicalName} is not a recognized or allowed app name What it means
Thrown by OculusManager.RemoveApp(string) when QueryOculusApps returns zero apps whose CanonicalName matches the argument (case-insensitive). It is a plain System.Exception (no dedicated type), surfaced as 'not a recognized or allowed app name'. The check fires after enumerating installed Oculus titles from the Oculus library JSON, so a miss means either the name is wrong or the app is not installed/tracked.
Source
Thrown at source/OculusHelper/OculusManager.cs:139
}
}
}
return apps;
}
public static void RemoveApp(string canonicalName)
{
Console.WriteLine("Looking for apps with canonical name: " + canonicalName);
var apps = QueryOculusApps()
.Where(x => canonicalName.Equals(x.CanonicalName, StringComparison.OrdinalIgnoreCase))
.ToList();
if (apps.Count == 0)
{
Console.WriteLine("Invalid app name or app can't be uninstalled");
throw new Exception($"{canonicalName} is not a recognized or allowed app name");
}
foreach (var app in apps)
RemoveApp(app);
}
public static void RemoveApp(OculusApp app)
{
CloseOculusClient();
Console.WriteLine("Removing Oculus app: " + app.CanonicalName);
Debug.Assert(app.CanonicalName.Length > 10);
foreach (var libraryLocation in OculusLibraryLocations)
{
// Collect paths first to avoid crashing halfway
var dirs = Directory.GetDirectories(libraryLocation,
$"*{app.CanonicalName}*", SearchOption.AllDirectories);View on GitHub (pinned to 608321de98)
Solutions
- Call QueryOculusApps() first and confirm the canonical name exists in the returned list before calling RemoveApp.
- List installed apps (their CanonicalName values) for the user to pick from rather than guessing the string.
- Verify the Oculus software and library are installed on the machine before attempting removal.
- Treat a zero-match result as a no-op/success in your own orchestrator if 'remove if present' semantics are acceptable.
Example fix
// before
OculusManager.RemoveApp(nameFromConfig);
// after
var installed = OculusManager.QueryOculusApps();
if (installed.Any(a => a.CanonicalName.Equals(nameFromConfig, StringComparison.OrdinalIgnoreCase)))
OculusManager.RemoveApp(nameFromConfig);
else
Console.WriteLine($"{nameFromConfig} is not installed, skipping"); Defensive patterns
Strategy: validation
Validate before calling
var installed = OculusManager.QueryOculusApps();
var match = installed.FirstOrDefault(a =>
a.CanonicalName.Equals(canonicalName, StringComparison.OrdinalIgnoreCase));
if (match == null) return; // not installed; nothing to remove Type guard
static bool IsInstalledOculusApp(string canonicalName) =>
OculusManager.QueryOculusApps().Any(a =>
a.CanonicalName.Equals(canonicalName, StringComparison.OrdinalIgnoreCase)); Try / catch
try { OculusManager.RemoveApp(canonicalName); }
catch (Exception ex) when (ex.Message.Contains("not a recognized"))
{ /* treat as already removed / not present */ } Prevention
- Enumerate installed apps and let the user pick rather than hardcoding a name.
- Verify the Oculus software/library is installed before attempting removal.
- Treat zero-match as a no-op in uninstall orchestrators.
When it happens
Trigger: Calling RemoveApp(canonicalName) where canonicalName does not match any installed app's CanonicalName; the Oculus software library is not installed so QueryOculusApps returns nothing; the install location was moved so Directory.Exists checks inside QueryOculusApps filtered the app out.
Common situations: Hardcoding a canonical name that changed between Oculus versions; uninstalling an app that was already removed; running on a machine without the Oculus software; the Oculus library JSON being empty or in a new format.
Related errors
- Minimum value must be lower than or equal to the maximum val
- Font size must be higher than 0
- Icon handle must not be zero
- Not a Windows .exe file.
- Failed to parse the input
AI-assisted analysis of BCUninstaller/Bulk-Crap-Uninstaller@608321de98 (2026-08-13).
Data as JSON: /api/errors/afca18c2030c9a76.
Report an issue: GitHub.