Support for ExcludeChats
pdex opened this issue · 2 comments
One of my filters is using ExcludeChats
a search of the github repo provides no additional documentation for why this field is unsupported and what the consequences are for interacting with that rule with gmailctl
.
I'm curious how much effort it would take to add support for ExcludeChats
or if it's just something that can't be done with gmailctl
.
Thank you for your time.
Warning: Error getting one or more filters from Gmail: 1 error occurred:
* importing filter "ANe1BmgJQFCHcYwLSwcmCDVO3pmuyTe_e3fX_Qhe-ons_xT8SqrclVTB1ygddXI3BN_OnbC53Q": importing criteria: criteria: usage of unsupported field "ExcludeChats" (value true)
They will be ignored in the diff.
The filter you see in the error will be "ignored in the diff", which is to say it won't be touched by gmailctl. I should make this more clear.
The problem with ExcludeChats
is that it seems to be a bit special. All other parameters (from
, to
, has:attachment
, etc) could be represented in the Gmail API by using the dedicated field in the FilterCriteria or by using an expression in the Query
field. This seems to be not true for ExcludeChats
, so filters with -in:chats
in the Query
field seem to be different w.r.t. filters that use the ExcludeChats
field explicitly. Adding support for this would be then a bit more work than usual.
With that said, could you try and see whether removing that filter manually from the Gmail UI and replacing it with the following works for you?
{
filter: {
query: '-in:chats',
},
actions: {
// ... something
},
},
This issue is stale because it has been open for 30 days without activity.
This will be closed in 7 days, unless you add the 'lifecycle/keep-alive' label or comment.