{"action":"created","issue":{"url":"https://api.github.com/repos/google/protobuf/issues/1313","repository_url":"https://api.github.com/repos/google/protobuf","labels_url":"https://api.github.com/repos/google/protobuf/issues/1313/labels{/name}","comments_url":"https://api.github.com/repos/google/protobuf/issues/1313/comments","events_url":"https://api.github.com/repos/google/protobuf/issues/1313/events","html_url":"https://github.com/google/protobuf/issues/1313","id":139745204,"number":1313,"title":"py_proto_library gets confused when a filegroup is provided for srcs","user":{"login":"davidzchen","id":5283042,"avatar_url":"https://avatars1.githubusercontent.com/u/5283042?v=4","gravatar_id":"","url":"https://api.github.com/users/davidzchen","html_url":"https://github.com/davidzchen","followers_url":"https://api.github.com/users/davidzchen/followers","following_url":"https://api.github.com/users/davidzchen/following{/other_user}","gists_url":"https://api.github.com/users/davidzchen/gists{/gist_id}","starred_url":"https://api.github.com/users/davidzchen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/davidzchen/subscriptions","organizations_url":"https://api.github.com/users/davidzchen/orgs","repos_url":"https://api.github.com/users/davidzchen/repos","events_url":"https://api.github.com/users/davidzchen/events{/privacy}","received_events_url":"https://api.github.com/users/davidzchen/received_events","type":"User","site_admin":false},"labels":[{"id":314806986,"url":"https://api.github.com/repos/google/protobuf/labels/bazel","name":"bazel","color":"bfd4f2","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":6,"created_at":"2016-03-10T00:29:44Z","updated_at":"2018-03-29T17:18:21Z","closed_at":null,"author_association":"MEMBER","body":"Currently, it is not possible to do the following:\n## Repository `foo`\n\n`BUILD`:\n\n``` python\nfilegroup(\n    name = \"foo_pb_srcs\",\n    srcs = [\"foo.proto\"],\n)\n```\n## Repository `bar`\n\n`WORKSPACE`:\n\n``` python\ngit_repository(\n    name = \"foo\"\n    remote = \"...\"\n   ...\n)\n```\n\n`BUILD`:\n\n``` python\nload(\"@protobuf//:protobuf.bzl\", \"py_proto_library\")\n\npy_proto_library(\n    name = \"foo_pb\",\n    srcs = [\"@foo//:foo_pb_srcs\"],\n)\n```\n\nI attempted to have this setup where I add a `filegroup` to `//src/main/protobuf` in the Bazel repository for `build.proto` and then have a `py_proto_library` target in a different repository that uses that filegroup (which is available in `@bazel_tools//`. This is the error that I get:\n\n```\n❯❯❯ bazel build //skydoc:build_pb\nExtracting Bazel installation...\nSending SIGTERM to previous Bazel server (pid=10593)... done.\n.......\nERROR: /Users/dzc/Sandbox/skydoc/skydoc/BUILD:5:1: //skydoc:build_pb_genproto: label '@bazel_tools//src/main/protobuf:build_p_pb2.py' is not in the current package.\nERROR: no such package 'skydoc': Package 'skydoc' contains errors.\nINFO: Elapsed time: 1.493s\n```\n"},"comment":{"url":"https://api.github.com/repos/google/protobuf/issues/comments/377308011","html_url":"https://github.com/google/protobuf/issues/1313#issuecomment-377308011","issue_url":"https://api.github.com/repos/google/protobuf/issues/1313","id":377308011,"user":{"login":"promiseofcake","id":1462322,"avatar_url":"https://avatars0.githubusercontent.com/u/1462322?v=4","gravatar_id":"","url":"https://api.github.com/users/promiseofcake","html_url":"https://github.com/promiseofcake","followers_url":"https://api.github.com/users/promiseofcake/followers","following_url":"https://api.github.com/users/promiseofcake/following{/other_user}","gists_url":"https://api.github.com/users/promiseofcake/gists{/gist_id}","starred_url":"https://api.github.com/users/promiseofcake/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/promiseofcake/subscriptions","organizations_url":"https://api.github.com/users/promiseofcake/orgs","repos_url":"https://api.github.com/users/promiseofcake/repos","events_url":"https://api.github.com/users/promiseofcake/events{/privacy}","received_events_url":"https://api.github.com/users/promiseofcake/received_events","type":"User","site_admin":false},"created_at":"2018-03-29T17:18:21Z","updated_at":"2018-03-29T17:18:21Z","author_association":"NONE","body":"@xfxyjwf we also need to generate gRPC services and that isn't provided by the native rule."}}
{"actor":{"display_login":"promiseofcake"}}