nimi-python icon indicating copy to clipboard operation
nimi-python copied to clipboard

session.proto should be replaced with a dependency on ni.grpcdevice.v1.proto

Open bkeryan opened this issue 3 months ago • 0 comments

Description of issue

The nimi-python packages contain duplicate protobuf codegen for session.proto. This only works when the duplicated codegen is exactly identical across all installed packages; if any package has a slightly different version of this codegen, users will get an error such as

ERROR: Exception calling application: Couldn't build proto file into descriptor pool: duplicate symbol 'nidevice_grpc.SessionInitializationBehavior'

The path forward is to add a dependency on https://pypi.org/project/ni.grpcdevice.v1.proto/ to the grpc extra. This will single-source the codegen for session.proto. See https://github.com/ni/ni-apis-python/issues/75 for more details.

System report

N/A

Steps to reproduce issue

  1. Rebuild one package to use the latest version of https://github.com/ni/ni-apis/blob/main/ni/grpcdevice/v1/session.proto
  2. Install the rebuilt package along with one of the previously released packages.
  3. Create gRPC sessions using both of the packages. You will get an error when loading the gRPC stubs.

bkeryan avatar Dec 08 '25 17:12 bkeryan