singnet / snet-sdk-python

Make gRPC calls to SingularityNET services programmatically using Python
MIT License
0 stars 1 forks source link

SDK/CLI separation: hidden use of config #33

Open Necr0x0Der opened 1 month ago

Necr0x0Der commented 1 month ago

How to reproduce:

The issue: the service in this org will not be found until snet network mainnet is not executed in the command line.

The hidden use of the CLI config makes the fact that the service is not found very confusing

PAY2109 commented 1 week ago

Dear @Necr0x0Der, Thank you for reporting this issue. We appreciate your feedback and apologize for any inconvenience caused. After thorough investigation, we have resolved this issue in the v3.3.0 of our app. The config now includes the "network" option. Please update to the most recent release, and if you encounter any further problems, feel free to reopen this issue or create a new one. Best regards, Paul, SingularityNET

Necr0x0Der commented 1 week ago

The issue with snet network mainnet seems to be solved, but "hidden use of config" issue is not solved in general. An attempt to use SDK without CLI leads to creation of config file, and while even if the session is on sepolia network there, SDK works correctly with mainnet, if it is specified in Python, however, the private key is saved into config (which is done secretly and this is bad), and if this secret key is deleted from the config file, SDK complains that Cannot find private_key in the session.identity and in the session.network, while the private key is passed to sdk.SnetSDK(config).