Skip to content

.sidecar

Liatir.sidecar.run() executes a binary that is bundled with the Liatir desktop app and captures its stdout, stderr, and exit code.

Use this to run bioinformatics tools (samtools, minimap2, bwa, bcftools, etc.) without requiring the user to install them separately.

Signature

Example

SidecarResult

FieldTypeDescription
okboolean / booltrue if the process exited with code 0.
stdoutstring / strCaptured standard output.
stderrstring / strCaptured standard error.
exitCodenumber | null / int | NoneProcess exit code.
errorstring | null / str | NoneError message if the process failed.
durationMsnumber / intExecution time in milliseconds.

NOTE

SidecarResult fields are always camelCase in both Node and Python, because they come from the JSON response of the Liatir bridge.

Available binaries

The following binaries are bundled with Liatir and can be invoked via sidecar:

BinaryDescription
samtoolsSAM/BAM processing
minimap2Long-read alignment
bwaShort-read alignment
bcftoolsVCF/BCF manipulation
fastpFASTQ preprocessing
seqkitFASTA/FASTQ toolkit
snpeffVariant annotation

Notes

TIP

Sidecar binaries run in a sandboxed environment. They cannot access arbitrary paths on the host filesystem — use the plugin filesystem (.desktop.fs.pluginFs / .desktop.fs.plugin_fs) to stage input files and read output files.

WARNING

The list of available sidecar binaries depends on the Liatir app version. Always check result.ok / result['ok'] and handle errors gracefully.