New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[humble] Resolve recording option problem #1644
[humble] Resolve recording option problem #1644
Conversation
Signed-off-by: Barry Xu <barry.xu@sony.com>
if (args.all and (args.topics or args.regex)) or (args.topics and args.regex): | ||
return print_error('Must specify only one option out of topics, --regex or --all') | ||
if (args.all and args.topics): | ||
return print_error('Specify either --all or topics, but not both simultaneously.') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is an existing test case to check this
rosbag2/rosbag2_tests/test/rosbag2_tests/test_rosbag2_record_end_to_end.cpp
Lines 665 to 673 in ed8d984
TEST_F(RecordFixture, record_fails_if_both_all_and_topic_list_is_specified) { | |
internal::CaptureStderr(); | |
auto exit_code = | |
execute_and_wait_until_completion("ros2 bag record -a /some_topic", temporary_dir_path_); | |
auto error_output = internal::GetCapturedStderr(); | |
EXPECT_THAT(exit_code, Eq(EXIT_FAILURE)); | |
EXPECT_FALSE(error_output.empty()); | |
} |
Test rosbag2 / build_and_test (pull_request) failed.
|
BTW, Iron has the same problem. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Barry-Xu-2018 please take a look at this comment, #1620 (comment)
I added comments #1620 (comment). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Barry-Xu-2018 thanks for the explanation.
fix looks good, btw is this supposed to target to iron 1st. then we can backport it to humble. (i think we can do vice-versa, so just a question)
CC: @MichaelOrlov
Yes. I will create a new PR for Iron and then backport it to Humble. |
…d '--regex' at the same time Signed-off-by: Barry Xu <barry.xu@sony.com>
#1649 for Iron has been created. After it is merged, it will backport to Humble. |
Address #1620