netgroup / eclat-daemon

eCLAT (eBPF Chains Language And Toolset) daemon.
2 stars 0 forks source link

improve error messages in eclat #23

Open hike-eclat opened 2 years ago

hike-eclat commented 2 years ago

1) writing a wrong program name in an eclat script should result in a clear error message, while now we have:

Exception: function alt_mark has not been imported

hike-eclat commented 2 years ago

we should clarity : in which script? and at which line?

hike-eclat commented 2 years ago

2) another improvement (I have not opened a new issue) if a wrong package name is supplied for example loaders.basic instead of loaders.hike_default the following error is received

grpc._channel._InactiveRpcError: <_InactiveRpcError of RPC that terminated with:
        status = StatusCode.UNKNOWN
        details = "Exception calling application: package basic not found in the repository"
        debug_error_string = "{"created":"@1652052101.171774400","description":"Error received from peer ipv4:127.0.0.1:50051","file":"src/core/lib/surface/call.cc","file_line":1069,"grpc_message":"Exception calling application: package basic not found in the repository","grpc_status":2}"

at least we should read : "Exception calling application: package loaders.basic not found in the repository"

StefanoSalsano commented 2 years ago

3) if an eclat script asks to load a chain which is already loaded, a clear error message should be received