Skip to content
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

Feature request: ability to exclude topics #24

Open
Rayman opened this issue Jul 28, 2022 · 1 comment
Open

Feature request: ability to exclude topics #24

Rayman opened this issue Jul 28, 2022 · 1 comment

Comments

@Rayman
Copy link

Rayman commented Jul 28, 2022

With #8 we now have a way to snapshot all topics. It would be really nice to be able to exclude certain topics from this list (because they are too big/not needed). I've thought of two ways to implement this.

Option 1: Exclude regex

rosbag record has several options to filter which topics to record. We could also add these to the cli and ros parameters

Usage: rosbag record TOPIC1 [TOPIC2 TOPIC3 ...]

Options:
  -a, --all             record all topics
  -e, --regex           match topics using regular expressions
  -x EXCLUDE_REGEX, --exclude=EXCLUDE_REGEX
                        exclude topics matching the follow regular expression
                        (subtracts from -a or regex)

Option2: fix count

I've tried to exclude topics by changing the maximum message count to 0. However 0 is a special value that means "inherit from default options". We could change the special value to another value (-2?) so that 0 can be used to exclude topics.

<rosparam>
    topics:
    - /topic_name: {count: 0}
</rosparam>

I've also tried limiting the memory of topics to 1 byte, that works, but the topics are still subscribed, so I would like a better solution.

What do you think of this proposal?

@JanezCim
Copy link

I'd also welcome a way to exclude topics from being recorded. This feature has my vote. Thanks!

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

No branches or pull requests

2 participants