Skip to content

Observing policy and constraints

Three separate mechanisms are covered here. They are independent of one another:

  • OperationalConstraint records are safety gates on a site or telescope (a weather reading must be in range, the mount must stay clear of the sun, …). When one is not safe, its actions keep the enclosure closed, stop the mount, or otherwise hold the hardware, and SkyNode stops starting new tasks.
  • ShutdownInterlock records are locks an operator places on a telescope or a whole observatory to halt automation and shut it down until the lock is cleared or expires.
  • ObservingPolicy records are per-organization rules about what an observing account may submit and how its data is handled. They are recorded but not yet enforced.

Constraints are polymorphic — each kind has its own concrete class. SkyNode evaluates them against live device readings at the telescope.

Constraint type What it gates on
WeatherSensorConstraint A reading from a weather sensor (cloudiness, wind, rain, humidity, …) outside a configured minimum / maximum
MountSunSeparationConstraint Angular separation between the mount’s current pointing and the sun
SunAltitudeConstraint, CameraTemperatureConstraint, BatteryConstraint, StorageConstraint Defined in the data model, but SkyNode does not evaluate them yet

Each constraint has a minimum and/or maximum value, a stability threshold (how long a reading must stay in range before the constraint reads safe again), a maximum data age (how long without a fresh reading before it reads unknown; 5 minutes by default), and an active flag. Its status is one of safe, unsafe, stabilizing, unknown, or fault.

A constraint does nothing on its own: it acts through actions, each naming a device and what to do to it — keep_enclosure_closed, prevent_enclosure_motion, shutdown_camera, stop_mount_motion, or warn_only — and whether the action fires when the constraint is unsafe, unknown, or stabilizing (unsafe and unknown by default). A device held by an action reads unsafe, and SkyNode does not start tasks while the mount or enclosure is unsafe.

Constraints are scoped to an observatory (the site safety boundary, always set) and optionally to one telescope there. A typical example: one weather-sensor constraint at the observatory that keeps every enclosure on the site closed when it rains.

SkyNode records each constraint’s status over time as OperationalConstraintStatusSnapshots; if a constraint is failing right now, the latest snapshot shows its status and the reason behind it. On the telescope’s Overview page, the conditions panel shows every constraint with its live reading, limit, and verdict.

A ShutdownInterlock is a lock an operator places deliberately, not a sensor reading. While one is active, SkyNode stops the running task, runs the telescope’s configured shutdown actions (close the enclosure and mirror covers, park the mount, warm the cameras), and starts no new work until the lock is cleared. Use it for “stop now and stay stopped” situations — a hardware problem, maintenance on site, a known hazard.

Each interlock has a name (shown on the SkyNode dashboard banner), an optional reason, a scope (one telescope, or every telescope at an observatory), an enabled flag, and optional starts at / expires at times, so it can be scheduled ahead or lapse on its own. Its status is active, scheduled, expired, or disabled.

SkyNode fails closed: if it cannot get a current interlock status from Skynet, it blocks automation and, after a short startup grace period, closes the enclosure.

Configure interlocks conservatively. The cost of an unnecessary shutdown is one missed night; the cost of a missed interlock can be much higher.

An ObservingPolicy belongs to an organization and lists what may be submitted under it:

  • Request types and data policies allowed (each must list at least one value), and how long data stays private before becoming public.
  • Target position types, coordinate types, and catalog object types allowed (unset means no restriction).
  • Whether hidden observations and hidden telemetry are allowed.

A policy is attached to a root observing account; its subaccounts inherit it. A queue access grant can also reference a policy.

  • Operational constraints: weather-sensor constraints are created and edited in SkyNode, under Settings → Operational Constraints; mount–sun separation constraints only through the API. An operator can also skip a constraint’s stabilizing wait from the SkyNode dashboard after an on-site check. See Set up a weather constraint.
  • Shutdown interlocks: placed and cleared from the SkyNode dashboard; the website shows an active interlock but cannot create one. See Place a shutdown interlock.
  • Observing policies: listed and edited under the organization’s Settings → Observing Policies, and attached to an account from the account’s Edit dialog. See Create an observing policy.

In the API, policies are managed at /v1/organizations/{organization}/observing-policies; constraints at /v1/operational-constraints, their status history at /v1/operational-constraint-snapshots; and interlocks at /v1/shutdown-interlocks.