# Inspect A Failed Solve Run this straight-line script with an installed `jcmsuite` package, a configured JCMsuite runtime, and a solver license: ```bash python demos/documentation_tutorials/failure_logs/single.py ``` The material template substitutes `intentional_solver_error` where a numeric permittivity is required. This deliberately causes a solver input error after template rendering. The script prints the diagnostics instead of returning a result. ```{literalinclude} ../../../../demos/documentation_tutorials/failure_logs/single.py :language: python ``` {class}`SolveExecutionError ` exposes diagnostic text in `log`, together with `backend` and `exit_code`. A source-mapped input error can instead raise {class}`SourceMappingError ` with the execution error as its cause. The script handles both cases, but re-raises a mapping error that has no execution-error cause. A successful solve returns a result whose `log` is a {class}`SolveExecutionLog ` or `None`. That object has separate `stdout` and `stderr` attributes; it is not the string stored on a raised execution error. The [mixed-batch tutorial](batch_failure_logs.md) shows how to retain both successful entries and failures. ## Project Files
project.jcmp ```{literalinclude} ../../../../demos/documentation_tutorials/failure_logs/project.jcmp :language: jcm ```
materials.jcmt ```{literalinclude} ../../../../demos/documentation_tutorials/failure_logs/materials.jcmt :language: jcm ```
layout.jcm ```{literalinclude} ../../../../demos/documentation_tutorials/failure_logs/layout.jcm :language: jcm ```
sources.jcm ```{literalinclude} ../../../../demos/documentation_tutorials/failure_logs/sources.jcm :language: jcm ```