Skip to content

Rename resource fields in request messages that don't follow style guide #1163

Closed

Description

I ran the apitool linter (prototype in #1162 ) and I got this:

Validating ateapi.proto (Control), 13 rule(s)...

  ✓ resource-metadata
  ✗ list-method-shape
      ateapi.Control.ListActorSnapshots: repeated field is named "snapshots", want "actor_snapshots" (the plural resource name, matching the method name)
  ✓ request-name-matches-method
  ✓ standard-method-returns-resource
  ✗ get-request-single-objectref
      ateapi.Control.GetActorSnapshot: resource field is named "snapshot", want "actor_snapshot"
      ateapi.Control.GetActorSnapshotTag: resource field is named "tag", want "actor_snapshot_tag"
  ✗ delete-request-shape
      ateapi.Control.DeleteActor: field "any_state" is not a message, want ateapi.ObjectRef or ateapi.DeleteOptions - non-resource control fields belong in ateapi.DeleteOptions
      ateapi.Control.DeleteActorSnapshotTag: resource field is named "tag", want "actor_snapshot_tag"
  ✓ list-response-name-matches-method
  ✓ enum-zero-value-unspecified
  ✓ enum-values-prefixed
  ✓ resource-status-field-shape
  ✓ no-oneofs
  ✗ create-update-request-embeds-resource
      ateapi.Control.UpdateActorSnapshotTag: resource field is named "tag", want "actor_snapshot_tag"

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions