JsonFormat does not support extensions

29 views
Skip to first unread message

Eleanore Jin

unread,
May 13, 2020, 8:04:58 PM5/13/20
to Protocol Buffers
Hi Community, 

I just wonder if there is any workaround to convert Json to proto with extensions? 

Thanks a lot! 
Eleanore

Josh Haberman

unread,
May 15, 2020, 8:30:26 PM5/15/20
to Protocol Buffers
Hi Eleanore,

Python and Go support this I believe, but the other languages currently do not.

There is now a conformance test for this behavior, though it's only "recommended":

So other implementations may start adding support for this before too long.

Eleanore Jin

unread,
May 17, 2020, 10:44:59 PM5/17/20
to Protocol Buffers
Hi Josh, 

Thanks a lot for the response, can you please point to me to library from go or pythong that can do the transformation from json to proto that respects extensions?

Maybe I can look into the code and see if we can do the same in Java. 

Thanks a lot!
Eleanore
Reply all
Reply to author
Forward
0 new messages