Skip to content

Message #6808

Closed
Closed

Description

@busFred

google.protobuf.json_format.MessageToJson() including_default_value_fields argument has been deprecated and removed since protobuf v5.26. need to use `always_print_fields_with_nopresence instead.

including_default_value_fields=True,

protocolbuffers/protobuf@2699579#diff-8de817c14d6a087981503c9aea38730b1b3e98f4e306db5ff9d525c7c304f234L89-L94
temporary fix is to just downgrade protobuf to 4.25

Activity

  1. DeepDuke commented on Mar 26, 2024

    @DeepDuke

    @busFred TKS! Downgrading protobuf to 4.25 works.

  2. arcra commented on Mar 28, 2024

    @arcra
    Member

    Thanks for flagging this.

    Looks like the new parameter was added less than 2 months ago in protocolbuffers/protobuf#15703, so it would only be present in very recent versions of protobuf dependencies, which might be a bit restrictive.

    For now, I'll add a restriction for the protobuf dependency to be < 5.0.0, and eventually we can update it to use the new parameter when we need to bump this dependency again for some reason.

  3. wimglenn commented on Jun 10, 2024

    @wimglenn

    @arcra Adding the upper bound like that is not really a great solution, because any reasonable solver with a constraint on protobuf>=5 will just go ahead and backtrack from tensorboard v2.17.0 to v2.16.2, and then remain broken.

    A more compatible way to solve this is detect protobuf version and fix the call into json_format.MessageToJson conditionally depending on protobuf 4.x or 5.x.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions