-
Notifications
You must be signed in to change notification settings - Fork 453
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
Bring most of the protos shuffle/update over to the 1.x branch #1432
Merged
thomasvl
merged 13 commits into
apple:1_x_release_branch
from
thomasvl:update_n_shuffle_protos
Jul 26, 2023
Merged
Bring most of the protos shuffle/update over to the 1.x branch #1432
thomasvl
merged 13 commits into
apple:1_x_release_branch
from
thomasvl:update_n_shuffle_protos
Jul 26, 2023
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Using upstream 1c23a17f091a0dd7ad44ddc4b0509d39773578e8.
Using commit 6e9357372ba5a183b1b2ad214f09f294781b708d
"upstream/" is now a copy of the files protocolbuffers/protobuf, this is basically moving the "google/protobuf" and "conformance" directories just down a level, but it will hopefully make things a little more clear. All the _local_ .proto files for other purposes are now moved into sub directories that match the name of their directories in "Sources/" or "Tests/". The places were SwiftProtobuf was using upstream files for tests, those files have now been forked. So they exist within "Protos/SwiftProtobufTests/" but they will *no* longer be updated to match upstream. This is a *good* thing as in the past there have been build breaks with upstream changed and it broke the test. Now the files are specific to this project and any edits desired can be made. NOTE: At some point the files should get updated/reduced down to only what is needed because they have always had some extra message/enums/fields that the local tests didn't need, and so the simplification would likely be good. Lastly, a few upstream .proto files are now mirrored from "Protos/upstream/" in to the specific project level directory needed (SwiftProtobuf, Conformance, etc.). This gets the files clearly in a target directory where they are used, but does mean they have to be updated in this second location. Symlinks might have worked for this, but to avoid issues building the package on any platform (Windows?), the copies were used instead. The "Reference/" directory was then update to mirror this new layout.
NOTE: This does *not* yet update the .proto files that use editions features; that can't be done until the plugin support all the new constructs. Using upstream commit 7e9d0c1630a51b2964ff1f359bc9a0e0bd4dfe78
Now that the files are specific to SwiftProtobuf, go ahead and trim files down to the things actually being used. Since the reference tests still include a lot of upstream things, they still generate there.
Swap to merging in another set of extensions in the cases we were do that.
There was one tiny message used, so recreate it in unittest_proto3.proto.
allevato
approved these changes
Jul 26, 2023
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This should bring everything over from
main
except for final commit in those changes that renamed the proto packages to be project specific. That's not an easy cherry-pick because of the other differences between the branch andmain
; so might have to be done from scratch if desired to have it on the branch.