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

Proto enum validation + documentation rework #129

Merged
merged 5 commits into from
Jan 15, 2024
Merged

Conversation

Baccata
Copy link
Contributor

@Baccata Baccata commented Jan 12, 2024

Amends protobuf-related validation to be aware of the constraint that all proto enumerations should have a 0, and that open enumerations should avoid using the protoIndex trait as they are meant to be processed as raw string or raw ints.

Also starts reworking validation :

  • splits the README into smaller files : serialisation-related docs, and protocol-related docs
  • incorporate the protobuf documentation from smithy-translate in here, as the semantics of the translation should be derived from the meaning that we give to the smithy constructs in alloy
  • reword some of the documentation to be more formal sounding (reword usage of "we" into passives , fully expend "don't", etc)

TODOs :

  • Extract general-purpose traits into their own section (openEnum, UUID, etc)
  • Link all extracted documents in the readme

1. Open enums should not carry @protoIndex
2. Closed enums the members of which have proto indexes should have
one set to 0.
Amends protobuf-related validation to be aware of the constraint that
all proto enumerations should have a `0`, and that open enumerations
should avoid using the `protoIndex` trait as they are meant to be
processed as raw string or raw ints.
Copy link
Contributor

@daddykotex daddykotex left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

minor comments: regarding the proto index phasing, which is better than field number I guess, but I'm fine keeping it as is

also two leftover println I found

@Baccata Baccata marked this pull request as ready for review January 15, 2024 13:45
@Baccata Baccata merged commit e663867 into main Jan 15, 2024
3 checks passed
@Baccata Baccata deleted the proto-enum-validation branch January 31, 2024 09:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants