Skip to content
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

feat: support $unknownFields #1912

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Commits on Jul 12, 2023

  1. feat: support $unknownFields

    This add `$unknownFields` property to generated code. It is populated on
    `.decode()` when decoder encounters currently unknown field, and
    similarly used by encoder to serialize unknown fields as they are into a
    binary data.
    
    If user stores unknown fields and then upgrades their protobufs to the
    latest spec - there is a chance that some of the previously unknown
    fields will become known. This is handled in the encoder by attempting
    to decode the fields first.
    
    The name of the field starts with `$` because it is not a valid
    character for a field name according to protobuf v3 specification.
    indutny-signal committed Jul 12, 2023
    Configuration menu
    Copy the full SHA
    5875cbf View commit details
    Browse the repository at this point in the history