{"record":{"id":"b10716684ccb4063","repo":"can1357/oh-my-pi","slug":"julia-backend-is-disabled-pi-jl-0-or-eval-jl-fa","errorCode":null,"errorMessage":"Julia backend is disabled (PI_JL=0 or eval.jl = false).","messagePattern":"Julia backend is disabled \\(PI_JL=0 or eval\\.jl = false\\)\\.","errorType":"validation","errorClass":"ToolError","httpStatus":null,"severity":"error","filePath":"packages/coding-agent/src/tools/eval.ts","lineNumber":281,"sourceCode":"\t}\n\tif (language === \"ruby\") {\n\t\tif (!allowRb) throw new ToolError(\"Ruby backend is disabled (PI_RB=0 or eval.rb = false).\");\n\t\tconst available = await rubyBackend.isAvailable(session, probeOpts);\n\t\tthrowIfAborted(probeOpts?.signal);\n\t\tif (!available) {\n\t\t\tconst alternatives = [allowJs ? '\"js\"' : null, allowPy ? '\"py\"' : null, allowJl ? '\"jl\"' : null].filter(\n\t\t\t\tBoolean,\n\t\t\t);\n\t\t\tthrow new ToolError(\n\t\t\t\talternatives.length > 0\n\t\t\t\t\t? `Ruby backend is unavailable in this session. Pass language: ${alternatives.join(\" or \")} or install Ruby.`\n\t\t\t\t\t: 'Ruby backend is unavailable in this session. Install Ruby to use language: \"rb\".',\n\t\t\t);\n\t\t}\n\t\treturn { backend: rubyBackend };\n\t}\n\tif (language === \"julia\") {\n\t\tif (!allowJl) throw new ToolError(\"Julia backend is disabled (PI_JL=0 or eval.jl = false).\");\n\t\tconst available = await juliaBackend.isAvailable(session, probeOpts);\n\t\tthrowIfAborted(probeOpts?.signal);\n\t\tif (!available) {\n\t\t\tconst alternatives = [allowJs ? '\"js\"' : null, allowPy ? '\"py\"' : null, allowRb ? '\"rb\"' : null].filter(\n\t\t\t\tBoolean,\n\t\t\t);\n\t\t\tthrow new ToolError(\n\t\t\t\talternatives.length > 0\n\t\t\t\t\t? `Julia backend is unavailable in this session. Pass language: ${alternatives.join(\" or \")} or install Julia.`\n\t\t\t\t\t: 'Julia backend is unavailable in this session. Install Julia to use language: \"jl\".',\n\t\t\t);\n\t\t}\n\t\treturn { backend: juliaBackend };\n\t}\n\tif (!allowJs) throw new ToolError(\"JavaScript backend is disabled (PI_JS=0 or eval.js = false).\");\n\treturn { backend: jsBackend };\n}\nfunction formatEvalInputLanguage(value: string): string {","sourceCodeStart":263,"sourceCodeEnd":299,"githubUrl":"https://github.com/can1357/oh-my-pi/blob/969062200754ea02cfac922e5ebb8c608c079e15/packages/coding-agent/src/tools/eval.ts#L263-L299","documentation":"The eval tool's backend resolver (resolveBackend) checks per-language allowances before probing the Julia runtime. This error means the Julia language backend is intentionally disabled by configuration, not merely unavailable. Allowance comes from the eval.jl setting (default false) with the PI_JL environment flag acting as an override (eval-backends.ts resolveEvalBackends: $flag(\"PI_JL\", settings.julia)).","triggerScenarios":"Calling the eval tool with language \"jl\" or \"julia\" when the setting eval.jl is false/unset (rb/jl are opt-in, default off) or PI_JL=0 is set in the environment. The check runs before juliaBackend.isAvailable is ever probed, so Julia being installed does not matter.","commonSituations":"A user asks the agent to run Julia code without ever enabling the opt-in Julia backend; a CI environment or project config sets PI_JL=0 to hard-disable it; a user upgraded from a config that assumed rb/jl default-on.","solutions":["Set the eval.jl setting to true in the session/project settings to enable the Julia backend.","Set PI_JL=1 in the environment to override the setting for the current session.","Re-run the eval cell with language \"js\" or \"py\" (or \"rb\" if enabled) instead of Julia."],"exampleFix":"// before (settings file)\n{ \"eval\": { \"jl\": false } }\n// after\n{ \"eval\": { \"jl\": true } }\n// or in shell before launching\nexport PI_JL=1","handlingStrategy":"validation","validationCode":"import { resolveEvalBackends } from \"./eval-backends\";\nconst backends = resolveEvalBackends(session);\nif (!backends.julia) {\n  // avoid the call: use another language or prompt user to enable eval.jl / PI_JL\n}","typeGuard":"function juliaEnabled(b: { julia: boolean }): b is { julia: true } { return b.julia; }","tryCatchPattern":"try {\n  await evalTool.execute(id, { language: \"jl\", code }, signal);\n} catch (e) {\n  if (e instanceof ToolError && e.message.includes(\"Julia backend is disabled\")) {\n    // fall back to an enabled language\n  } else throw e;\n}","preventionTips":["Check resolveEvalBackends(session) once at session start and advertise only enabled languages.","Set eval.jl true or PI_JL=1 up front if Julia cells are planned.","Gate any prompt/model instructions that suggest language \"jl\" on the allowance."],"tags":["configuration","eval-tool","julia","feature-flag"],"backgroundTag":"feature-disabled-by-config","analyzedSha":"969062200754ea02cfac922e5ebb8c608c079e15","analyzedAt":"2026-08-31T10:29:35.737Z","schemaVersion":2},"datasetVersion":"2026-08-31T14:17:45.589Z"}