Opensnitch runtime error due to Python package not currently in nixpkg repo

On unstable, when I run “opensnitch-ui” I get the following error:

/nix/store/dyjz8kf7id22i9js6lkknq71pvm3z1i6-python3.11-protobuf-5.28.2/lib/python3.11/site-packages/google/protobuf/runtime_version.py:112: UserWarning: Protobuf gencode version 5.27.2 is older than the runtime version 5.28.2 at ui.proto. Please avoid checked-in Protobuf gencode that can be obsolete.
  warnings.warn(
Traceback (most recent call last):
  File "/nix/store/0k12vibb7qw546nw3wpwvys1zaz9yz3v-opensnitch-ui-1.6.6/bin/.opensnitch-ui-wrapped", line 42, in <module>
    from opensnitch.service import UIService
  File "/nix/store/0k12vibb7qw546nw3wpwvys1zaz9yz3v-opensnitch-ui-1.6.6/lib/python3.11/site-packages/opensnitch/service.py", line 16, in <module>
    from opensnitch import ui_pb2_grpc
  File "/nix/store/0k12vibb7qw546nw3wpwvys1zaz9yz3v-opensnitch-ui-1.6.6/lib/python3.11/site-packages/opensnitch/ui_pb2_grpc.py", line 19, in <module>
    raise RuntimeError(
RuntimeError: The grpc package installed is at version 1.64.1, but the generated code in ui_pb2_grpc.py depends on grpcio>=1.66.1. Please upgrade your grpc module to grpcio>=1.66.1 or downgrade your generated code using grpcio-tools<=1.64.1.

The latest version of grpcio available is v1.64.1. How would I go about getting grpcio v1.66.1 or later in NixOS?

I also tried installing grpc (v1.66.1) and python313 to no avail.

thanks for the report! could you please open a issue in the nixpkgs repo and ping me, thank you :slight_smile:

1 Like

@onny thanks for looking into this. Opensnitch runtime error due to Python package not currently in nixpkg repo · Issue #350923 · NixOS/nixpkgs · GitHub