{"record":{"id":"4784577c739d879e","repo":"BigPizzaV3/CodexPlusPlus","slug":"unsupported-native-entry-point","errorCode":null,"errorMessage":"Unsupported native entry point","messagePattern":"Unsupported native entry point","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"crates/codex-plus-core/src/native_browser.rs","lineNumber":328,"sourceCode":"        env[\"NODE_REPL_TRUSTED_SERVICES\"]\n            .as_str()\n            .context(\"Missing native service map\")?,\n    )?;\n    ensure!(\n        services[\"browser\"] == \"@oai/browser-desktop/service\",\n        \"Original browser service is not selected\"\n    );\n    ensure!(\n        env[\"CUA_REPL_ENABLED_SURFACES\"].as_str() == Some(\"browser\"),\n        \"Unsupported native surface selection\"\n    );\n    let args = server[\"args\"]\n        .as_array()\n        .context(\"Missing native entry point\")?;\n    let entry = root\n        .join(key)\n        .join(\"bin/node_modules/@oai/cua-repl/bin/cua-repl.mjs\");\n    ensure!(\n        args.len() == 1 && args[0].as_str().map(Path::new) == Some(entry.as_path()),\n        \"Unsupported native entry point\"\n    );\n    plain_path(&node)?;\n    Ok(key.to_owned())\n}\n\nfn discover(paths: &BrowserPaths) -> Result<Option<String>> {\n    let plugins = paths\n        .codex_home\n        .join(\"plugins/cache/openai-bundled/unified-computer-use\");\n    plain_path(&plugins)?;\n    if !plugins.exists() {\n        return Ok(None);\n    }\n    let mut keys = BTreeSet::new();\n    let mut count = 0;\n    for entry in fs::read_dir(plugins)? {","sourceCodeStart":310,"sourceCodeEnd":346,"githubUrl":"https://github.com/BigPizzaV3/CodexPlusPlus/blob/b1ed92e5e4a2d74095d4b8db5af43cef7acba9c6/crates/codex-plus-core/src/native_browser.rs#L310-L346","documentation":"The cua_repl server must be launched with exactly one argument: the cached entry script <runtime_root>/<key>/bin/node_modules/@oai/cua-repl/bin/cua-repl.mjs. If args contains extra flags, a different script, or a different number of arguments, the server would run an entry point Codex++ did not prepare/patch, so the descriptor is rejected.","triggerScenarios":"selected_key inspects mcpServers.cua_repl.args and finds args.len() != 1 or args[0] not equal to the expected cua-repl.mjs path under the runtime key's bin directory — e.g. someone appended --inspect or pointed at a system-installed cua-repl.","commonSituations":"Debugging additions like --inspect or --trace-warnings left in args; pointing args at a globally installed cua-repl.mjs; plugin version drift changing the arg list; copied descriptors from other setups.","solutions":["Set args to exactly [\"<runtime_root>/<key>/bin/node_modules/@oai/cua-repl/bin/cua-repl.mjs\"]","Remove any extra CLI flags from the args array in .mcp.json","Reinstall the unified-computer-use plugin to regenerate a correct descriptor"],"exampleFix":"// before\n\"args\": [\".../cua-repl.mjs\", \"--inspect\"]\n// after\n\"args\": [\".../cua-repl.mjs\"]","handlingStrategy":"validation","validationCode":"let args = descriptor[\"mcpServers\"][\"cua_repl\"][\"args\"].as_array().unwrap();\nlet expected = runtime_root.join(key).join(\"bin/node_modules/@oai/cua-repl/bin/cua-repl.mjs\");\nif args.len() != 1 || args[0].as_str() != Some(expected.to_str().unwrap()) { eprintln!(\"unexpected cua_repl args\"); }","typeGuard":"fn entry_point_is_expected(args: &Value, root: &Path, key: &str) -> bool {\n    let expected = root.join(key).join(\"bin/node_modules/@oai/cua-repl/bin/cua-repl.mjs\");\n    args.as_array()\n        .map(|a| a.len() == 1 && a[0].as_str().map(Path::new) == Some(expected.as_path()))\n        .unwrap_or(false)\n}","tryCatchPattern":null,"preventionTips":["Don't append debug flags (--inspect etc.) to managed descriptors; use a separate unmanaged config for debugging","After plugin upgrades, confirm args still point at the cached cua-repl.mjs","Keep exactly one arg pointing inside the runtime cache"],"tags":["config","native-browser","mcp-descriptor","entry-point"],"backgroundTag":"invalid-config-value","analyzedSha":"b1ed92e5e4a2d74095d4b8db5af43cef7acba9c6","analyzedAt":"2026-09-19T23:35:21.129Z","contentChangedAt":"2026-09-19T23:35:21.129Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}