Skip to content
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

Unexpected HTTP response codes for unimplemented GRPC methods #4392

Closed
hdevalence opened this issue May 15, 2024 · 7 comments · Fixed by #4424
Closed

Unexpected HTTP response codes for unimplemented GRPC methods #4392

hdevalence opened this issue May 15, 2024 · 7 comments · Fixed by #4424
Assignees
Labels
A-node Area: System design and implementation for node software C-bug Category: a bug needs-refinement unclear, incomplete, or stub issue that needs work _P-high High priority _P-V1 Priority: slated for V1 release
Milestone

Comments

@hdevalence
Copy link
Member

hdevalence commented May 15, 2024

Describe the bug

Skip reported unexpected HTTP response codes for unimplemented GRPC methods:

Another thing I noticed I think has to do with the problem I was running into with grpcurl. Instead of returning "Unimplemented" GRPC error for unimplemented queries, I get back an unknown error type

2024/05/15 15:05:12 rpc error: code = Unknown desc = unexpected HTTP status code received from server: 405 (Method Not Allowed); malformed header: missing HTTP content-type
exit status 1

Skip API uses the unimplemented error type to detect feature support in certain cases. We may need to handle this other error type specially since it seems like we are getting it instead of unimplemented.

They also reported that grpcurl didn't work, potentially because of problems with reflection.

This was against https://grpc.testnet.penumbra.zone; it's possible the custom load balancer setup there interferes with HTTP headers, we've had that issue in the past, but this seems more likely to be a problem in pd itself.


🔗 related work

@github-actions github-actions bot added the needs-refinement unclear, incomplete, or stub issue that needs work label May 15, 2024
@hdevalence
Copy link
Member Author

Link to gist with pd logs: https://gist.github.com/hdevalence/3cc8c9cef56463dc08cf4e303f316ba4

$ grpcurl -plaintext -vv localhost:8080 list
Failed to list services: rpc error: code = Unknown desc = unexpected HTTP status code received from server: 405 (Method Not Allowed); malformed header: missing HTTP content-type

@conorsch
Copy link
Contributor

They also reported that grpcurl didn't work

Using grpcurl with a known-good query works fine:

❯ grpcurl grpc.testnet.penumbra.zone:443 penumbra.core.app.v1.QueryService.AppParameters  | jq .appParameters.chainId
"penumbra-testnet-deimos-8"

potentially because of problems with reflection.

Reflection is also supported, shown here via grpcurl:

❯ grpcurl grpc.testnet.penumbra.zone:443 list
grpc.reflection.v1alpha.ServerReflection
penumbra.cnidarium.v1.QueryService
penumbra.core.app.v1.QueryService
penumbra.core.component.auction.v1.QueryService
penumbra.core.component.community_pool.v1.QueryService
penumbra.core.component.compact_block.v1.QueryService
penumbra.core.component.dex.v1.QueryService
penumbra.core.component.dex.v1.SimulationService
penumbra.core.component.fee.v1.QueryService
penumbra.core.component.governance.v1.QueryService
penumbra.core.component.sct.v1.QueryService
penumbra.core.component.shielded_pool.v1.QueryService
penumbra.core.component.stake.v1.QueryService
penumbra.custody.v1.CustodyService
penumbra.tools.summoning.v1.CeremonyCoordinatorService
penumbra.util.tendermint_proxy.v1.TendermintProxyService
penumbra.view.v1.ViewService

Skip reported unexpected HTTP response codes for unimplemented GRPC methods:

That makes sense, as a side-effect of our merging multiple routers in the pd endpoint, so that we can provide a node status page in addition to the gRPC services. I'm not sure what the best compromise is for this situation.

@conorsch
Copy link
Contributor

Ah, looks like I had an outdated grpcurl: I was using 1.8.7, and the results above were posted from that version. After upgrading my local version to 1.9.1, I can reproduce problems:

❯ grpcurl --version
grpcurl v1.9.1

❯ grpcurl -vv grpc.testnet.penumbra.zone:443 list
Failed to list services: rpc error: code = Unknown desc = unexpected HTTP status code received from server: 405 (Method Not Allowed); malformed header: missing HTTP content-type

@cratelyn cratelyn added this to the Sprint 6 milestone May 15, 2024
@conorsch
Copy link
Contributor

Looks like newer versions of grpcurl, the server reflection API moved from v1alpha to v1, as shown here: https://github.com/fullstorydev/grpcurl/pull/407/files We get gRPC server reflection support via the tonic-reflection crate, which is still using the v1alpha namespace: hyperium/tonic#1685 Can we do anything about that without an upstream patch and version bump? Let's find out.

@cratelyn cratelyn added A-node Area: System design and implementation for node software C-bug Category: a bug labels May 15, 2024
@aubrika aubrika added _P-V1 Priority: slated for V1 release _P-high High priority labels May 15, 2024
@hdevalence
Copy link
Member Author

Let's do an upstream patch and version bump, that seems like the best solution

@cratelyn
Copy link
Contributor

cratelyn commented May 15, 2024

cratelyn added a commit to cratelyn/tonic that referenced this issue May 15, 2024
this fixes hyperium#1685.

 ### 🩹 changes

* vendors the `v1` definition of [`reflection.proto`][proto].

* renames the (deprecated) `v1alpha` definition to
  `reflection_v1alpha.proto`.

* `tonic_reflection::generated::grpc_reflection_v1` links to the
  generated Rust code (created by running `cargo run --package codegen`).

* `tonic_reflection::generated::FILE_DESCRIPTOR_SET` is replaced by
  `tonic_reflection::generated::{FILE_DESCRIPTOR_SET_V1ALPHA, FILE_DESCRIPTOR_SET_V1}`.

* `tonic_reflection::pb` now contains namespaced
  `tonic_reflection::pb::{v1alpha, v1}` submodules. (**NB: this is a
  breaking change to the public `tonic-reflection` API.**)

* `tonic_reflection::server` is updated to use the generated
  `tonic_reflection::pb::v1` code.

[proto]: https://github.com/grpc/grpc/blob/master/src/proto/grpc/reflection/v1/reflection.proto

fixes: hyperium#1685
x-ref: penumbra-zone/penumbra#4392
cratelyn added a commit to cratelyn/tonic that referenced this issue May 15, 2024
this fixes hyperium#1685.

 ### 🩹 changes

* vendors the `v1` definition of [`reflection.proto`][proto].

* renames the (deprecated) `v1alpha` definition to
  `reflection_v1alpha.proto`.

* `tonic_reflection::generated::grpc_reflection_v1` links to the
  generated Rust code (created by running `cargo run --package codegen`).

* `tonic_reflection::generated::FILE_DESCRIPTOR_SET` is replaced by
  `tonic_reflection::generated::{FILE_DESCRIPTOR_SET_V1ALPHA, FILE_DESCRIPTOR_SET_V1}`.

* `tonic_reflection::pb` now contains namespaced
  `tonic_reflection::pb::{v1alpha, v1}` submodules. (**NB: this is a
  breaking change to the public `tonic-reflection` API.**)

* `tonic_reflection::server` is updated to use the generated
  `tonic_reflection::pb::v1` code.

[proto]: https://github.com/grpc/grpc/blob/master/src/proto/grpc/reflection/v1/reflection.proto

fixes: hyperium#1685
x-ref: penumbra-zone/penumbra#4392
cratelyn added a commit to cratelyn/tonic that referenced this issue May 16, 2024
this fixes hyperium#1685.

in penumbra-zone/penumbra#4392, we observed that tonic servers do not
properly support reflection when servicing a request sent by recent
versions of [`grpcurl`], after [v1.8.8] began using
`grpc.reflection.v1.ServerReflection`. (see fullstorydev/grpcurl#407)

these lead to an error regarding an unexpected status code, like this:

```
❯ grpcurl --version
grpcurl v1.9.1

❯ grpcurl -vv grpc.testnet.penumbra.zone:443 list
Failed to list services: rpc error: code = Unknown desc = unexpected HTTP status code received from server: 405 (Method Not Allowed); malformed header: missing HTTP content-type
```

this adds the v1 reflection definition to `tonic-reflection`, which was
observed as fixing these issues for our gRPC endpoint.

 ### 🩹 changes

changes in this commet are as follows:

* vendors the `v1` definition of [`reflection.proto`][proto].

* renames the (deprecated) `v1alpha` definition to
  `reflection_v1alpha.proto`.

* `tonic_reflection::generated::grpc_reflection_v1` links to the
  generated Rust code (created by running `cargo run --package codegen`).

* `tonic_reflection::generated::FILE_DESCRIPTOR_SET` is replaced by
  `tonic_reflection::generated::{FILE_DESCRIPTOR_SET_V1ALPHA, FILE_DESCRIPTOR_SET_V1}`.

* `tonic_reflection::pb` now contains namespaced
  `tonic_reflection::pb::{v1alpha, v1}` submodules. (**NB: this is a
  breaking change to the public `tonic-reflection` API.**)

* `tonic_reflection::server` is updated to use the generated
  `tonic_reflection::pb::v1` code.

[v1.8.8]: https://github.com/fullstorydev/grpcurl/releases/tag/v1.8.8
[proto]: https://github.com/grpc/grpc/blob/master/src/proto/grpc/reflection/v1/reflection.proto
[grpcurl]: https://github.com/fullstorydev/grpcurl

---

fixes: hyperium#1685
x-ref: penumbra-zone/penumbra#4392
co-authored-by: Conor Schaefer <[email protected]>
cratelyn added a commit to cratelyn/tonic that referenced this issue May 16, 2024
this fixes hyperium#1685.

in penumbra-zone/penumbra#4392, we observed that tonic servers do not
properly support reflection when servicing a request sent by recent
versions of [`grpcurl`], after [v1.8.8] began using
`grpc.reflection.v1.ServerReflection`. (see fullstorydev/grpcurl#407)

these lead to an error regarding an unexpected status code, like this:

```
❯ grpcurl --version
grpcurl v1.9.1

❯ grpcurl -vv grpc.testnet.penumbra.zone:443 list
Failed to list services: rpc error: code = Unknown desc = unexpected HTTP status code received from server: 405 (Method Not Allowed); malformed header: missing HTTP content-type
```

this adds the v1 reflection definition to `tonic-reflection`, which was
observed as fixing these issues for our gRPC endpoint.

 ### 🩹 changes

changes in this commet are as follows:

* vendors the `v1` definition of [`reflection.proto`][proto].

* renames the (deprecated) `v1alpha` definition to
  `reflection_v1alpha.proto`.

* `tonic_reflection::generated::grpc_reflection_v1` links to the
  generated Rust code (created by running `cargo run --package codegen`).

* `tonic_reflection::generated::FILE_DESCRIPTOR_SET` is replaced by
  `tonic_reflection::generated::{FILE_DESCRIPTOR_SET_V1ALPHA, FILE_DESCRIPTOR_SET_V1}`.

* `tonic_reflection::pb` now contains namespaced
  `tonic_reflection::pb::{v1alpha, v1}` submodules. (**NB: this is a
  breaking change to the public `tonic-reflection` API.**)

* `tonic_reflection::server` is updated to use the generated
  `tonic_reflection::pb::v1` code.

[v1.8.8]: https://github.com/fullstorydev/grpcurl/releases/tag/v1.8.8
[proto]: https://github.com/grpc/grpc/blob/master/src/proto/grpc/reflection/v1/reflection.proto
[grpcurl]: https://github.com/fullstorydev/grpcurl

---

fixes: hyperium#1685
x-ref: penumbra-zone/penumbra#4392
co-authored-by: Conor Schaefer <[email protected]>
@cratelyn
Copy link
Contributor

cratelyn commented May 16, 2024

i've opened hyperium/tonic/pull/1701. @conorsch and i confirmed fixes this issue by running pd locally and sending a list request from a new version of grpcurl.

once that lands, we will need to either upgrade our tonic dependency to a new release that includes that patch (NB: this will involve upgrading from 0.10 to 0.11), or we will need to backport that to the 0.10 release (that would involve a temporary fork of tonic-*). the former option is ideal, but will involve a bit of finagling to get ibc-types, ibc-proto, and our tonic dependencies all in agreement with one another.

in any case, i have a version of this patch based on the 0.11 and 0.10 releases here and here, respectively.

cratelyn added a commit to cratelyn/tonic that referenced this issue May 20, 2024
this fixes hyperium#1685.

in penumbra-zone/penumbra#4392, we observed that tonic servers do not
properly support reflection when servicing a request sent by recent
versions of [`grpcurl`], after [v1.8.8] began using
`grpc.reflection.v1.ServerReflection`. (see fullstorydev/grpcurl#407)

these lead to an error regarding an unexpected status code, like this:

```
❯ grpcurl --version
grpcurl v1.9.1

❯ grpcurl -vv grpc.testnet.penumbra.zone:443 list
Failed to list services: rpc error: code = Unknown desc = unexpected HTTP status code received from server: 405 (Method Not Allowed); malformed header: missing HTTP content-type
```

this adds the v1 reflection definition to `tonic-reflection`, which was
observed as fixing these issues for our gRPC endpoint.

 ### 🩹 changes

changes in this commet are as follows:

* vendors the `v1` definition of [`reflection.proto`][proto].

* renames the (deprecated) `v1alpha` definition to
  `reflection_v1alpha.proto`.

* `tonic_reflection::generated::grpc_reflection_v1` links to the
  generated Rust code (created by running `cargo run --package codegen`).

* `tonic_reflection::generated::FILE_DESCRIPTOR_SET` is replaced by
  `tonic_reflection::generated::{FILE_DESCRIPTOR_SET_V1ALPHA, FILE_DESCRIPTOR_SET_V1}`.

* `tonic_reflection::pb` now contains namespaced
  `tonic_reflection::pb::{v1alpha, v1}` submodules. (**NB: this is a
  breaking change to the public `tonic-reflection` API.**)

* `tonic_reflection::server` is updated to use the generated
  `tonic_reflection::pb::v1` code.

[v1.8.8]: https://github.com/fullstorydev/grpcurl/releases/tag/v1.8.8
[proto]: https://github.com/grpc/grpc/blob/master/src/proto/grpc/reflection/v1/reflection.proto
[grpcurl]: https://github.com/fullstorydev/grpcurl

---

fixes: hyperium#1685
x-ref: penumbra-zone/penumbra#4392
co-authored-by: Conor Schaefer <[email protected]>
cratelyn added a commit to cratelyn/tonic that referenced this issue May 20, 2024
this fixes hyperium#1685.

in penumbra-zone/penumbra#4392, we observed that tonic servers do not
properly support reflection when servicing a request sent by recent
versions of [`grpcurl`], after [v1.8.8] began using
`grpc.reflection.v1.ServerReflection`. (see fullstorydev/grpcurl#407)

these lead to an error regarding an unexpected status code, like this:

```
❯ grpcurl --version
grpcurl v1.9.1

❯ grpcurl -vv grpc.testnet.penumbra.zone:443 list
Failed to list services: rpc error: code = Unknown desc = unexpected HTTP status code received from server: 405 (Method Not Allowed); malformed header: missing HTTP content-type
```

this adds the v1 reflection definition to `tonic-reflection`, which was
observed as fixing these issues for our gRPC endpoint.

 ### 🩹 changes

changes in this commet are as follows:

* vendors the `v1` definition of [`reflection.proto`][proto].

* renames the (deprecated) `v1alpha` definition to
  `reflection_v1alpha.proto`.

* `tonic_reflection::generated::grpc_reflection_v1` links to the
  generated Rust code (created by running `cargo run --package codegen`).

* `tonic_reflection::generated::FILE_DESCRIPTOR_SET` is replaced by
  `tonic_reflection::generated::{FILE_DESCRIPTOR_SET_V1ALPHA, FILE_DESCRIPTOR_SET_V1}`.

* `tonic_reflection::pb` now contains namespaced
  `tonic_reflection::pb::{v1alpha, v1}` submodules. (**NB: this is a
  breaking change to the public `tonic-reflection` API.**)

* `tonic_reflection::server` is updated to use the generated
  `tonic_reflection::pb::v1` code.

[v1.8.8]: https://github.com/fullstorydev/grpcurl/releases/tag/v1.8.8
[proto]: https://github.com/grpc/grpc/blob/master/src/proto/grpc/reflection/v1/reflection.proto
[grpcurl]: https://github.com/fullstorydev/grpcurl

---

fixes: hyperium#1685
x-ref: penumbra-zone/penumbra#4392
co-authored-by: Conor Schaefer <[email protected]>
cratelyn added a commit to cratelyn/tonic that referenced this issue May 20, 2024
this fixes hyperium#1685.

in penumbra-zone/penumbra#4392, we observed that tonic servers do not
properly support reflection when servicing a request sent by recent
versions of [`grpcurl`], after [v1.8.8] began using
`grpc.reflection.v1.ServerReflection`. (see fullstorydev/grpcurl#407)

these lead to an error regarding an unexpected status code, like this:

```
❯ grpcurl --version
grpcurl v1.9.1

❯ grpcurl -vv grpc.testnet.penumbra.zone:443 list
Failed to list services: rpc error: code = Unknown desc = unexpected HTTP status code received from server: 405 (Method Not Allowed); malformed header: missing HTTP content-type
```

this adds the v1 reflection definition to `tonic-reflection`, which was
observed as fixing these issues for our gRPC endpoint.

 ### 🩹 changes

changes in this commet are as follows:

* vendors the `v1` definition of [`reflection.proto`][proto].

* renames the (deprecated) `v1alpha` definition to
  `reflection_v1alpha.proto`.

* `tonic_reflection::generated::grpc_reflection_v1` links to the
  generated Rust code (created by running `cargo run --package codegen`).

* `tonic_reflection::generated::FILE_DESCRIPTOR_SET` is replaced by
  `tonic_reflection::generated::{FILE_DESCRIPTOR_SET_V1ALPHA, FILE_DESCRIPTOR_SET_V1}`.

* `tonic_reflection::pb` now contains namespaced
  `tonic_reflection::pb::{v1alpha, v1}` submodules. (**NB: this is a
  breaking change to the public `tonic-reflection` API.**)

* `tonic_reflection::server` is updated to use the generated
  `tonic_reflection::pb::v1` code.

* `HttpsUriWithoutTlsSupport` is now gated behind the `transport`
  feature flag, because it is not used otherwise.

[v1.8.8]: https://github.com/fullstorydev/grpcurl/releases/tag/v1.8.8
[proto]: https://github.com/grpc/grpc/blob/master/src/proto/grpc/reflection/v1/reflection.proto
[grpcurl]: https://github.com/fullstorydev/grpcurl

---

fixes: hyperium#1685
x-ref: penumbra-zone/penumbra#4392
co-authored-by: Conor Schaefer <[email protected]>
cratelyn added a commit to cratelyn/tonic that referenced this issue May 20, 2024
this fixes hyperium#1685.

in penumbra-zone/penumbra#4392, we observed that tonic servers do not
properly support reflection when servicing a request sent by recent
versions of [`grpcurl`], after [v1.8.8] began using
`grpc.reflection.v1.ServerReflection`. (see fullstorydev/grpcurl#407)

these lead to an error regarding an unexpected status code, like this:

```
❯ grpcurl --version
grpcurl v1.9.1

❯ grpcurl -vv grpc.testnet.penumbra.zone:443 list
Failed to list services: rpc error: code = Unknown desc = unexpected HTTP status code received from server: 405 (Method Not Allowed); malformed header: missing HTTP content-type
```

this adds the v1 reflection definition to `tonic-reflection`, which was
observed as fixing these issues for our gRPC endpoint.

 ### 🩹 changes

changes in this commet are as follows:

* vendors the `v1` definition of [`reflection.proto`][proto].

* renames the (deprecated) `v1alpha` definition to
  `reflection_v1alpha.proto`.

* `tonic_reflection::generated::grpc_reflection_v1` links to the
  generated Rust code (created by running `cargo run --package codegen`).

* `tonic_reflection::generated::FILE_DESCRIPTOR_SET` is replaced by
  `tonic_reflection::generated::{FILE_DESCRIPTOR_SET_V1ALPHA, FILE_DESCRIPTOR_SET_V1}`.

* `tonic_reflection::pb` now contains namespaced
  `tonic_reflection::pb::{v1alpha, v1}` submodules. (**NB: this is a
  breaking change to the public `tonic-reflection` API.**)

* `tonic_reflection::server` is updated to use the generated
  `tonic_reflection::pb::v1` code.

* `HttpsUriWithoutTlsSupport` is now gated behind the `tls`
  feature flag, because it is not used otherwise.

[v1.8.8]: https://github.com/fullstorydev/grpcurl/releases/tag/v1.8.8
[proto]: https://github.com/grpc/grpc/blob/master/src/proto/grpc/reflection/v1/reflection.proto
[grpcurl]: https://github.com/fullstorydev/grpcurl

---

fixes: hyperium#1685
x-ref: penumbra-zone/penumbra#4392
co-authored-by: Conor Schaefer <[email protected]>
cratelyn added a commit to cratelyn/tonic that referenced this issue May 20, 2024
this fixes hyperium#1685.

in penumbra-zone/penumbra#4392, we observed that tonic servers do not
properly support reflection when servicing a request sent by recent
versions of [`grpcurl`], after [v1.8.8] began using
`grpc.reflection.v1.ServerReflection`. (see fullstorydev/grpcurl#407)

these lead to an error regarding an unexpected status code, like this:

```
❯ grpcurl --version
grpcurl v1.9.1

❯ grpcurl -vv grpc.testnet.penumbra.zone:443 list
Failed to list services: rpc error: code = Unknown desc = unexpected HTTP status code received from server: 405 (Method Not Allowed); malformed header: missing HTTP content-type
```

this adds the v1 reflection definition to `tonic-reflection`, which was
observed as fixing these issues for our gRPC endpoint.

 ### 🩹 changes

changes in this commet are as follows:

* vendors the `v1` definition of [`reflection.proto`][proto].

* renames the (deprecated) `v1alpha` definition to
  `reflection_v1alpha.proto`.

* `tonic_reflection::generated::grpc_reflection_v1` links to the
  generated Rust code (created by running `cargo run --package codegen`).

* `tonic_reflection::generated::FILE_DESCRIPTOR_SET` is replaced by
  `tonic_reflection::generated::{FILE_DESCRIPTOR_SET_V1ALPHA, FILE_DESCRIPTOR_SET_V1}`.

* `tonic_reflection::pb` now contains namespaced
  `tonic_reflection::pb::{v1alpha, v1}` submodules. (**NB: this is a
  breaking change to the public `tonic-reflection` API.**)

* `tonic_reflection::server` is updated to use the generated
  `tonic_reflection::pb::v1` code.

* `HttpsUriWithoutTlsSupport` is now gated behind the `tls`
  feature flag, because it is not used otherwise.

[v1.8.8]: https://github.com/fullstorydev/grpcurl/releases/tag/v1.8.8
[proto]: https://github.com/grpc/grpc/blob/master/src/proto/grpc/reflection/v1/reflection.proto
[grpcurl]: https://github.com/fullstorydev/grpcurl

---

fixes: hyperium#1685
x-ref: penumbra-zone/penumbra#4392
co-authored-by: Conor Schaefer <[email protected]>
cratelyn added a commit to cratelyn/tonic that referenced this issue May 20, 2024
this fixes hyperium#1685.

in penumbra-zone/penumbra#4392, we observed that tonic servers do not
properly support reflection when servicing a request sent by recent
versions of [`grpcurl`], after [v1.8.8] began using
`grpc.reflection.v1.ServerReflection`. (see fullstorydev/grpcurl#407)

these lead to an error regarding an unexpected status code, like this:

```
❯ grpcurl --version
grpcurl v1.9.1

❯ grpcurl -vv grpc.testnet.penumbra.zone:443 list
Failed to list services: rpc error: code = Unknown desc = unexpected HTTP status code received from server: 405 (Method Not Allowed); malformed header: missing HTTP content-type
```

this adds the v1 reflection definition to `tonic-reflection`, which was
observed as fixing these issues for our gRPC endpoint.

 ### 🩹 changes

changes in this commet are as follows:

* vendors the `v1` definition of [`reflection.proto`][proto].

* renames the (deprecated) `v1alpha` definition to
  `reflection_v1alpha.proto`.

* `tonic_reflection::generated::grpc_reflection_v1` links to the
  generated Rust code (created by running `cargo run --package codegen`).

* `tonic_reflection::generated::FILE_DESCRIPTOR_SET` is replaced by
  `tonic_reflection::generated::{FILE_DESCRIPTOR_SET_V1ALPHA, FILE_DESCRIPTOR_SET_V1}`.

* `tonic_reflection::pb` now contains namespaced
  `tonic_reflection::pb::{v1alpha, v1}` submodules. (**NB: this is a
  breaking change to the public `tonic-reflection` API.**)

* `tonic_reflection::server` is updated to use the generated
  `tonic_reflection::pb::v1` code.

* `HttpsUriWithoutTlsSupport` is now gated behind the `tls`
  feature flag, because it is not used otherwise.

[v1.8.8]: https://github.com/fullstorydev/grpcurl/releases/tag/v1.8.8
[proto]: https://github.com/grpc/grpc/blob/master/src/proto/grpc/reflection/v1/reflection.proto
[grpcurl]: https://github.com/fullstorydev/grpcurl

---

fixes: hyperium#1685
x-ref: penumbra-zone/penumbra#4392
co-authored-by: Conor Schaefer <[email protected]>
@aubrika aubrika modified the milestones: Sprint 6, Sprint 7 May 20, 2024
cratelyn added a commit to penumbra-zone/tonic that referenced this issue May 20, 2024
this fixes hyperium#1685.

in penumbra-zone/penumbra#4392, we observed that tonic servers do not
properly support reflection when servicing a request sent by recent
versions of [`grpcurl`], after [v1.8.8] began using
`grpc.reflection.v1.ServerReflection`. (see fullstorydev/grpcurl#407)

these lead to an error regarding an unexpected status code, like this:

```
❯ grpcurl --version
grpcurl v1.9.1

❯ grpcurl -vv grpc.testnet.penumbra.zone:443 list
Failed to list services: rpc error: code = Unknown desc = unexpected HTTP status code received from server: 405 (Method Not Allowed); malformed header: missing HTTP content-type
```

this adds the v1 reflection definition to `tonic-reflection`, which was
observed as fixing these issues for our gRPC endpoint.

 ### 🩹 changes

changes in this commet are as follows:

* vendors the `v1` definition of [`reflection.proto`][proto].

* renames the (deprecated) `v1alpha` definition to
  `reflection_v1alpha.proto`.

* `tonic_reflection::generated::grpc_reflection_v1` links to the
  generated Rust code (created by running `cargo run --package codegen`).

* `tonic_reflection::generated::FILE_DESCRIPTOR_SET` is replaced by
  `tonic_reflection::generated::{FILE_DESCRIPTOR_SET_V1ALPHA, FILE_DESCRIPTOR_SET_V1}`.

* `tonic_reflection::pb` now contains namespaced
  `tonic_reflection::pb::{v1alpha, v1}` submodules. (**NB: this is a
  breaking change to the public `tonic-reflection` API.**)

* `tonic_reflection::server` is updated to use the generated
  `tonic_reflection::pb::v1` code.

* `HttpsUriWithoutTlsSupport` is now gated behind the `tls`
  feature flag, because it is not used otherwise.

[v1.8.8]: https://github.com/fullstorydev/grpcurl/releases/tag/v1.8.8
[proto]: https://github.com/grpc/grpc/blob/master/src/proto/grpc/reflection/v1/reflection.proto
[grpcurl]: https://github.com/fullstorydev/grpcurl

---

fixes: hyperium#1685
x-ref: penumbra-zone/penumbra#4392
co-authored-by: Conor Schaefer <[email protected]>
cratelyn added a commit to penumbra-zone/tonic that referenced this issue May 20, 2024
this fixes hyperium#1685.

in penumbra-zone/penumbra#4392, we observed that tonic servers do not
properly support reflection when servicing a request sent by recent
versions of [`grpcurl`], after [v1.8.8] began using
`grpc.reflection.v1.ServerReflection`. (see fullstorydev/grpcurl#407)

these lead to an error regarding an unexpected status code, like this:

```
❯ grpcurl --version
grpcurl v1.9.1

❯ grpcurl -vv grpc.testnet.penumbra.zone:443 list
Failed to list services: rpc error: code = Unknown desc = unexpected HTTP status code received from server: 405 (Method Not Allowed); malformed header: missing HTTP content-type
```

this adds the v1 reflection definition to `tonic-reflection`, which was
observed as fixing these issues for our gRPC endpoint.

 ### 🩹 changes

changes in this commet are as follows:

* vendors the `v1` definition of [`reflection.proto`][proto].

* renames the (deprecated) `v1alpha` definition to
  `reflection_v1alpha.proto`.

* `tonic_reflection::generated::grpc_reflection_v1` links to the
  generated Rust code (created by running `cargo run --package codegen`).

* `tonic_reflection::generated::FILE_DESCRIPTOR_SET` is replaced by
  `tonic_reflection::generated::{FILE_DESCRIPTOR_SET_V1ALPHA, FILE_DESCRIPTOR_SET_V1}`.

* `tonic_reflection::pb` now contains namespaced
  `tonic_reflection::pb::{v1alpha, v1}` submodules. (**NB: this is a
  breaking change to the public `tonic-reflection` API.**)

* `tonic_reflection::server` is updated to use the generated
  `tonic_reflection::pb::v1` code.

* `HttpsUriWithoutTlsSupport` is now gated behind the `tls`
  feature flag, because it is not used otherwise.

[v1.8.8]: https://github.com/fullstorydev/grpcurl/releases/tag/v1.8.8
[proto]: https://github.com/grpc/grpc/blob/master/src/proto/grpc/reflection/v1/reflection.proto
[grpcurl]: https://github.com/fullstorydev/grpcurl

---

fixes: hyperium#1685
x-ref: penumbra-zone/penumbra#4392
co-authored-by: Conor Schaefer <[email protected]>
cratelyn added a commit that referenced this issue May 20, 2024
fixes #4392.

in #4392, we found an issue with gRPC reflection when recent versions of
`grpcurl` were used to list supported endpoints.

this was tracked down and fixed in #hyperium/tonic#1701, in
collaboration with @conorsch. that pr targets the more recent 0.11 tonic
release however, which we are not yet using.

eventually we should upgrade to tonic 0.11 (see #4400). as a short-term
measure, but we want to unblock engineers from Skip working on an
integration with Penumbra. this commit patches the `tonic` dependencies
used to point to a temporary fork of the `tonic` repo, where i have
backported that patch (and some ci-related fixes) to the 0.10 release.

see also:
* hyperium/tonic#1701
* penumbra-zone/tonic#1
* penumbra-zone/tonic#2
* #4392
* #4400

---

checking that all transitive dependencies point to the patched version:

```
; cargo tree | grep tonic
│   └── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7)
├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   ├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   │   │   │   ├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   │   │   │   ├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   │   │   │   │   ├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   │   │   │   ├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   │   │   ├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   │   ├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   │   │   │   ├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   │   │   ├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   │   ├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   │   ├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   │   ├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   ├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   ├── tonic-reflection v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7)
│   │   └── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   ├── tonic-web v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7)
│   │   ├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   ├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   ├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   ├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
├── tonic-reflection v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
├── tonic-web v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
├── tonic-reflection v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
├── tonic-web v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
```
conorsch pushed a commit that referenced this issue May 21, 2024
fixes #4392.

in #4392, we found an issue with gRPC reflection when recent versions of
`grpcurl` were used to list supported endpoints.

this was tracked down and fixed in #hyperium/tonic#1701, in
collaboration with @conorsch. that pr targets the more recent 0.11 tonic
release however, which we are not yet using.

eventually we should upgrade to tonic 0.11 (see #4400). as a short-term
measure, but we want to unblock engineers from Skip working on an
integration with Penumbra. this commit patches the `tonic` dependencies
used to point to a temporary fork of the `tonic` repo, where i have
backported that patch (and some ci-related fixes) to the 0.10 release.

see also:
* hyperium/tonic#1701
* penumbra-zone/tonic#1
* penumbra-zone/tonic#2
* #4392
* #4400

---

checking that all transitive dependencies point to the patched version:

```
; cargo tree | grep tonic
│   └── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7)
├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   ├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   │   │   │   ├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   │   │   │   ├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   │   │   │   │   ├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   │   │   │   ├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   │   │   ├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   │   ├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   │   │   │   ├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   │   │   ├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   │   ├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   │   ├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   │   ├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   ├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   ├── tonic-reflection v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7)
│   │   └── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   ├── tonic-web v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7)
│   │   ├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   ├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   ├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
│   ├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
├── tonic-reflection v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
├── tonic-web v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
├── tonic-reflection v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
├── tonic-web v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
├── tonic v0.10.2 (https://github.com/penumbra-zone/tonic.git?tag=v0.10.3-penumbra#db355dd7) (*)
```
conorsch added a commit that referenced this issue May 21, 2024
Refs #4392. We want to ensure that server reflection remains
working, despite changes to the tonic dependencies (#4400)
and proto compiling logic #4422. While the most effective test
is exercising all these protos regularly, we currently lack
solid coverage, so this superficial integration test is a sanity-check
to save time versus building locally and inspecting the output manually.
cratelyn added a commit to cratelyn/tonic that referenced this issue May 21, 2024
this fixes hyperium#1685.

in penumbra-zone/penumbra#4392, we observed that tonic servers do not
properly support reflection when servicing a request sent by recent
versions of [`grpcurl`], after [v1.8.8] began using
`grpc.reflection.v1.ServerReflection`. (see fullstorydev/grpcurl#407)

these lead to an error regarding an unexpected status code, like this:

```
❯ grpcurl --version
grpcurl v1.9.1

❯ grpcurl -vv grpc.testnet.penumbra.zone:443 list
Failed to list services: rpc error: code = Unknown desc = unexpected HTTP status code received from server: 405 (Method Not Allowed); malformed header: missing HTTP content-type
```

this adds the v1 reflection definition to `tonic-reflection`, which was
observed as fixing these issues for our gRPC endpoint.

 ### 🩹 changes

changes in this commet are as follows:

* vendors the `v1` definition of [`reflection.proto`][proto].

* renames the (deprecated) `v1alpha` definition to
  `reflection_v1alpha.proto`.

* `tonic_reflection::generated::grpc_reflection_v1` links to the
  generated Rust code (created by running `cargo run --package codegen`).

* `tonic_reflection::generated::FILE_DESCRIPTOR_SET` is replaced by
  `tonic_reflection::generated::{FILE_DESCRIPTOR_SET_V1ALPHA, FILE_DESCRIPTOR_SET_V1}`.

* `tonic_reflection::pb` now contains namespaced
  `tonic_reflection::pb::{v1alpha, v1}` submodules. (**NB: this is a
  breaking change to the public `tonic-reflection` API.**)

* `tonic_reflection::server` is updated to use the generated
  `tonic_reflection::pb::v1` code.

[v1.8.8]: https://github.com/fullstorydev/grpcurl/releases/tag/v1.8.8
[proto]: https://github.com/grpc/grpc/blob/master/src/proto/grpc/reflection/v1/reflection.proto
[grpcurl]: https://github.com/fullstorydev/grpcurl

---

fixes: hyperium#1685
x-ref: penumbra-zone/penumbra#4392
co-authored-by: Conor Schaefer <[email protected]>
conorsch added a commit that referenced this issue May 23, 2024
Refs #4392. We want to ensure that server reflection remains
working, despite changes to the tonic dependencies (#4400)
and proto compiling logic #4422. While the most effective test
is exercising all these protos regularly, we currently lack
solid coverage, so this superficial integration test is a sanity-check
to save time versus building locally and inspecting the output manually.
conorsch added a commit that referenced this issue May 23, 2024
Refs #4392. We want to ensure that server reflection remains
working, despite changes to the tonic dependencies (#4400)
and proto compiling logic #4422. While the most effective test
is exercising all these protos regularly, we currently lack
solid coverage, so this superficial integration test is a sanity-check
to save time versus building locally and inspecting the output manually.
cratelyn added a commit to cratelyn/tonic that referenced this issue May 23, 2024
this fixes hyperium#1685.

in penumbra-zone/penumbra#4392, we observed that tonic servers do not
properly support reflection when servicing a request sent by recent
versions of [`grpcurl`], after [v1.8.8] began using
`grpc.reflection.v1.ServerReflection`. (see fullstorydev/grpcurl#407)

these lead to an error regarding an unexpected status code, like this:

```
❯ grpcurl --version
grpcurl v1.9.1

❯ grpcurl -vv grpc.testnet.penumbra.zone:443 list
Failed to list services: rpc error: code = Unknown desc = unexpected HTTP status code received from server: 405 (Method Not Allowed); malformed header: missing HTTP content-type
```

this adds the v1 reflection definition to `tonic-reflection`, which was
observed as fixing these issues for our gRPC endpoint.

 ### 🩹 changes

changes in this commet are as follows:

* vendors the `v1` definition of [`reflection.proto`][proto].

* renames the (deprecated) `v1alpha` definition to
  `reflection_v1alpha.proto`.

* `tonic_reflection::generated::grpc_reflection_v1` links to the
  generated Rust code (created by running `cargo run --package codegen`).

* `tonic_reflection::generated::FILE_DESCRIPTOR_SET` is replaced by
  `tonic_reflection::generated::{FILE_DESCRIPTOR_SET_V1ALPHA, FILE_DESCRIPTOR_SET_V1}`.

* `tonic_reflection::pb` now contains namespaced
  `tonic_reflection::pb::{v1alpha, v1}` submodules. (**NB: this is a
  breaking change to the public `tonic-reflection` API.**)

* `tonic_reflection::server` is updated to use the generated
  `tonic_reflection::pb::v1` code.

[v1.8.8]: https://github.com/fullstorydev/grpcurl/releases/tag/v1.8.8
[proto]: https://github.com/grpc/grpc/blob/master/src/proto/grpc/reflection/v1/reflection.proto
[grpcurl]: https://github.com/fullstorydev/grpcurl

---

fixes: hyperium#1685
x-ref: penumbra-zone/penumbra#4392
co-authored-by: Conor Schaefer <[email protected]>
conorsch added a commit that referenced this issue May 23, 2024
Refs #4392. We want to ensure that server reflection remains
working, despite changes to the tonic dependencies (#4400)
and proto compiling logic #4422. While the most effective test
is exercising all these protos regularly, we currently lack
solid coverage, so this superficial integration test is a sanity-check
to save time versus building locally and inspecting the output manually.
conorsch added a commit that referenced this issue May 23, 2024
Refs #4392. We want to ensure that server reflection remains
working, despite changes to the tonic dependencies (#4400)
and proto compiling logic #4422. While the most effective test
is exercising all these protos regularly, we currently lack
solid coverage, so this superficial integration test is a sanity-check
to save time versus building locally and inspecting the output manually.
conorsch added a commit that referenced this issue May 23, 2024
Refs #4392. We want to ensure that server reflection remains
working, despite changes to the tonic dependencies (#4400)
and proto compiling logic #4422. While the most effective test
is exercising all these protos regularly, we currently lack
solid coverage, so this superficial integration test is a sanity-check
to save time versus building locally and inspecting the output manually.
github-merge-queue bot pushed a commit to hyperium/tonic that referenced this issue May 29, 2024
this fixes #1685.

in penumbra-zone/penumbra#4392, we observed that tonic servers do not
properly support reflection when servicing a request sent by recent
versions of [`grpcurl`], after [v1.8.8] began using
`grpc.reflection.v1.ServerReflection`. (see fullstorydev/grpcurl#407)

these lead to an error regarding an unexpected status code, like this:

```
❯ grpcurl --version
grpcurl v1.9.1

❯ grpcurl -vv grpc.testnet.penumbra.zone:443 list
Failed to list services: rpc error: code = Unknown desc = unexpected HTTP status code received from server: 405 (Method Not Allowed); malformed header: missing HTTP content-type
```

this adds the v1 reflection definition to `tonic-reflection`, which was
observed as fixing these issues for our gRPC endpoint.

 ### 🩹 changes

changes in this commet are as follows:

* vendors the `v1` definition of [`reflection.proto`][proto].

* renames the (deprecated) `v1alpha` definition to
  `reflection_v1alpha.proto`.

* `tonic_reflection::generated::grpc_reflection_v1` links to the
  generated Rust code (created by running `cargo run --package codegen`).

* `tonic_reflection::generated::FILE_DESCRIPTOR_SET` is replaced by
  `tonic_reflection::generated::{FILE_DESCRIPTOR_SET_V1ALPHA, FILE_DESCRIPTOR_SET_V1}`.

* `tonic_reflection::pb` now contains namespaced
  `tonic_reflection::pb::{v1alpha, v1}` submodules. (**NB: this is a
  breaking change to the public `tonic-reflection` API.**)

* `tonic_reflection::server` is updated to use the generated
  `tonic_reflection::pb::v1` code.

[v1.8.8]: https://github.com/fullstorydev/grpcurl/releases/tag/v1.8.8
[proto]: https://github.com/grpc/grpc/blob/master/src/proto/grpc/reflection/v1/reflection.proto
[grpcurl]: https://github.com/fullstorydev/grpcurl

---

fixes: #1685
x-ref: penumbra-zone/penumbra#4392

Co-authored-by: Conor Schaefer <[email protected]>
conorsch added a commit that referenced this issue Jul 31, 2024
Adds a version of grpcui to the local nix dev env. Includes logic
to build the go binary from source, via nix, because the released
version of grpcui upstream still uses the old v1alpha reflection API,
which is incompatible with current versions of `pd`.

Refs #4392.
conorsch added a commit that referenced this issue Jul 31, 2024
Adds a version of grpcui to the local nix dev env. Includes logic
to build the go binary from source, via nix, because the released
version of grpcui upstream still uses the old v1alpha reflection API,
which is incompatible with current versions of `pd`.

Refs #4392.
conorsch added a commit that referenced this issue Aug 6, 2024
Adds a version of grpcui to the local nix dev env. Includes logic
to build the go binary from source, via nix, because the released
version of grpcui upstream still uses the old v1alpha reflection API,
which is incompatible with current versions of `pd`.

Refs #4392.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-node Area: System design and implementation for node software C-bug Category: a bug needs-refinement unclear, incomplete, or stub issue that needs work _P-high High priority _P-V1 Priority: slated for V1 release
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

4 participants