Skip to content

K-Dense-AI/scientific-agent-skills / skills/pylabrobot

pylabrobot

Verified

Develops and reviews PyLabRobot lab-automation resources, liquid-handling plans, offline simulations, and supported-device integrations. Supports PyLabRobot protocols and API questions; keep physical execution behind an explicit operator safety gate.

scripts/check_deck_geometry.py

View on GitHub
#!/usr/bin/env python3
"""Check bounded static deck geometry without importing PyLabRobot."""

from __future__ import annotations

import argparse
from typing import Sequence

if __package__:
  from ._common import (
      ValidationError,
      emit_error,
      emit_json,
      geometry_report,
      load_json,
      validate_manifest,
  )
else:
  from _common import (
      ValidationError,
      emit_error,
      emit_json,
      geometry_report,
      load_json,
      validate_manifest,
  )


def build_parser() -> argparse.ArgumentParser:
  parser = argparse.ArgumentParser(
      description=(
          "Check resource bounds and static axis-aligned collisions in an offline "
          "manifest. No hardware, serial, USB, or network access occurs."
      )
  )
  parser.add_argument("--input", required=True, help="Local UTF-8 .json manifest")
  return parser


def main(argv: Sequence[str] | None = None) -> int:
  args = build_parser().parse_args(argv)
  try:
    manifest = validate_manifest(load_json(args.input))
    report = geometry_report(manifest)
  except (OSError, ValidationError) as error:
    return emit_error(error)
  emit_json({"protocol_id": manifest["protocol_id"], **report})
  return 0 if report["ok"] else 3


if __name__ == "__main__":
  raise SystemExit(main())
receiving-code-reviewobra/superpowersUse when receiving code review feedback, before implementing suggestions, especially if feedback seems unclear or technically questionable - requires technical rigor and verification, not performative agreement or blind implementationStars: 322kUpdated Claude CodeCodexVerifiedInstall
requesting-code-reviewobra/superpowersUse when completing tasks, implementing major features, or before merging to verify work meets requirementsStars: 322kUpdated Claude CodeCodexVerifiedInstall
using-git-worktreesobra/superpowersUse when starting feature work that needs isolation from current workspace or before executing implementation plans - ensures an isolated workspace exists via native tools or git worktree fallbackStars: 322kUpdated Claude CodeCodexVerifiedInstall
verification-before-completionobra/superpowersUse when about to claim work is complete, fixed, or passing, before committing or creating PRs - requires running verification commands and confirming output before making any success claims; evidence before assertions alwaysStars: 322kUpdated Claude CodeCodexVerifiedInstall