From fe168dd3d77a85cb4f867447b96b181c8951df0c Mon Sep 17 00:00:00 2001 From: ZdenekM Date: Tue, 23 Jan 2024 13:08:53 +0100 Subject: [PATCH] fix(arcor2_arserver): ik and fk RPCs --- README.md | 2 +- compose-files/fit-demo/docker-compose.yml | 2 +- src/docker/arcor2_arserver/BUILD | 2 +- src/python/arcor2_arserver/CHANGELOG.md | 6 ++++++ src/python/arcor2_arserver/VERSION | 2 +- src/python/arcor2_arserver/rpc/robot.py | 4 ++-- 6 files changed, 12 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index 38be0d4e2..e8276c8f4 100644 --- a/README.md +++ b/README.md @@ -42,7 +42,7 @@ The following video by [Kinali](https://www.kinali.cz/en/) shows the use case (o [README](src/python/arcor2_arserver/README.md) | [CHANGELOG](src/python/arcor2_arserver/CHANGELOG.md) - - 2023-07-20: [1.1.0](https://github.com/robofit/arcor2/releases/tag/arcor2_arserver%2F1.1.0) ([docker](https://hub.docker.com/r/arcor2/arcor2_arserver/tags?page=1&ordering=last_updated&name=1.1.0), [pypi](https://pypi.org/project/arcor2-arserver/1.1.0/)). + - 2024-01-23: [1.1.1](https://github.com/robofit/arcor2/releases/tag/arcor2_arserver%2F1.1.1) ([docker](https://hub.docker.com/r/arcor2/arcor2_arserver/tags?page=1&ordering=last_updated&name=1.1.1), [pypi](https://pypi.org/project/arcor2-arserver/1.1.1/)). ### arcor2_arserver_data diff --git a/compose-files/fit-demo/docker-compose.yml b/compose-files/fit-demo/docker-compose.yml index 92af4a0b6..513382b52 100644 --- a/compose-files/fit-demo/docker-compose.yml +++ b/compose-files/fit-demo/docker-compose.yml @@ -2,7 +2,7 @@ version: '3.8' services: fit-demo-arserver: - image: arcor2/arcor2_arserver:1.1.0 + image: arcor2/arcor2_arserver:1.1.1 container_name: fit-demo-arserver depends_on: fit-demo-project: diff --git a/src/docker/arcor2_arserver/BUILD b/src/docker/arcor2_arserver/BUILD index cc8f15df6..5d829b025 100644 --- a/src/docker/arcor2_arserver/BUILD +++ b/src/docker/arcor2_arserver/BUILD @@ -1,5 +1,5 @@ shell_source(name="start.sh", source="start.sh") docker_image( - name="arcor2_arserver", repository="arcor2/arcor2_arserver", dependencies=[":start.sh"], image_tags=["1.1.0"] + name="arcor2_arserver", repository="arcor2/arcor2_arserver", dependencies=[":start.sh"], image_tags=["1.1.1"] ) diff --git a/src/python/arcor2_arserver/CHANGELOG.md b/src/python/arcor2_arserver/CHANGELOG.md index 534d8bc14..1715b74e1 100644 --- a/src/python/arcor2_arserver/CHANGELOG.md +++ b/src/python/arcor2_arserver/CHANGELOG.md @@ -2,6 +2,12 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), +## [1.1.1] - 2024-01-23 + +### Fixed + +- `InverseKinematics` and `ForwardKinematics` RPCs were always returning `Object not found` error. + ## [1.1.0] - 2023-07-20 ### Changed diff --git a/src/python/arcor2_arserver/VERSION b/src/python/arcor2_arserver/VERSION index 1cc5f657e..8cfbc905b 100644 --- a/src/python/arcor2_arserver/VERSION +++ b/src/python/arcor2_arserver/VERSION @@ -1 +1 @@ -1.1.0 \ No newline at end of file +1.1.1 \ No newline at end of file diff --git a/src/python/arcor2_arserver/rpc/robot.py b/src/python/arcor2_arserver/rpc/robot.py index 084aacb42..31c2097af 100644 --- a/src/python/arcor2_arserver/rpc/robot.py +++ b/src/python/arcor2_arserver/rpc/robot.py @@ -383,7 +383,7 @@ async def move_to_action_point_cb(req: srpc.r.MoveToActionPoint.Request, ui: WsC async def ik_cb(req: srpc.r.InverseKinematics.Request, ui: WsClient) -> srpc.r.InverseKinematics.Response: glob.LOCK.scene_or_exception() - async with ctx_read_lock([req.args.robot_id, req.args.end_effector_id], glob.USERS.user_name(ui)): + async with ctx_read_lock(req.args.robot_id, glob.USERS.user_name(ui)): ensure_scene_started() robot_inst = get_robot_instance(req.args.robot_id) await check_feature(robot_inst, Robot.inverse_kinematics.__name__) @@ -404,7 +404,7 @@ async def ik_cb(req: srpc.r.InverseKinematics.Request, ui: WsClient) -> srpc.r.I async def fk_cb(req: srpc.r.ForwardKinematics.Request, ui: WsClient) -> srpc.r.ForwardKinematics.Response: glob.LOCK.scene_or_exception() - async with ctx_read_lock([req.args.robot_id, req.args.end_effector_id], glob.USERS.user_name(ui)): + async with ctx_read_lock(req.args.robot_id, glob.USERS.user_name(ui)): ensure_scene_started() robot_inst = get_robot_instance(req.args.robot_id) await check_feature(robot_inst, Robot.forward_kinematics.__name__)