Skip to content

Type UAV vehicle state#231

Open
ethayu wants to merge 2 commits into
mainfrom
user/ethayu/workspace-pylance-uav-vehicle-state
Open

Type UAV vehicle state#231
ethayu wants to merge 2 commits into
mainfrom
user/ethayu/workspace-pylance-uav-vehicle-state

Conversation

@ethayu
Copy link
Copy Markdown
Collaborator

@ethayu ethayu commented May 27, 2026

Summary

  • add explicit guards for nullable UAV GPS/local/yaw state before use
  • type payload runtime node extensions with a structural protocol
  • narrow dynamic vision node name/service helpers before calling them

Fixes #230
Part of #201

Verification

  • source /opt/ros/humble/setup.bash && source /home/ubuntu/monorepo/controls/sae_2025_ws/install/setup.bash && export PYTHONPATH="$PWD/controls/sae_2025_ws/src/uav:$PYTHONPATH" && npx --yes pyright controls/sae_2025_ws/src/uav/uav/vehicles/UAV.py controls/sae_2025_ws/src/uav/uav/vehicles/Payload.py controls/sae_2025_ws/src/uav/uav/vehicles/Vehicle.py --outputjson
  • python3 -m compileall controls/sae_2025_ws/src/uav/uav/vehicles/UAV.py controls/sae_2025_ws/src/uav/uav/vehicles/Payload.py controls/sae_2025_ws/src/uav/uav/vehicles/Vehicle.py
  • ruff check --config controls/sae_2025_ws/.ruff.toml controls/sae_2025_ws/src/uav/uav/vehicles/UAV.py controls/sae_2025_ws/src/uav/uav/vehicles/Payload.py controls/sae_2025_ws/src/uav/uav/vehicles/Vehicle.py
  • ruff format --check --config controls/sae_2025_ws/.ruff.toml controls/sae_2025_ws/src/uav/uav/vehicles/UAV.py controls/sae_2025_ws/src/uav/uav/vehicles/Payload.py controls/sae_2025_ws/src/uav/uav/vehicles/Vehicle.py
  • python3 -m pytest -q controls/sae_2025_ws/src/uav/test/test_runtime_behavior.py controls/sae_2025_ws/src/uav/test/test_peer_runtime_contract.py

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Pylance: type UAV vehicle state

1 participant