Skip to content

Commit add7e7c

Browse files
authored
ROS2 tools update (#10)
* refactor: better error handling and response parsing for ROS2 tools, add blacklist where applicable. * feat(ros2): add ros2 topic echo tool. * chore: bump version to 1.0.4, update CHANGELOG.md
1 parent f6b331b commit add7e7c

File tree

5 files changed

+233
-217
lines changed

5 files changed

+233
-217
lines changed

CHANGELOG.md

+15
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,21 @@ All notable changes to this project will be documented in this file.
55
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
66
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
77

8+
## [1.0.4] - 2024-08-21
9+
10+
### Added
11+
12+
* Implemented ros2 topic echo tool.
13+
14+
### Changed
15+
16+
* Refactored ROS2 tools for better error handling and response parsing.
17+
* Added blacklist parameters to relevant ROS2 tools.
18+
19+
### Fixed
20+
21+
* Fixed a bug where getting a list of ROS2 log files failed.
22+
823
## [1.0.3] - 2024-08-17
924

1025
### Added

Dockerfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ RUN apt-get update && apt-get install -y \
2828
RUN apt-get update && apt-get install -y python3.9
2929
RUN apt-get update && apt-get install -y python3-pip
3030
RUN python3 -m pip install -U python-dotenv catkin_tools
31-
RUN python3.9 -m pip install -U jpl-rosa>=1.0.1
31+
RUN python3.9 -m pip install -U jpl-rosa>=1.0.4
3232

3333
# Configure ROS
3434
RUN rosdep update

setup.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
setup(
2525
name="jpl-rosa",
26-
version="1.0.3",
26+
version="1.0.4",
2727
license="Apache 2.0",
2828
description="ROSA: the Robot Operating System Agent",
2929
long_description=long_description,

src/rosa/tools/ros1.py

+2-3
Original file line numberDiff line numberDiff line change
@@ -338,7 +338,7 @@ def rostopic_echo(
338338
timeout: float = 1.0,
339339
) -> dict:
340340
"""
341-
Opens a new terminal window and echoes the contents of a specific ROS topic.
341+
Echoes the contents of a specific ROS topic.
342342
343343
:param topic: The name of the ROS topic to echo.
344344
:param count: The number of messages to echo. Valid range is 1-100.
@@ -675,7 +675,7 @@ def roslog_list(min_size: int = 2048, blacklist: Optional[List[str]] = None) ->
675675
"""
676676

677677
logs = []
678-
log_dirs = get_roslog_directories.invoke({})
678+
log_dirs = get_roslog_directories()
679679

680680
for _, log_dir in log_dirs.items():
681681
if not log_dir:
@@ -729,7 +729,6 @@ def roslog_list(min_size: int = 2048, blacklist: Optional[List[str]] = None) ->
729729
)
730730

731731

732-
@tool
733732
def get_roslog_directories() -> dict:
734733
"""Returns any available ROS log directories."""
735734
default_directory = rospkg.get_log_dir()

0 commit comments

Comments
 (0)