Skip to content
This repository was archived by the owner on Mar 4, 2022. It is now read-only.
This repository was archived by the owner on Mar 4, 2022. It is now read-only.

Support experimental optional fields #571

@setpill

Description

@setpill

Protobuf allows experimental optional fields since v3.12. However, this needs to be specifically enabled in protoc, and prototool doesn't currently seem to allow this. prototool lint throws an exit code 255 with the following output:

$ prototool lint
2021-01-29T[time]Z	WARN	protoc returned a line we do not understand, please file this as an issue at https://github.com/uber/prototool/issues/new	{"protocLine": "[proto file]: This file contains proto3 optional fields, but --experimental_allow_proto3_optional was not set."}
<input>:1:1:[proto file]: This file contains proto3 optional fields, but --experimental_allow_proto3_optional was not set.

This can be reproduced by adding an optional field to any message and running the linter.

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