Skip to content

working_copy: mark unused conflict_id proto field reserved #7234

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

martinvonz
Copy link
Member

The field has been unused since it was deprecated in 97b81a0 (~2 years ago). It should have been marked reserved instead of deprecated already then.

Checklist

If applicable:

  • I have updated CHANGELOG.md
  • I have updated the documentation (README.md, docs/, demos/)
  • I have updated the config schema (cli/src/config-schema.json)
  • I have added/updated tests to cover my changes

The field has been unused since it was deprecated in 97b81a0 (~2
years ago). It should have been marked reserved instead of deprecated
already then.
@martinvonz martinvonz requested a review from a team as a code owner August 13, 2025 16:06
Comment on lines -36 to 39
// Set only if file_type is Conflict
bytes conflict_id = 4 [deprecated = true];
MaterializedConflictData materialized_conflict_data = 5;
reserved 4;
}
Copy link
Member

Choose a reason for hiding this comment

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

nit: any reason to move this to the bottom? I personally like to keep the fields ordered and have a comment like reserved 4; // old Conflict file_type info or something. Not a big deal, though.

Copy link
Member Author

Choose a reason for hiding this comment

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

This is what I usually see in internal proto definitions at Google. I suspect the reason for putting them out of order is that you can include many tags in a single reserved statement (e.g. reserved 3, 14, 15;). I don't know if there's a good reason for grouping them like that, or if there's a good reason to not explain what they used to be used for. I'm happy to do it differently here.

Copy link
Member Author

Choose a reason for hiding this comment

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

We have two reserved fields in op_store.proto. The message they're in (View) actually has its fields grouped logically rather than ordered by tag number. We could put the reserved fields close to where they logically belong, but maybe this is another reason to move them to the end so they're less distracting. We can still have a comment about what they used to be for.

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