Skip to content
protobuf.kmcd.dev

Practice

Protobuf Practice

Edit the schema, wait for the descriptor checks, and continue when everything passes.

Progress

Exercise 5: Reserved Fields

5. Reserved Fields
Context
When a field is removed from a message, its number and name should not be reused. Reserving them prevents future schema edits from accidentally colliding with old serialized data.
Task

Reserve field number 3 and field name phone in UserAccount.

schema.proto
Valid Schema
syntax = "proto3";

package practice;

message UserAccount {
  string id = 1;
  string email = 2;
  // The field 'phone' at number 3 was removed. Protect it!
}
EVALUATION_CHECKS
Field number 3 is reserved.
Field name 'phone' is reserved.

Exercise Incomplete

Please satisfy all checks above