-
Notifications
You must be signed in to change notification settings - Fork 12
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
support for wildcards #6
Comments
Sounds interesting! As you mentioned this should be implemented separately from the existing API as the wildcard does not seem to be a valid input there. |
Is a PR planned? Repeated wildcards seem to be intended https://google.aip.dev/161#wildcards |
That doc mentions the wildcards in the context of repeated fields only as a way to describe all possible indexes in a list. If I got the initial request right #6 (comment) the wildcards are wanted on all types of fields, not just repeated fields. In both cases this should be possible to implement. |
Sounds great. If you are interested in a PR regarding the repeated field wildcard just let me know. |
Repeated fields are already supported, example: Line 265 in d05c935
If the wildcard is what you need then your PR is welcome (keep in mind that the existing behavior should also be supported). |
Yes, had a look into the sources on mobile and also thought that it already should be possible just without wildcard asterisk. Should be fine, will try it in a few days. Thanks |
@mennanov Works well, thanks. But I don't understand why the recommendation is to normalize and validate paths since normalize would remove fields of repeated messages. And in fieldmask-utils you referring to this project for simple usage with protobuf messages but this project does not cover merge with fieldmask (which is needed for update masks). Or am I missing something? edit: I will consider a PR for Merge. Shouldn't be a big deal, then we can discuss it there. edit2: Since |
There is an example on how to use Line 60 in d05c935
Yeah, that's true. Looks like repeated messages are not well supported by the standard go proto package: they are considered invalid. However this library supported them. |
Thanks for your reply! Although we're leaving the topic of this issue. In my opinion this merge approach does not solve two requirements:
|
Hi there.
I was wondering if you would be interested in a PR to add support for wildcards in field filters. For example, something like
"*.a.b.c"
would match all paths with any field followed by a nesteda
,b
, andc
field. Perhaps this could be exposed through a separate WildcardNestedMask type to avoid changing existing behaviour.If you would be interested in this, please let me know, and I would be happy to make a PR. :)
The text was updated successfully, but these errors were encountered: