-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Removal of .proto files from googleapis-common-protos broke us #13545
Comments
I see that the source .proto files are in https://github.com/googleapis/googleapis however that repo is not tagged with the release information applied to https://pypi.org/project/googleapis-common-protos and this repository so it's not possible as far as I can tell to determine which revision of the https://github.com/googleapis/googleapis repo to pull to grab the source that corresponds to a specific version of googleapis-common-protos |
Thanks for reporting this issue! We will take a look and figure out how to best address it. |
I believe this is a duplicate of my previously-reported issue: #13526 |
Follow up on #13545 (comment), the links in the Github point to the specific version of For example, see release 1.68.0
Click on commit eb554e8 and you can find the specific commit of googleapis used. Source-Link: |
It's recommended to use googleapis/googleapis to retrieve the source protos, as that is the source of truth for the protos. The protos ( |
@parthea I'm not sure this solution works for existing users of the library. A lot of us have been relying on the fact that the core API proto can be installed with pip, in order to use them when they call protoc. Say I have a code base with syntax = "proto3";
package demo;
import "google/type/date.proto";
import "google/protobuf/timestamp.proto";
message Demo {
google.protobuf.Timestamp timestamp = 1;
google.type.Date trade_date = 5;
}
With the previous version of pip install "googleapis-common-protos<=1.67.0" grpcio-tools I can simply build my proto from the command line: python -m grpc_tools.protoc \
--proto_path=$(python -c 'import pathlib;import grpc_tools;print(pathlib.Path(grpc_tools.__file__).parent.absolute() / "_proto")') \
--proto_path=$(python -c 'import pathlib;import google;print(pathlib.Path(google.__path__[0]).parent)') \
--proto_path=./ \
--python_out=./ \
demo.proto This is no longer possible because half of the protos are missing. The suggested solution requires manually getting the proto from github, which isn't suitable for automated CI pipelines. |
In terms of adding this to CI, if you know the
For example, In https://github.com/googleapis/python-api-common-protos/pull/266/files, we were simply cloning
Alternatively, you can maintain your own copy of the protos by syncing with googleapis/googleapis as needed. If we were to add the protos in
|
@parthea You're proposing that clients use a project-specific side-channel (GitHub Releases API) to collect metadata associated with the This introduces a lot of toil to downstream users, and runs contrary to the repository's stated goal of providing "idiomatic Python". Why having
|
Thanks for the detailed responses. I agree with the sentiment discussed in this issue. Since From https://opensource.google/documentation/policies/library-breaking-change#breaking_change,
If/When googleapis/gapic-generator-python#2349 is merged and released, I will move forward with applying the necessary changes to |
|
Determine this is the right repository
Summary of the issue
Context
23e0f96 removed the source .proto files for Google APIs. Since we use these protos in our project to build our own services with gRPC, this broke our build process.
Expected Behavior:
I would have expected the .proto files to have stayed in place or another pip package to be provided that published the source proto files for existing users.
Actual Behavior:
.proto files removed, build broken
API client name and version
No response
Reproduction steps: code
file: main.py
Reproduction steps: supporting files
file: mydata.csv
Reproduction steps: actual results
file: output.txtmydata.csv
Reproduction steps: expected results
file: output.txtmydata.csv
OS & version + platform
No response
Python environment
No response
Python dependencies
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: