IRL2 / nanover-server-py

https://irl2.github.io/nanover-docs/#
Other
0 stars 1 forks source link

Issue using grpcio-tools 1.62 and above -- not caught by automated tests #261

Open rhoslynroebuck opened 1 month ago

rhoslynroebuck commented 1 month ago

I'm running into the following error when running the puppeteering client in SubtleGame, which has happened since I updated my nanover-server package today:

C:\Users\rhosl\miniforge3\envs\subtle-game\python.exe C:\Users\rhosl\GIT_REPOS\SubtleGame\Client\puppeteering_client.py 
C:\Users\rhosl\miniforge3\envs\subtle-game\Lib\site-packages\nanover\protocol\command\command_service_pb2_grpc.py:21: RuntimeWarning: The grpc package installed is at version 1.62.2, but the generated code in nanover/protocol/command/command_service_pb2_grpc.py depends on grpcio>=1.65.5. Please upgrade your grpc module to grpcio>=1.65.5 or downgrade your generated code using grpcio-tools<=1.62.2. This warning will become an error in 1.66.0, scheduled for release on August 6, 2024.
  warnings.warn(
C:\Users\rhosl\miniforge3\envs\subtle-game\Lib\site-packages\nanover\protocol\state\state_service_pb2_grpc.py:21: RuntimeWarning: The grpc package installed is at version 1.62.2, but the generated code in nanover/protocol/state/state_service_pb2_grpc.py depends on grpcio>=1.65.5. Please upgrade your grpc module to grpcio>=1.65.5 or downgrade your generated code using grpcio-tools<=1.62.2. This warning will become an error in 1.66.0, scheduled for release on August 6, 2024.
  warnings.warn(
C:\Users\rhosl\miniforge3\envs\subtle-game\Lib\site-packages\nanover\protocol\trajectory\frame_pb2_grpc.py:20: RuntimeWarning: The grpc package installed is at version 1.62.2, but the generated code in nanover/protocol/trajectory/frame_pb2_grpc.py depends on grpcio>=1.65.5. Please upgrade your grpc module to grpcio>=1.65.5 or downgrade your generated code using grpcio-tools<=1.62.2. This warning will become an error in 1.66.0, scheduled for release on August 6, 2024.
  warnings.warn(
C:\Users\rhosl\miniforge3\envs\subtle-game\Lib\site-packages\nanover\protocol\trajectory\get_frame_pb2_grpc.py:20: RuntimeWarning: The grpc package installed is at version 1.62.2, but the generated code in nanover/protocol/trajectory/get_frame_pb2_grpc.py depends on grpcio>=1.65.5. Please upgrade your grpc module to grpcio>=1.65.5 or downgrade your generated code using grpcio-tools<=1.62.2. This warning will become an error in 1.66.0, scheduled for release on August 6, 2024.
  warnings.warn(
C:\Users\rhosl\miniforge3\envs\subtle-game\Lib\site-packages\nanover\protocol\trajectory\trajectory_service_pb2_grpc.py:21: RuntimeWarning: The grpc package installed is at version 1.62.2, but the generated code in nanover/protocol/trajectory/trajectory_service_pb2_grpc.py depends on grpcio>=1.65.5. Please upgrade your grpc module to grpcio>=1.65.5 or downgrade your generated code using grpcio-tools<=1.62.2. This warning will become an error in 1.66.0, scheduled for release on August 6, 2024.
  warnings.warn(
Username:  ['ecstaticBass4']
Type 'y' to accept this username: y
Keeping username.
Traceback (most recent call last):
  File "C:\Users\rhosl\GIT_REPOS\SubtleGame\Client\puppeteering_client.py", line 277, in <module>
    puppeteering_client = PuppeteeringClient(number_of_trial_repeats=number_of_repeats,
                          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\rhosl\GIT_REPOS\SubtleGame\Client\puppeteering_client.py", line 97, in __init__
    self.nanover_client = NanoverImdClient.autoconnect(name=SERVER_NAME)
                          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\rhosl\miniforge3\envs\subtle-game\Lib\site-packages\nanover\app\client.py", line 295, in autoconnect
    return cls(
           ^^^^
  File "C:\Users\rhosl\miniforge3\envs\subtle-game\Lib\site-packages\nanover\app\client.py", line 201, in __init__
    self.connect(
  File "C:\Users\rhosl\miniforge3\envs\subtle-game\Lib\site-packages\nanover\app\client.py", line 365, in connect
    self.connect_trajectory(trajectory_address)
  File "C:\Users\rhosl\miniforge3\envs\subtle-game\Lib\site-packages\nanover\app\client.py", line 333, in connect_trajectory
    self._frame_client = self._connect_client(FrameClient, address)
                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\rhosl\miniforge3\envs\subtle-game\Lib\site-packages\nanover\app\client.py", line 939, in _connect_client
    client: ClientVarType = client_type.insecure_channel(address=address[0], port=address[1])  # type: ignore[no-redef]
                            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\rhosl\miniforge3\envs\subtle-game\Lib\site-packages\nanover\core\grpc_client.py", line 50, in insecure_channel
    return cls(channel=channel, make_channel_owner=True, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\rhosl\miniforge3\envs\subtle-game\Lib\site-packages\nanover\trajectory\frame_client.py", line 11, in __init__
    super().__init__(
  File "C:\Users\rhosl\miniforge3\envs\subtle-game\Lib\site-packages\nanover\core\nanover_client.py", line 194, in __init__
    super().__init__(channel=channel, make_channel_owner=make_channel_owner)
  File "C:\Users\rhosl\miniforge3\envs\subtle-game\Lib\site-packages\nanover\core\nanover_client.py", line 56, in __init__
    self._setup_command_stub()
  File "C:\Users\rhosl\miniforge3\envs\subtle-game\Lib\site-packages\nanover\core\nanover_client.py", line 172, in _setup_command_stub
    self._command_stub = CommandStub(self.channel)
                         ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "miniforge3\envs\subtle-game\Lib\site-packages\nanover\protocol\command\command_service_pb2_grpc.py", line 42, in __init__
    self.GetCommands = channel.unary_unary(
                       ^^^^^^^^^^^^^^^^^^^^
TypeError: Channel.unary_unary() got an unexpected keyword argument '_registered_method'

Process finished with exit code 1
Ragzouken commented 1 month ago

May need to be explicit in requirements/dependencies list about protobuf grpcio grpcio-tools packages in both python and conda

Ragzouken commented 1 month ago

Related to https://github.com/IRL2/nanover-protocol/issues/248 probably