Skip to content

Allow spaces in -F/--fields and -X/--exclude values#213

Open
yunzheng wants to merge 4 commits intomainfrom
rdump-field-strip-spaces
Open

Allow spaces in -F/--fields and -X/--exclude values#213
yunzheng wants to merge 4 commits intomainfrom
rdump-field-strip-spaces

Conversation

@yunzheng
Copy link
Member

fixes #212

@codecov
Copy link

codecov bot commented Feb 16, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 84.20%. Comparing base (e9118cf) to head (dc7ab00).

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #213      +/-   ##
==========================================
+ Coverage   84.18%   84.20%   +0.02%     
==========================================
  Files          35       35              
  Lines        3736     3741       +5     
==========================================
+ Hits         3145     3150       +5     
  Misses        591      591              
Flag Coverage Δ
unittests 84.20% <100.00%> (+0.02%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR addresses issue #212 by making rdump accept comma-separated --fields/-F and --exclude/-X values that include surrounding whitespace, so users can write lists like "foo, bar" without breaking field selection.

Changes:

  • Strip whitespace around individual field names parsed from --fields and --exclude in rdump.
  • Add a regression test ensuring spaced field lists work for both inclusion and exclusion.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.

File Description
flow/record/tools/rdump.py Strips whitespace when parsing --fields / --exclude into lists used for record rewriting.
tests/tools/test_rdump.py Adds a test case validating spaced field lists for --fields and --exclude.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 2 out of 2 changed files in this pull request and generated no new comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

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

Successfully merging this pull request may close these issues.

Fields argument's comma-seperated list does not accept spaces

2 participants