grpc: Regression with grpc 1.46.2 for unimplemented error

What version of gRPC and what language are you using?

gRPC 1.46.2 ruby 3.0.3

What operating system (Linux, Windows,…) and version?

Linux and Mac

What did you do?

Ran a test for pubsub client library that check for Error message UnimplementedError when a wrong domain is given.

What did you expect to see?

Expected the test to run fine and assert on the UnimplementedError

What did you see instead?

The test fails at GRPC with the below error,

 hpack_parser.cc:1216]         Error parsing metadata: error=invalid value key=content-type value=text/html; charset=UTF-8

which lead to retrying from client side causing DeadlineExceededError instead.

Refer for the test run results. https://source.cloud.google.com/results/invocations/1fd7d996-8998-4c49-b034-5c7c93781289/targets/cloud-devrel%2Fclient-libraries%2Fgoogle-cloud-ruby%2Fpresubmit%2Facceptance/log

About this issue

  • Original URL
  • State: open
  • Created 2 years ago
  • Comments: 17 (6 by maintainers)

Most upvoted comments

sorry for the late response, adding the log below

D0619 11:49:53.533069000 123145554423808 hpack_parser.cc:760]          HTTP:1:HDR:CLI: :status: 404
D0619 11:49:53.533079000 123145554423808 hpack_parser.cc:760]          HTTP:1:HDR:CLI: cache-control: max-age=604800
E0619 11:49:53.533090000 123145554423808 hpack_parser.cc:833]          Error parsing 'content-type' metadata: error=invalid value key=content-type
D0619 11:49:53.533099000 123145554423808 hpack_parser.cc:760]          HTTP:1:HDR:CLI: content-type: <discarded-invalid-value> (parse error: INTERNAL: Error parsing 'content-type' metadata: error=invalid value key=content-type)
D0619 11:49:53.533109000 123145554423808 hpack_parser.cc:760]          HTTP:1:HDR:CLI: date: Mon, 19 Jun 2023 06:19:53 GMT
D0619 11:49:53.533116000 123145554423808 hpack_parser.cc:760]          HTTP:1:HDR:CLI: expires: Mon, 26 Jun 2023 06:19:53 GMT
D0619 11:49:53.533123000 123145554423808 hpack_parser.cc:760]          HTTP:1:HDR:CLI: server: EOS (vny/044F)
D0619 11:49:53.533140000 123145554423808 hpack_parser.cc:760]          HTTP:1:HDR:CLI: content-length: 433
E0619 11:49:53.533348000 123145554423808 parsing.cc:811]               INCOMING[0x7f7d2ca99e00;0x7f7d2e8630c0]: Parse failed with INTERNAL: Error parsing 'content-type' metadata: error=invalid value key=content-type [type.googleapis.com/grpc.status.int.stream_id='0']

The error you were facing is now fixed.

I’m also getting the same exceptions with the latest version, do we have any update on this issue?

E0922 14:33:43.878000000 25760 src/core/ext/transport/chttp2/transport/hpack_parser.cc:993] Error parsing ‘content-type’ metadata: invalid value Traceback (most recent call last): File “\Python\Python311\site-packages\google\api_core\grpc_helpers.py”, line 72, in error_remapped_callable return callable_(*args, **kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^ File “\Python\Python311\Lib\site-packages\grpc_channel.py”, line 1161, in call return _end_unary_response_blocking(state, call, False, None) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File “\Python\Python311\Lib\site-packages\grpc_channel.py”, line 1004, in _end_unary_response_blocking raise _InactiveRpcError(state) # pytype: disable=not-instantiable ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ grpc._channel._InactiveRpcError: <_InactiveRpcError of RPC that terminated with: status = StatusCode.UNKNOWN details = “Stream removed” debug_error_string = “UNKNOWN:Error received from peer {grpc_message:“Stream removed”, grpc_status:2, created_time:“2023-09-22T18:33:43.8935151+00:00”}”

The above exception was the direct cause of the following exception:

Traceback (most recent call last): File “c:\python testing\questionanswer_langchain.py”, line 113, in <module> index = mengine.create_index( ^^^^^^^^^^^^^^^^^^^^^ File “c:\python testing\utils\matching_engine_utils.py”, line 77, in create_index index = self.get_index() ^^^^^^^^^^^^^^^^ File “c:\python testing\utils\matching_engine_utils.py”, line 34, in get_index page_result = self.index_client.list_indexes(request=request) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File “Python\Python311\site-packages\google\cloud\aiplatform_v1\services\index_service\client.py”, line 810, in list_indexes response = rpc( ^^^^ File “Python\Python311\site-packages\google\api_core\gapic_v1\method.py”, line 113, in call return wrapped_func(*args, **kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File “Python\Python311\site-packages\google\api_core\grpc_helpers.py”, line 74, in error_remapped_callable raise exceptions.from_grpc_error(exc) from exc google.api_core.exceptions.Unknown: None Stream removed

I’m able to reproduce it and have identified it started from https://github.com/grpc/grpc/pull/29182 Will try to figure out what could have caused this. CC: @ctiller in the mean while.

Still giving the same error with grpc 1.55.0 .

Sample:


pubsub_client = Google::Cloud::PubSub.new endpoint: "example.com"
pubsub_client.topics # Throws ` hpack_parser.cc:1216]         Error parsing metadata: error=invalid value key=content-type value=text/html; charset=UTF-8`

https://github.com/googleapis/google-cloud-ruby/blob/c1e320bc049b28426785843f6700885d7789d261/google-cloud-pubsub/acceptance/pubsub/pubsub_test.rb#L53