You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
It is not possible to filter (-F/--filter) using a comma in the filter string.
To Reproduce
Steps to reproduce the behavior:
Run any filer using -F/--filter that contains a comma.
Expected behavior
Be able to filter on fields that contain a comma.
Screenshots
$ elm DeviceList -F displayName~test,
Usage: elm DeviceList [OPTIONS]
Error: Invalid value for '--filter' / '-F': format must be 'FIELD[>:,<:,>,<,!:,:,~,!~]VALUE'
$ elm DeviceList -F displayName~test\,
Usage: elm DeviceList [OPTIONS]
Error: Invalid value for '--filter' / '-F': format must be 'FIELD[>:,<:,>,<,!:,:,~,!~]VALUE'
$ elm DeviceList -F "displayName~test\,"
Usage: elm DeviceList [OPTIONS]
Error: Invalid value for '--filter' / '-F': format must be 'FIELD[>:,<:,>,<,!:,:,~,!~]VALUE'
$ elm DeviceList -F "displayName~test,"
Usage: elm DeviceList [OPTIONS]
Error: Invalid value for '--filter' / '-F': format must be 'FIELD[>:,<:,>,<,!:,:,~,!~]VALUE'
$ elm DeviceList -F 'displayName~test,'
Usage: elm DeviceList [OPTIONS]
Error: Invalid value for '--filter' / '-F': format must be 'FIELD[>:,<:,>,<,!:,:,~,!~]VALUE'
$ elm DeviceList -F 'displayName~test,,'
Usage: elm DeviceList [OPTIONS]
Error: Invalid value for '--filter' / '-F': format must be 'FIELD[>:,<:,>,<,!:,:,~,!~]VALUE'
$ elm DeviceList -F 'displayName~test\\,'
Usage: elm DeviceList [OPTIONS]
Error: Invalid value for '--filter' / '-F': format must be 'FIELD[>:,<:,>,<,!:,:,~,!~]VALUE'
$ elm DeviceList -F 'displayName~test\\\,'
Usage: elm DeviceList [OPTIONS]
Error: Invalid value for '--filter' / '-F': format must be 'FIELD[>:,<:,>,<,!:,:,~,!~]VALUE'
Desktop (please complete the following information):
OS: Mac 13.5.1 (22G90)
Shell: GNU bash, version 5.2.15(1)-release (aarch64-apple-darwin22.1.0)
The text was updated successfully, but these errors were encountered:
+ #split filters by commas except if they're proceeded by a backslash
+ for filter in re.split(r'[^\\],', filters):
+ #now remove the backslash we used to protect the comma from split above
+ filter = filter.replace('\\,',',')
Describe the bug
It is not possible to filter (-F/--filter) using a comma in the filter string.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
Be able to filter on fields that contain a comma.
Screenshots
Desktop (please complete the following information):
The text was updated successfully, but these errors were encountered: