Conversation
PiperOrigin-RevId: 892354630
PiperOrigin-RevId: 892959815
PiperOrigin-RevId: 893673111
There was a problem hiding this comment.
Code Review
This pull request updates the regex pattern in betocq/setup_utils.py to accommodate additional characters in the RSSI field. A review comment suggests using a more robust non-whitespace matcher (\S+) since the field is skipped and not captured, which would prevent future breakages from unexpected output formats.
| (\d+) # Captures Frequency | ||
| \s+ | ||
| [-\d.]+ # Matches RSSI (skipped) | ||
| [-\d()./:]+ # Matches RSSI (skipped) |
There was a problem hiding this comment.
The regex for the RSSI field is being expanded to include more characters, but it remains brittle as it still excludes alphabetic characters (e.g., for 'N/A' or 'unknown' values) and other potential punctuation. Since this field is explicitly skipped and not captured, using \S+ (matching any non-whitespace characters) would be more robust and maintainable, preventing the need for future updates when encountering different output formats from various devices.
| [-\d()./:]+ # Matches RSSI (skipped) | |
| \S+ # Matches RSSI (skipped) |
No description provided.