Skip to content

Commit

Permalink
Introduce new annotation to skip fields for py-deprecated
Browse files Browse the repository at this point in the history
Summary:
The thrift-py-deprecated codegen (especially when the json option is turned-on) cannot deal with maps/sets with structured keys.

Introduce a new (field-level) annotation to skip over problematic fields.

The next diff will modify the compiler to acutlaly skip over annotated fields.

Reviewed By: Filip-F

Differential Revision: D62617627

fbshipit-source-id: 2b79a1d0e99de1cc497a7cf8aed9574e55e2d085
  • Loading branch information
Pranav Thulasiram Bhat authored and facebook-github-bot committed Sep 20, 2024
1 parent d6daa83 commit 1e478b2
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions thrift/annotation/python.thrift
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,12 @@ namespace py thrift.annotation.python
@scope.Definition
struct Py3Hidden {}

/// Hides in thrift-py-deprecated only
@scope.Field
struct PyDeprecatedHidden {
1: string reason;
}

@scope.Enum
struct Flags {}

Expand Down

0 comments on commit 1e478b2

Please sign in to comment.