Skip to content

Commit dbe3798

Browse files
fix: moving components between files is breaking (#929)
* fix: moving components between files is breaking * fix: clarification Co-authored-by: Noah Dietz <noahdietz@users.noreply.github.com> * fix: make the sentence make more sense * fix: suggested wording * fix: changelog Co-authored-by: Noah Dietz <noahdietz@users.noreply.github.com>
1 parent b6e429a commit dbe3798

1 file changed

Lines changed: 11 additions & 1 deletion

File tree

aip/general/0180.md

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,15 @@ add the new component, but **must not** remove the existing one. In situations
8686
where this can allow users to specify conflicting values for the same semantic
8787
idea, the behavior **must** be clearly specified.
8888

89+
### Moving components between files
90+
91+
Existing components **must not** be moved between files.
92+
93+
Moving a component from one proto file to another within the same package is
94+
wire compatible, however, the code generated for languages like C++ or Python
95+
will result in breaking change since `import` and `#include` will no longer
96+
point to the correct code location.
97+
8998
### Moving into oneofs
9099

91100
Existing fields **must not** be moved into or out of a oneof. This is a
@@ -140,7 +149,8 @@ this guidance could ostensibly prevent _any_ change (which is not the intent).
140149

141150
## Changelog
142151

143-
- **2022-06-??**: Added more links to other AIPs with compatibility concerns
152+
- **2022-08-11**: Added "Moving components between files" section.
153+
- **2022-06-01**: Added more links to other AIPs with compatibility concerns
144154
- **2019-12-16**: Clarified that moving existing fields into oneofs is
145155
breaking.
146156

0 commit comments

Comments
 (0)