isar 1.25.9__tar.gz → 1.26.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of isar might be problematic. Click here for more details.
- {isar-1.25.9 → isar-1.26.1}/.github/workflows/compile_requirements.yml +1 -1
- {isar-1.25.9 → isar-1.26.1}/.github/workflows/pythonpackage.yml +11 -6
- {isar-1.25.9 → isar-1.26.1}/.github/workflows/stale.yml +0 -4
- {isar-1.25.9 → isar-1.26.1}/PKG-INFO +5 -19
- {isar-1.25.9 → isar-1.26.1}/README.md +0 -17
- isar-1.26.1/docs/state_machine_diagram.png +0 -0
- {isar-1.25.9 → isar-1.26.1}/pyproject.toml +2 -0
- {isar-1.25.9 → isar-1.26.1}/requirements.txt +25 -28
- isar-1.26.1/src/isar/apis/models/start_mission_definition.py +172 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/apis/robot_control/robot_controller.py +5 -4
- {isar-1.25.9 → isar-1.26.1}/src/isar/apis/schedule/scheduling_controller.py +6 -57
- {isar-1.25.9 → isar-1.26.1}/src/isar/apis/security/authentication.py +2 -2
- {isar-1.25.9 → isar-1.26.1}/src/isar/config/settings.env +1 -3
- {isar-1.25.9 → isar-1.26.1}/src/isar/config/settings.py +6 -6
- {isar-1.25.9 → isar-1.26.1}/src/isar/models/communication/message.py +0 -4
- isar-1.26.1/src/isar/models/communication/queues/events.py +57 -0
- isar-1.26.1/src/isar/models/communication/queues/queue_utils.py +32 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/models/communication/queues/status_queue.py +7 -5
- {isar-1.25.9 → isar-1.26.1}/src/isar/modules.py +26 -13
- isar-1.26.1/src/isar/robot/robot.py +124 -0
- isar-1.26.1/src/isar/robot/robot_start_mission.py +73 -0
- isar-1.26.1/src/isar/robot/robot_status.py +49 -0
- isar-1.26.1/src/isar/robot/robot_stop_mission.py +72 -0
- isar-1.26.1/src/isar/robot/robot_task_status.py +92 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/script.py +14 -7
- {isar-1.25.9 → isar-1.26.1}/src/isar/services/utilities/scheduling_utilities.py +21 -30
- {isar-1.25.9 → isar-1.26.1}/src/isar/state_machine/state_machine.py +70 -212
- isar-1.26.1/src/isar/state_machine/states/blocked_protective_stop.py +45 -0
- isar-1.26.1/src/isar/state_machine/states/idle.py +81 -0
- isar-1.26.1/src/isar/state_machine/states/monitor.py +240 -0
- isar-1.26.1/src/isar/state_machine/states/offline.py +42 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/state_machine/states/paused.py +6 -3
- isar-1.26.1/src/isar/state_machine/states/stop.py +62 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/state_machine/states_enum.py +0 -2
- isar-1.26.1/src/isar/state_machine/transitions/fail_mission.py +13 -0
- isar-1.26.1/src/isar/state_machine/transitions/finish_mission.py +39 -0
- isar-1.26.1/src/isar/state_machine/transitions/pause.py +24 -0
- isar-1.26.1/src/isar/state_machine/transitions/resume.py +27 -0
- isar-1.26.1/src/isar/state_machine/transitions/start_mission.py +73 -0
- isar-1.26.1/src/isar/state_machine/transitions/stop.py +40 -0
- isar-1.26.1/src/isar/state_machine/transitions/utils.py +10 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/storage/slimm_storage.py +2 -2
- {isar-1.25.9 → isar-1.26.1}/src/isar/storage/uploader.py +5 -5
- {isar-1.25.9 → isar-1.26.1}/src/isar.egg-info/PKG-INFO +5 -19
- {isar-1.25.9 → isar-1.26.1}/src/isar.egg-info/SOURCES.txt +14 -7
- {isar-1.25.9 → isar-1.26.1}/src/isar.egg-info/requires.txt +1 -0
- {isar-1.25.9 → isar-1.26.1}/src/robot_interface/telemetry/mqtt_client.py +0 -1
- {isar-1.25.9 → isar-1.26.1}/src/robot_interface/telemetry/payloads.py +3 -3
- {isar-1.25.9 → isar-1.26.1}/src/robot_interface/utilities/json_service.py +1 -1
- {isar-1.25.9 → isar-1.26.1}/tests/conftest.py +10 -12
- {isar-1.25.9 → isar-1.26.1}/tests/integration/turtlebot/test_successful_mission.py +5 -3
- {isar-1.25.9 → isar-1.26.1}/tests/isar/apis/scheduler/test_scheduler_router.py +0 -2
- isar-1.26.1/tests/isar/apis/security/test_authentication.py +32 -0
- {isar-1.25.9 → isar-1.26.1}/tests/isar/models/communication/test_queues.py +12 -12
- {isar-1.25.9 → isar-1.26.1}/tests/isar/services/utilities/test_scheduling_utilities.py +2 -2
- {isar-1.25.9 → isar-1.26.1}/tests/isar/state_machine/states/test_monitor.py +1 -1
- {isar-1.25.9 → isar-1.26.1}/tests/isar/state_machine/test_state_machine.py +97 -67
- {isar-1.25.9 → isar-1.26.1}/tests/isar/storage/test_uploader.py +2 -2
- {isar-1.25.9 → isar-1.26.1}/tests/mocks/robot_interface.py +25 -11
- isar-1.25.9/.github/workflows/publish_isar_base_image.yml +0 -52
- isar-1.25.9/Dockerfile +0 -41
- isar-1.25.9/docker-compose-turtlebot.yml +0 -30
- isar-1.25.9/docker-compose.yml +0 -22
- isar-1.25.9/docs/state_machine_diagram.png +0 -0
- isar-1.25.9/src/isar/apis/models/start_mission_definition.py +0 -229
- isar-1.25.9/src/isar/models/communication/queues/queues.py +0 -19
- isar-1.25.9/src/isar/state_machine/states/blocked_protective_stop.py +0 -65
- isar-1.25.9/src/isar/state_machine/states/idle.py +0 -103
- isar-1.25.9/src/isar/state_machine/states/initialize.py +0 -70
- isar-1.25.9/src/isar/state_machine/states/initiate.py +0 -111
- isar-1.25.9/src/isar/state_machine/states/monitor.py +0 -250
- isar-1.25.9/src/isar/state_machine/states/offline.py +0 -63
- isar-1.25.9/src/isar/state_machine/states/stop.py +0 -91
- isar-1.25.9/tests/isar/apis/security/test_authentication.py +0 -53
- {isar-1.25.9 → isar-1.26.1}/.dockerignore +0 -0
- {isar-1.25.9 → isar-1.26.1}/.github/ISSUE_TEMPLATE/bug_report.md +0 -0
- {isar-1.25.9 → isar-1.26.1}/.github/ISSUE_TEMPLATE/feature.md +0 -0
- {isar-1.25.9 → isar-1.26.1}/.github/ISSUE_TEMPLATE/improvement.md +0 -0
- {isar-1.25.9 → isar-1.26.1}/.github/PULL_REQUEST_TEMPLATE.md +0 -0
- {isar-1.25.9 → isar-1.26.1}/.github/release.yml +0 -0
- {isar-1.25.9 → isar-1.26.1}/.github/workflows/project_automations.yml +0 -0
- {isar-1.25.9 → isar-1.26.1}/.github/workflows/pythonpublish.yml +0 -0
- {isar-1.25.9 → isar-1.26.1}/.gitignore +0 -0
- {isar-1.25.9 → isar-1.26.1}/.pre-commit-config.yaml +0 -0
- {isar-1.25.9 → isar-1.26.1}/LICENSE +0 -0
- {isar-1.25.9 → isar-1.26.1}/SECURITY.md +0 -0
- {isar-1.25.9 → isar-1.26.1}/docs/Makefile +0 -0
- {isar-1.25.9 → isar-1.26.1}/docs/make.bat +0 -0
- {isar-1.25.9 → isar-1.26.1}/docs/rst_processing.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/docs/source/conf.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/docs/source/index.rst +0 -0
- {isar-1.25.9 → isar-1.26.1}/docs/source/readme_link.md +0 -0
- {isar-1.25.9 → isar-1.26.1}/main.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/radixconfig.yml +0 -0
- {isar-1.25.9 → isar-1.26.1}/setup.cfg +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/apis/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/apis/api.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/apis/models/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/apis/models/models.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/apis/schedule/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/apis/security/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/config/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/config/certs/ca-cert.pem +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/config/configuration_error.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/config/keyvault/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/config/keyvault/keyvault_error.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/config/keyvault/keyvault_service.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/config/log.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/config/logging.conf +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/config/maps/JSP1_intermediate_deck.json +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/config/maps/JSP1_weather_deck.json +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/config/maps/default_map.json +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/config/maps/klab_b.json +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/config/maps/klab_compressor.json +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/config/maps/klab_turtlebot.json +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/config/maps/turtleworld.json +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/config/predefined_mission_definition/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/config/predefined_mission_definition/default_exr.json +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/config/predefined_mission_definition/default_mission.json +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/config/predefined_mission_definition/default_turtlebot.json +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/config/predefined_missions/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/config/predefined_missions/default.json +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/config/predefined_missions/default_turtlebot.json +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/mission_planner/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/mission_planner/local_planner.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/mission_planner/mission_planner_interface.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/mission_planner/sequential_task_selector.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/mission_planner/task_selector_interface.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/models/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/models/communication/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/models/communication/queues/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/models/communication/queues/queue_io.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/models/communication/queues/queue_timeout_error.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/models/mission_metadata/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/services/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/services/auth/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/services/auth/azure_credentials.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/services/service_connections/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/services/service_connections/mqtt/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/services/service_connections/mqtt/mqtt_client.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/services/service_connections/mqtt/robot_heartbeat_publisher.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/services/service_connections/mqtt/robot_info_publisher.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/services/service_connections/request_handler.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/services/service_connections/stid/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/services/utilities/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/services/utilities/queue_utilities.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/services/utilities/robot_utilities.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/services/utilities/threaded_request.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/state_machine/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/state_machine/states/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/state_machine/states/off.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/storage/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/storage/blob_storage.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/storage/local_storage.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/storage/storage_interface.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar/storage/utilities.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar.egg-info/dependency_links.txt +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar.egg-info/entry_points.txt +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/isar.egg-info/top_level.txt +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/robot_interface/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/robot_interface/models/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/robot_interface/models/exceptions/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/robot_interface/models/exceptions/robot_exceptions.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/robot_interface/models/initialize/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/robot_interface/models/inspection/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/robot_interface/models/inspection/inspection.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/robot_interface/models/mission/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/robot_interface/models/mission/mission.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/robot_interface/models/mission/status.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/robot_interface/models/mission/task.py +1 -1
- {isar-1.25.9 → isar-1.26.1}/src/robot_interface/models/robots/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/robot_interface/models/robots/battery_state.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/robot_interface/models/robots/media.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/robot_interface/models/robots/robot_model.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/robot_interface/robot_interface.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/robot_interface/telemetry/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/robot_interface/test_robot_interface.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/robot_interface/utilities/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/src/robot_interface/utilities/uuid_string_factory.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/integration/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/integration/turtlebot/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/integration/turtlebot/config/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/integration/turtlebot/config/maps/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/integration/turtlebot/config/maps/turtleworld.json +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/integration/turtlebot/config/missions/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/integration/turtlebot/config/missions/default.json +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/isar/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/isar/apis/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/isar/apis/models/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/isar/apis/models/example_mission_definition.json +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/isar/apis/models/test_start_mission_definition.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/isar/apis/scheduler/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/isar/apis/security/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/isar/mission/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/isar/mission/test_mission.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/isar/models/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/isar/models/communication/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/isar/services/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/isar/services/readers/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/isar/services/readers/test_mission_reader.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/isar/services/service_connections/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/isar/services/service_connections/echo/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/isar/services/service_connections/test_base_request_handler.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/isar/services/utilities/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/isar/services/utilities/test_queue_utilities.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/isar/state_machine/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/isar/state_machine/states/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/isar/storage/test_blob_storage.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/mocks/__init__.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/mocks/blob_storage.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/mocks/mission_definition.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/mocks/mqtt_client.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/mocks/pose.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/mocks/request.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/mocks/status.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/mocks/task.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/mocks/token.py +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/test_data/test_map_config/test_map_config.json +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/test_data/test_mission_not_working.json +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/test_data/test_mission_working.json +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/test_data/test_mission_working_no_tasks.json +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/test_data/test_thermal_image_mission.json +0 -0
- {isar-1.25.9 → isar-1.26.1}/tests/test_modules.py +0 -0
|
@@ -7,6 +7,7 @@ on:
|
|
|
7
7
|
pull_request:
|
|
8
8
|
branches:
|
|
9
9
|
- main
|
|
10
|
+
- update-dependencies
|
|
10
11
|
|
|
11
12
|
jobs:
|
|
12
13
|
build:
|
|
@@ -14,7 +15,7 @@ jobs:
|
|
|
14
15
|
strategy:
|
|
15
16
|
fail-fast: false
|
|
16
17
|
matrix:
|
|
17
|
-
python-version: ["3.9", "3.10", "3.11", "3.12"]
|
|
18
|
+
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
|
|
18
19
|
|
|
19
20
|
steps:
|
|
20
21
|
- uses: actions/checkout@v4
|
|
@@ -28,13 +29,13 @@ jobs:
|
|
|
28
29
|
run: |
|
|
29
30
|
python -m pip install --upgrade pip
|
|
30
31
|
|
|
31
|
-
- name: Install dependencies with the compiled requirements (for Python 3.
|
|
32
|
-
if: ${{matrix.python-version == '3.
|
|
32
|
+
- name: Install dependencies with the compiled requirements (for Python 3.13)
|
|
33
|
+
if: ${{matrix.python-version == '3.13'}}
|
|
33
34
|
run: |
|
|
34
35
|
pip install -r requirements.txt -e .[dev]
|
|
35
36
|
|
|
36
|
-
- name: Install dependencies based on the pyproject.toml file (for Python 3.9-3.
|
|
37
|
-
if: ${{matrix.python-version != '3.
|
|
37
|
+
- name: Install dependencies based on the pyproject.toml file (for Python 3.9-3.12)
|
|
38
|
+
if: ${{matrix.python-version != '3.13'}}
|
|
38
39
|
run: |
|
|
39
40
|
pip install -e .[dev]
|
|
40
41
|
|
|
@@ -48,9 +49,13 @@ jobs:
|
|
|
48
49
|
run: |
|
|
49
50
|
black --check .
|
|
50
51
|
|
|
52
|
+
- name: Run isort
|
|
53
|
+
run: |
|
|
54
|
+
isort --check .
|
|
55
|
+
|
|
51
56
|
- name: Run mypy
|
|
52
57
|
run: |
|
|
53
|
-
mypy --disable-error-code=import-untyped .
|
|
58
|
+
mypy --disable-error-code=import-untyped --check-untyped-defs .
|
|
54
59
|
|
|
55
60
|
- name: Run ruff
|
|
56
61
|
run: |
|
|
@@ -22,11 +22,7 @@ jobs:
|
|
|
22
22
|
uses: actions/stale@v9
|
|
23
23
|
with:
|
|
24
24
|
repo-token: ${{ secrets.STALE_ISSUE_TOKEN }}
|
|
25
|
-
stale-issue-message: "This issue has automatically been marked as stale as there has been no activity for 60 days."
|
|
26
|
-
stale-pr-message: "This pull request has automatically been marked as stale as there has been no activity for 30 days."
|
|
27
25
|
stale-issue-label: "stale"
|
|
28
26
|
stale-pr-label: "stale"
|
|
29
|
-
close-issue-message: "This issue has been closed automatically due to a lack of activity."
|
|
30
|
-
close-pr-message: "This pull request has been closed automatically due to a lack of activity."
|
|
31
27
|
days-before-pr-stale: 30
|
|
32
28
|
days-before-close: -1
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
Metadata-Version: 2.
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
2
|
Name: isar
|
|
3
|
-
Version: 1.
|
|
3
|
+
Version: 1.26.1
|
|
4
4
|
Summary: Integration and Supervisory control of Autonomous Robots
|
|
5
5
|
Author-email: Equinor ASA <fg_robots_dev@equinor.com>
|
|
6
6
|
License: Eclipse Public License version 2.0
|
|
@@ -95,6 +95,7 @@ Classifier: Programming Language :: Python :: 3.9
|
|
|
95
95
|
Classifier: Programming Language :: Python :: 3.10
|
|
96
96
|
Classifier: Programming Language :: Python :: 3.11
|
|
97
97
|
Classifier: Programming Language :: Python :: 3.12
|
|
98
|
+
Classifier: Programming Language :: Python :: 3.13
|
|
98
99
|
Classifier: Topic :: Scientific/Engineering
|
|
99
100
|
Classifier: Topic :: Scientific/Engineering :: Physics
|
|
100
101
|
Classifier: Topic :: Software Development :: Libraries
|
|
@@ -127,6 +128,7 @@ Requires-Dist: transitions
|
|
|
127
128
|
Requires-Dist: uvicorn
|
|
128
129
|
Provides-Extra: dev
|
|
129
130
|
Requires-Dist: black; extra == "dev"
|
|
131
|
+
Requires-Dist: isort; extra == "dev"
|
|
130
132
|
Requires-Dist: mypy; extra == "dev"
|
|
131
133
|
Requires-Dist: pip-tools; extra == "dev"
|
|
132
134
|
Requires-Dist: pre-commit; extra == "dev"
|
|
@@ -136,6 +138,7 @@ Requires-Dist: pytest-xdist; extra == "dev"
|
|
|
136
138
|
Requires-Dist: pytest; extra == "dev"
|
|
137
139
|
Requires-Dist: requests-mock; extra == "dev"
|
|
138
140
|
Requires-Dist: ruff; extra == "dev"
|
|
141
|
+
Dynamic: license-file
|
|
139
142
|
|
|
140
143
|
# ISAR
|
|
141
144
|
|
|
@@ -253,21 +256,6 @@ In [this](./src/isar/config/predefined_missions) folder there are predefined def
|
|
|
253
256
|
corresponding to `mission_id=1`. A new mission may be added by adding a new json-file with a mission description. Note,
|
|
254
257
|
the mission IDs must be unique.
|
|
255
258
|
|
|
256
|
-
### Running with docker-compose
|
|
257
|
-
|
|
258
|
-
ISAR may be started with an instance of the [isar-robot](https://github.com/equinor/isar-robot) package by
|
|
259
|
-
|
|
260
|
-
```shell
|
|
261
|
-
docker-compose up --build
|
|
262
|
-
```
|
|
263
|
-
|
|
264
|
-
Provided that the simulator from [isar-turtlebot](https://github.com/equinor/isar-turtlebot) is running ISAR may be
|
|
265
|
-
started with the turtlebot by
|
|
266
|
-
|
|
267
|
-
```shell
|
|
268
|
-
docker-compose -f docker-compose-turtlebot.yml up --build
|
|
269
|
-
```
|
|
270
|
-
|
|
271
259
|
### Configuration
|
|
272
260
|
|
|
273
261
|
The system consists of many configuration variables which may alter the functionality. As an example, it is possible to
|
|
@@ -350,8 +338,6 @@ In general the states
|
|
|
350
338
|
|
|
351
339
|
```
|
|
352
340
|
States.Off,
|
|
353
|
-
States.Initialize,
|
|
354
|
-
States.Initiate,
|
|
355
341
|
States.Stop,
|
|
356
342
|
States.Monitor,
|
|
357
343
|
States.Paused,
|
|
@@ -114,21 +114,6 @@ In [this](./src/isar/config/predefined_missions) folder there are predefined def
|
|
|
114
114
|
corresponding to `mission_id=1`. A new mission may be added by adding a new json-file with a mission description. Note,
|
|
115
115
|
the mission IDs must be unique.
|
|
116
116
|
|
|
117
|
-
### Running with docker-compose
|
|
118
|
-
|
|
119
|
-
ISAR may be started with an instance of the [isar-robot](https://github.com/equinor/isar-robot) package by
|
|
120
|
-
|
|
121
|
-
```shell
|
|
122
|
-
docker-compose up --build
|
|
123
|
-
```
|
|
124
|
-
|
|
125
|
-
Provided that the simulator from [isar-turtlebot](https://github.com/equinor/isar-turtlebot) is running ISAR may be
|
|
126
|
-
started with the turtlebot by
|
|
127
|
-
|
|
128
|
-
```shell
|
|
129
|
-
docker-compose -f docker-compose-turtlebot.yml up --build
|
|
130
|
-
```
|
|
131
|
-
|
|
132
117
|
### Configuration
|
|
133
118
|
|
|
134
119
|
The system consists of many configuration variables which may alter the functionality. As an example, it is possible to
|
|
@@ -211,8 +196,6 @@ In general the states
|
|
|
211
196
|
|
|
212
197
|
```
|
|
213
198
|
States.Off,
|
|
214
|
-
States.Initialize,
|
|
215
|
-
States.Initiate,
|
|
216
199
|
States.Stop,
|
|
217
200
|
States.Monitor,
|
|
218
201
|
States.Paused,
|
|
Binary file
|
|
@@ -19,6 +19,7 @@ classifiers = [
|
|
|
19
19
|
"Programming Language :: Python :: 3.10",
|
|
20
20
|
"Programming Language :: Python :: 3.11",
|
|
21
21
|
"Programming Language :: Python :: 3.12",
|
|
22
|
+
"Programming Language :: Python :: 3.13",
|
|
22
23
|
"Topic :: Scientific/Engineering",
|
|
23
24
|
"Topic :: Scientific/Engineering :: Physics",
|
|
24
25
|
"Topic :: Software Development :: Libraries",
|
|
@@ -60,6 +61,7 @@ repository = "https://github.com/equinor/isar.git"
|
|
|
60
61
|
[project.optional-dependencies]
|
|
61
62
|
dev = [
|
|
62
63
|
"black",
|
|
64
|
+
"isort",
|
|
63
65
|
"mypy",
|
|
64
66
|
"pip-tools",
|
|
65
67
|
"pre-commit",
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#
|
|
2
|
-
# This file is autogenerated by pip-compile with Python 3.
|
|
2
|
+
# This file is autogenerated by pip-compile with Python 3.13
|
|
3
3
|
# by the following command:
|
|
4
4
|
#
|
|
5
5
|
# pip-compile --output-file=requirements.txt pyproject.toml
|
|
@@ -8,7 +8,7 @@ alitra==1.1.3
|
|
|
8
8
|
# via isar (pyproject.toml)
|
|
9
9
|
annotated-types==0.7.0
|
|
10
10
|
# via pydantic
|
|
11
|
-
anyio==4.
|
|
11
|
+
anyio==4.9.0
|
|
12
12
|
# via
|
|
13
13
|
# httpx
|
|
14
14
|
# starlette
|
|
@@ -18,19 +18,19 @@ azure-core==1.32.0
|
|
|
18
18
|
# azure-keyvault-secrets
|
|
19
19
|
# azure-storage-blob
|
|
20
20
|
# opencensus-ext-azure
|
|
21
|
-
azure-identity==1.
|
|
21
|
+
azure-identity==1.21.0
|
|
22
22
|
# via
|
|
23
23
|
# isar (pyproject.toml)
|
|
24
24
|
# opencensus-ext-azure
|
|
25
25
|
azure-keyvault-secrets==4.9.0
|
|
26
26
|
# via isar (pyproject.toml)
|
|
27
|
-
azure-storage-blob==12.
|
|
27
|
+
azure-storage-blob==12.25.0
|
|
28
28
|
# via isar (pyproject.toml)
|
|
29
29
|
backoff==2.2.1
|
|
30
30
|
# via isar (pyproject.toml)
|
|
31
|
-
cachetools==5.5.
|
|
31
|
+
cachetools==5.5.2
|
|
32
32
|
# via google-auth
|
|
33
|
-
certifi==
|
|
33
|
+
certifi==2025.1.31
|
|
34
34
|
# via
|
|
35
35
|
# httpcore
|
|
36
36
|
# httpx
|
|
@@ -43,28 +43,28 @@ click==8.1.8
|
|
|
43
43
|
# via
|
|
44
44
|
# isar (pyproject.toml)
|
|
45
45
|
# uvicorn
|
|
46
|
-
cryptography==44.0.
|
|
46
|
+
cryptography==44.0.2
|
|
47
47
|
# via
|
|
48
48
|
# azure-identity
|
|
49
49
|
# azure-storage-blob
|
|
50
50
|
# fastapi-azure-auth
|
|
51
51
|
# msal
|
|
52
52
|
# pyjwt
|
|
53
|
-
dacite==1.
|
|
53
|
+
dacite==1.9.2
|
|
54
54
|
# via
|
|
55
55
|
# alitra
|
|
56
56
|
# isar (pyproject.toml)
|
|
57
|
-
fastapi==0.115.
|
|
57
|
+
fastapi==0.115.12
|
|
58
58
|
# via
|
|
59
59
|
# fastapi-azure-auth
|
|
60
60
|
# isar (pyproject.toml)
|
|
61
|
-
fastapi-azure-auth==5.
|
|
61
|
+
fastapi-azure-auth==5.1.1
|
|
62
62
|
# via isar (pyproject.toml)
|
|
63
|
-
google-api-core==2.24.
|
|
63
|
+
google-api-core==2.24.2
|
|
64
64
|
# via opencensus
|
|
65
|
-
google-auth==2.
|
|
65
|
+
google-auth==2.38.0
|
|
66
66
|
# via google-api-core
|
|
67
|
-
googleapis-common-protos==1.
|
|
67
|
+
googleapis-common-protos==1.69.2
|
|
68
68
|
# via google-api-core
|
|
69
69
|
h11==0.14.0
|
|
70
70
|
# via
|
|
@@ -85,13 +85,13 @@ isodate==0.7.2
|
|
|
85
85
|
# via
|
|
86
86
|
# azure-keyvault-secrets
|
|
87
87
|
# azure-storage-blob
|
|
88
|
-
msal==1.
|
|
88
|
+
msal==1.32.0
|
|
89
89
|
# via
|
|
90
90
|
# azure-identity
|
|
91
91
|
# msal-extensions
|
|
92
|
-
msal-extensions==1.
|
|
92
|
+
msal-extensions==1.3.1
|
|
93
93
|
# via azure-identity
|
|
94
|
-
numpy==2.2.
|
|
94
|
+
numpy==2.2.4
|
|
95
95
|
# via
|
|
96
96
|
# alitra
|
|
97
97
|
# isar (pyproject.toml)
|
|
@@ -111,16 +111,14 @@ opencensus-ext-requests==0.8.0
|
|
|
111
111
|
# via isar (pyproject.toml)
|
|
112
112
|
paho-mqtt==2.1.0
|
|
113
113
|
# via isar (pyproject.toml)
|
|
114
|
-
|
|
115
|
-
# via msal-extensions
|
|
116
|
-
proto-plus==1.25.0
|
|
114
|
+
proto-plus==1.26.1
|
|
117
115
|
# via google-api-core
|
|
118
|
-
protobuf==
|
|
116
|
+
protobuf==6.30.1
|
|
119
117
|
# via
|
|
120
118
|
# google-api-core
|
|
121
119
|
# googleapis-common-protos
|
|
122
120
|
# proto-plus
|
|
123
|
-
psutil==
|
|
121
|
+
psutil==7.0.0
|
|
124
122
|
# via opencensus-ext-azure
|
|
125
123
|
pyasn1==0.6.1
|
|
126
124
|
# via
|
|
@@ -130,21 +128,21 @@ pyasn1-modules==0.4.1
|
|
|
130
128
|
# via google-auth
|
|
131
129
|
pycparser==2.22
|
|
132
130
|
# via cffi
|
|
133
|
-
pydantic==2.10.
|
|
131
|
+
pydantic==2.10.6
|
|
134
132
|
# via
|
|
135
133
|
# fastapi
|
|
136
134
|
# isar (pyproject.toml)
|
|
137
135
|
# pydantic-settings
|
|
138
136
|
pydantic-core==2.27.2
|
|
139
137
|
# via pydantic
|
|
140
|
-
pydantic-settings==2.
|
|
138
|
+
pydantic-settings==2.8.1
|
|
141
139
|
# via isar (pyproject.toml)
|
|
142
140
|
pyjwt[crypto]==2.10.1
|
|
143
141
|
# via
|
|
144
142
|
# fastapi-azure-auth
|
|
145
143
|
# isar (pyproject.toml)
|
|
146
144
|
# msal
|
|
147
|
-
python-dotenv==1.0
|
|
145
|
+
python-dotenv==1.1.0
|
|
148
146
|
# via
|
|
149
147
|
# isar (pyproject.toml)
|
|
150
148
|
# pydantic-settings
|
|
@@ -163,7 +161,7 @@ requests-toolbelt==1.0.0
|
|
|
163
161
|
# via isar (pyproject.toml)
|
|
164
162
|
rsa==4.9
|
|
165
163
|
# via google-auth
|
|
166
|
-
scipy==1.15.
|
|
164
|
+
scipy==1.15.2
|
|
167
165
|
# via alitra
|
|
168
166
|
six==1.17.0
|
|
169
167
|
# via
|
|
@@ -172,13 +170,12 @@ six==1.17.0
|
|
|
172
170
|
# transitions
|
|
173
171
|
sniffio==1.3.1
|
|
174
172
|
# via anyio
|
|
175
|
-
starlette==0.
|
|
173
|
+
starlette==0.46.1
|
|
176
174
|
# via fastapi
|
|
177
175
|
transitions==0.9.2
|
|
178
176
|
# via isar (pyproject.toml)
|
|
179
177
|
typing-extensions==4.12.2
|
|
180
178
|
# via
|
|
181
|
-
# anyio
|
|
182
179
|
# azure-core
|
|
183
180
|
# azure-identity
|
|
184
181
|
# azure-keyvault-secrets
|
|
@@ -190,5 +187,5 @@ urllib3==2.3.0
|
|
|
190
187
|
# via requests
|
|
191
188
|
uvicorn==0.34.0
|
|
192
189
|
# via isar (pyproject.toml)
|
|
193
|
-
wrapt==1.17.
|
|
190
|
+
wrapt==1.17.2
|
|
194
191
|
# via opencensus-ext-requests
|
|
@@ -0,0 +1,172 @@
|
|
|
1
|
+
import time
|
|
2
|
+
from enum import Enum
|
|
3
|
+
from typing import List, Optional
|
|
4
|
+
|
|
5
|
+
from pydantic import BaseModel, Field
|
|
6
|
+
|
|
7
|
+
from isar.apis.models.models import InputPose, InputPosition
|
|
8
|
+
from isar.config.settings import settings
|
|
9
|
+
from isar.mission_planner.mission_planner_interface import MissionPlannerError
|
|
10
|
+
from robot_interface.models.mission.mission import Mission
|
|
11
|
+
from robot_interface.models.mission.task import (
|
|
12
|
+
TASKS,
|
|
13
|
+
RecordAudio,
|
|
14
|
+
ReturnToHome,
|
|
15
|
+
TakeGasMeasurement,
|
|
16
|
+
TakeImage,
|
|
17
|
+
TakeThermalImage,
|
|
18
|
+
TakeThermalVideo,
|
|
19
|
+
TakeVideo,
|
|
20
|
+
ZoomDescription,
|
|
21
|
+
)
|
|
22
|
+
from robot_interface.utilities.uuid_string_factory import uuid4_string
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
class InspectionTypes(str, Enum):
|
|
26
|
+
image = "Image"
|
|
27
|
+
thermal_image = "ThermalImage"
|
|
28
|
+
video = "Video"
|
|
29
|
+
thermal_video = "ThermalVideo"
|
|
30
|
+
audio = "Audio"
|
|
31
|
+
gas_measurement = "GasMeasurement"
|
|
32
|
+
|
|
33
|
+
|
|
34
|
+
class TaskType(str, Enum):
|
|
35
|
+
Inspection = "inspection"
|
|
36
|
+
ReturnToHome = "return_to_home"
|
|
37
|
+
|
|
38
|
+
|
|
39
|
+
class StartMissionInspectionDefinition(BaseModel):
|
|
40
|
+
type: InspectionTypes = Field(default=InspectionTypes.image)
|
|
41
|
+
inspection_target: InputPosition
|
|
42
|
+
analysis_type: Optional[str] = None
|
|
43
|
+
duration: Optional[float] = None
|
|
44
|
+
metadata: Optional[dict] = None
|
|
45
|
+
|
|
46
|
+
|
|
47
|
+
class StartMissionTaskDefinition(BaseModel):
|
|
48
|
+
id: Optional[str] = None
|
|
49
|
+
type: TaskType = Field(default=TaskType.Inspection)
|
|
50
|
+
pose: InputPose
|
|
51
|
+
inspection: Optional[StartMissionInspectionDefinition] = None
|
|
52
|
+
tag: Optional[str] = None
|
|
53
|
+
zoom: Optional[ZoomDescription] = None
|
|
54
|
+
|
|
55
|
+
|
|
56
|
+
class StartMissionDefinition(BaseModel):
|
|
57
|
+
tasks: List[StartMissionTaskDefinition]
|
|
58
|
+
name: Optional[str] = None
|
|
59
|
+
start_pose: Optional[InputPose] = None
|
|
60
|
+
|
|
61
|
+
|
|
62
|
+
def to_isar_mission(
|
|
63
|
+
start_mission_definition: StartMissionDefinition,
|
|
64
|
+
) -> Mission:
|
|
65
|
+
isar_tasks: List[TASKS] = []
|
|
66
|
+
|
|
67
|
+
for task_definition in start_mission_definition.tasks:
|
|
68
|
+
task: TASKS = to_isar_task(task_definition)
|
|
69
|
+
isar_tasks.append(task)
|
|
70
|
+
|
|
71
|
+
if not isar_tasks:
|
|
72
|
+
raise MissionPlannerError("Mission does not contain any valid tasks")
|
|
73
|
+
|
|
74
|
+
isar_mission_name: str = (
|
|
75
|
+
start_mission_definition.name
|
|
76
|
+
if start_mission_definition.name
|
|
77
|
+
else _build_mission_name()
|
|
78
|
+
)
|
|
79
|
+
|
|
80
|
+
start_pose = None
|
|
81
|
+
if start_mission_definition.start_pose:
|
|
82
|
+
start_pose = start_mission_definition.start_pose.to_alitra_pose()
|
|
83
|
+
|
|
84
|
+
return Mission(
|
|
85
|
+
tasks=isar_tasks,
|
|
86
|
+
name=isar_mission_name,
|
|
87
|
+
start_pose=start_pose,
|
|
88
|
+
)
|
|
89
|
+
|
|
90
|
+
|
|
91
|
+
def to_isar_task(task_definition: StartMissionTaskDefinition) -> TASKS:
|
|
92
|
+
if task_definition.type == TaskType.Inspection:
|
|
93
|
+
return to_inspection_task(task_definition)
|
|
94
|
+
elif task_definition.type == TaskType.ReturnToHome:
|
|
95
|
+
return create_return_to_home_task(task_definition)
|
|
96
|
+
else:
|
|
97
|
+
raise MissionPlannerError(
|
|
98
|
+
f"Failed to create task: '{task_definition.type}' is not a valid"
|
|
99
|
+
)
|
|
100
|
+
|
|
101
|
+
|
|
102
|
+
def to_inspection_task(task_definition: StartMissionTaskDefinition) -> TASKS:
|
|
103
|
+
inspection_definition = task_definition.inspection
|
|
104
|
+
|
|
105
|
+
if inspection_definition.type == InspectionTypes.image:
|
|
106
|
+
return TakeImage(
|
|
107
|
+
id=task_definition.id if task_definition.id else uuid4_string(),
|
|
108
|
+
robot_pose=task_definition.pose.to_alitra_pose(),
|
|
109
|
+
tag_id=task_definition.tag,
|
|
110
|
+
target=task_definition.inspection.inspection_target.to_alitra_position(),
|
|
111
|
+
metadata=task_definition.inspection.metadata,
|
|
112
|
+
zoom=task_definition.zoom,
|
|
113
|
+
)
|
|
114
|
+
elif inspection_definition.type == InspectionTypes.video:
|
|
115
|
+
return TakeVideo(
|
|
116
|
+
id=task_definition.id if task_definition.id else uuid4_string(),
|
|
117
|
+
robot_pose=task_definition.pose.to_alitra_pose(),
|
|
118
|
+
tag_id=task_definition.tag,
|
|
119
|
+
target=task_definition.inspection.inspection_target.to_alitra_position(),
|
|
120
|
+
duration=inspection_definition.duration,
|
|
121
|
+
metadata=task_definition.inspection.metadata,
|
|
122
|
+
zoom=task_definition.zoom,
|
|
123
|
+
)
|
|
124
|
+
elif inspection_definition.type == InspectionTypes.thermal_image:
|
|
125
|
+
return TakeThermalImage(
|
|
126
|
+
id=task_definition.id if task_definition.id else uuid4_string(),
|
|
127
|
+
robot_pose=task_definition.pose.to_alitra_pose(),
|
|
128
|
+
tag_id=task_definition.tag,
|
|
129
|
+
target=task_definition.inspection.inspection_target.to_alitra_position(),
|
|
130
|
+
metadata=task_definition.inspection.metadata,
|
|
131
|
+
zoom=task_definition.zoom,
|
|
132
|
+
)
|
|
133
|
+
elif inspection_definition.type == InspectionTypes.thermal_video:
|
|
134
|
+
return TakeThermalVideo(
|
|
135
|
+
id=task_definition.id if task_definition.id else uuid4_string(),
|
|
136
|
+
robot_pose=task_definition.pose.to_alitra_pose(),
|
|
137
|
+
tag_id=task_definition.tag,
|
|
138
|
+
target=task_definition.inspection.inspection_target.to_alitra_position(),
|
|
139
|
+
duration=inspection_definition.duration,
|
|
140
|
+
metadata=task_definition.inspection.metadata,
|
|
141
|
+
zoom=task_definition.zoom,
|
|
142
|
+
)
|
|
143
|
+
elif inspection_definition.type == InspectionTypes.audio:
|
|
144
|
+
return RecordAudio(
|
|
145
|
+
id=task_definition.id if task_definition.id else uuid4_string(),
|
|
146
|
+
robot_pose=task_definition.pose.to_alitra_pose(),
|
|
147
|
+
tag_id=task_definition.tag,
|
|
148
|
+
target=task_definition.inspection.inspection_target.to_alitra_position(),
|
|
149
|
+
duration=inspection_definition.duration,
|
|
150
|
+
metadata=task_definition.inspection.metadata,
|
|
151
|
+
)
|
|
152
|
+
elif inspection_definition.type == InspectionTypes.gas_measurement:
|
|
153
|
+
return TakeGasMeasurement(
|
|
154
|
+
id=task_definition.id if task_definition.id else uuid4_string(),
|
|
155
|
+
robot_pose=task_definition.pose.to_alitra_pose(),
|
|
156
|
+
tag_id=task_definition.tag,
|
|
157
|
+
metadata=task_definition.inspection.metadata,
|
|
158
|
+
)
|
|
159
|
+
else:
|
|
160
|
+
raise ValueError(
|
|
161
|
+
f"Inspection type '{inspection_definition.type}' not supported"
|
|
162
|
+
)
|
|
163
|
+
|
|
164
|
+
|
|
165
|
+
def create_return_to_home_task(
|
|
166
|
+
task_definition: StartMissionTaskDefinition,
|
|
167
|
+
) -> ReturnToHome:
|
|
168
|
+
return ReturnToHome(pose=task_definition.pose.to_alitra_pose())
|
|
169
|
+
|
|
170
|
+
|
|
171
|
+
def _build_mission_name() -> str:
|
|
172
|
+
return f"{settings.PLANT_SHORT_NAME}{settings.ROBOT_NAME}{int(time.time())}"
|
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
import logging
|
|
2
2
|
|
|
3
|
+
from fastapi import HTTPException
|
|
3
4
|
from injector import inject
|
|
4
5
|
|
|
5
6
|
from isar.apis.models.models import RobotInfoResponse
|
|
6
7
|
from isar.config.settings import robot_settings, settings
|
|
7
8
|
from isar.services.utilities.robot_utilities import RobotUtilities
|
|
8
|
-
from
|
|
9
|
+
from robot_interface.models.robots.media import MediaConfig
|
|
9
10
|
|
|
10
11
|
|
|
11
12
|
class RobotController:
|
|
@@ -17,8 +18,8 @@ class RobotController:
|
|
|
17
18
|
self.robot_utilities: RobotUtilities = robot_utilities
|
|
18
19
|
self.logger = logging.getLogger("api")
|
|
19
20
|
|
|
20
|
-
def generate_media_config(self):
|
|
21
|
-
media_config = self.robot_utilities.generate_media_config()
|
|
21
|
+
def generate_media_config(self) -> MediaConfig:
|
|
22
|
+
media_config: MediaConfig = self.robot_utilities.generate_media_config()
|
|
22
23
|
if media_config is None:
|
|
23
24
|
raise HTTPException(
|
|
24
25
|
status_code=204,
|
|
@@ -26,7 +27,7 @@ class RobotController:
|
|
|
26
27
|
)
|
|
27
28
|
return media_config
|
|
28
29
|
|
|
29
|
-
def get_info(self):
|
|
30
|
+
def get_info(self) -> RobotInfoResponse:
|
|
30
31
|
return RobotInfoResponse(
|
|
31
32
|
robot_package=settings.ROBOT_PACKAGE,
|
|
32
33
|
isar_id=settings.ISAR_ID,
|
|
@@ -1,16 +1,13 @@
|
|
|
1
1
|
import logging
|
|
2
2
|
from http import HTTPStatus
|
|
3
|
-
from typing import Optional
|
|
4
3
|
|
|
5
|
-
from alitra import Pose
|
|
6
4
|
from fastapi import Body, HTTPException, Path
|
|
7
5
|
from injector import inject
|
|
8
6
|
|
|
9
7
|
from isar.apis.models.models import (
|
|
10
8
|
ControlMissionResponse,
|
|
11
|
-
TaskResponse,
|
|
12
|
-
InputPose,
|
|
13
9
|
StartMissionResponse,
|
|
10
|
+
TaskResponse,
|
|
14
11
|
)
|
|
15
12
|
from isar.apis.models.start_mission_definition import (
|
|
16
13
|
StartMissionDefinition,
|
|
@@ -21,12 +18,7 @@ from isar.mission_planner.mission_planner_interface import MissionPlannerError
|
|
|
21
18
|
from isar.services.utilities.scheduling_utilities import SchedulingUtilities
|
|
22
19
|
from isar.state_machine.states_enum import States
|
|
23
20
|
from robot_interface.models.mission.mission import Mission
|
|
24
|
-
from robot_interface.models.mission.task import
|
|
25
|
-
TASKS,
|
|
26
|
-
InspectionTask,
|
|
27
|
-
MoveArm,
|
|
28
|
-
ReturnToHome,
|
|
29
|
-
)
|
|
21
|
+
from robot_interface.models.mission.task import TASKS, InspectionTask, MoveArm
|
|
30
22
|
|
|
31
23
|
|
|
32
24
|
class SchedulingController:
|
|
@@ -45,18 +37,6 @@ class SchedulingController:
|
|
|
45
37
|
title="Mission ID",
|
|
46
38
|
description="ID-number for predefined mission",
|
|
47
39
|
),
|
|
48
|
-
initial_pose: Optional[InputPose] = Body(
|
|
49
|
-
default=None,
|
|
50
|
-
description="The starting point of the mission. Used for initial "
|
|
51
|
-
"localization of robot",
|
|
52
|
-
embed=True,
|
|
53
|
-
),
|
|
54
|
-
return_pose: Optional[InputPose] = Body(
|
|
55
|
-
default=None,
|
|
56
|
-
description="End pose of the mission. The robot return to the specified "
|
|
57
|
-
"pose after finishing all inspections",
|
|
58
|
-
embed=True,
|
|
59
|
-
),
|
|
60
40
|
) -> StartMissionResponse:
|
|
61
41
|
self.logger.info(f"Received request to start mission with id {mission_id}")
|
|
62
42
|
|
|
@@ -64,23 +44,14 @@ class SchedulingController:
|
|
|
64
44
|
self.scheduling_utilities.verify_state_machine_ready_to_receive_mission(state)
|
|
65
45
|
|
|
66
46
|
mission: Mission = self.scheduling_utilities.get_mission(mission_id)
|
|
67
|
-
if return_pose:
|
|
68
|
-
pose: Pose = return_pose.to_alitra_pose()
|
|
69
|
-
mission.tasks.append(ReturnToHome(pose=pose))
|
|
70
47
|
|
|
71
48
|
self.scheduling_utilities.verify_robot_capable_of_mission(
|
|
72
49
|
mission=mission, robot_capabilities=robot_settings.CAPABILITIES
|
|
73
50
|
)
|
|
74
51
|
|
|
75
|
-
initial_pose_alitra: Optional[Pose] = (
|
|
76
|
-
initial_pose.to_alitra_pose() if initial_pose else None
|
|
77
|
-
)
|
|
78
|
-
|
|
79
52
|
self.logger.info(f"Starting mission with ISAR Mission ID: '{mission.id}'")
|
|
80
53
|
|
|
81
|
-
self.scheduling_utilities.start_mission(
|
|
82
|
-
mission=mission, initial_pose=initial_pose_alitra
|
|
83
|
-
)
|
|
54
|
+
self.scheduling_utilities.start_mission(mission=mission)
|
|
84
55
|
|
|
85
56
|
return self._api_response(mission)
|
|
86
57
|
|
|
@@ -92,18 +63,6 @@ class SchedulingController:
|
|
|
92
63
|
title="Mission Definition",
|
|
93
64
|
description="Description of the mission in json format",
|
|
94
65
|
),
|
|
95
|
-
initial_pose: Optional[InputPose] = Body(
|
|
96
|
-
default=None,
|
|
97
|
-
description="The starting point of the mission. Used for initial "
|
|
98
|
-
"localization of robot",
|
|
99
|
-
embed=True,
|
|
100
|
-
),
|
|
101
|
-
return_pose: Optional[InputPose] = Body(
|
|
102
|
-
default=None,
|
|
103
|
-
description="End pose of the mission. The robot return to the specified "
|
|
104
|
-
"pose after finishing all inspections",
|
|
105
|
-
embed=True,
|
|
106
|
-
),
|
|
107
66
|
) -> StartMissionResponse:
|
|
108
67
|
self.logger.info("Received request to start new mission")
|
|
109
68
|
|
|
@@ -121,7 +80,7 @@ class SchedulingController:
|
|
|
121
80
|
|
|
122
81
|
try:
|
|
123
82
|
mission: Mission = to_isar_mission(
|
|
124
|
-
start_mission_definition=mission_definition
|
|
83
|
+
start_mission_definition=mission_definition
|
|
125
84
|
)
|
|
126
85
|
except MissionPlannerError as e:
|
|
127
86
|
error_message = f"Bad Request - Cannot create ISAR mission: {e}"
|
|
@@ -135,14 +94,8 @@ class SchedulingController:
|
|
|
135
94
|
mission=mission, robot_capabilities=robot_settings.CAPABILITIES
|
|
136
95
|
)
|
|
137
96
|
|
|
138
|
-
initial_pose_alitra: Optional[Pose] = (
|
|
139
|
-
initial_pose.to_alitra_pose() if initial_pose else None
|
|
140
|
-
)
|
|
141
|
-
|
|
142
97
|
self.logger.info(f"Starting mission: {mission.id}")
|
|
143
|
-
self.scheduling_utilities.start_mission(
|
|
144
|
-
mission=mission, initial_pose=initial_pose_alitra
|
|
145
|
-
)
|
|
98
|
+
self.scheduling_utilities.start_mission(mission=mission)
|
|
146
99
|
return self._api_response(mission)
|
|
147
100
|
|
|
148
101
|
def pause_mission(self) -> ControlMissionResponse:
|
|
@@ -152,7 +105,6 @@ class SchedulingController:
|
|
|
152
105
|
|
|
153
106
|
if state not in [
|
|
154
107
|
States.Monitor,
|
|
155
|
-
States.Initiate,
|
|
156
108
|
]:
|
|
157
109
|
error_message = (
|
|
158
110
|
f"Conflict - Pause command received in invalid state - State: {state}"
|
|
@@ -245,10 +197,7 @@ class SchedulingController:
|
|
|
245
197
|
self.logger.info(
|
|
246
198
|
f"Starting move arm mission with ISAR Mission ID: '{mission.id}'"
|
|
247
199
|
)
|
|
248
|
-
self.scheduling_utilities.start_mission(
|
|
249
|
-
mission=mission,
|
|
250
|
-
initial_pose=None,
|
|
251
|
-
)
|
|
200
|
+
self.scheduling_utilities.start_mission(mission=mission)
|
|
252
201
|
return self._api_response(mission)
|
|
253
202
|
|
|
254
203
|
def _api_response(self, mission: Mission) -> StartMissionResponse:
|