Skip to content

Protobuf Practice

Edit the schema and the descriptor checks run as you type. Continue when everything passes.

Progress

Exercise 4: Reserved Fields

4. Reserved Fields

Context
Removing a field frees its number and name for reuse, and reusing them makes readers silently misread old data. reserved blocks that.
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

Checks remaining above