Goliothctl - failed to fetch device list : rpc error

Hi,
The command goliothctl is giving “rpc error” messages.

The only goliothctl command that doesn’t give the error is golioth device list.

Am I missing some configuration? Thanks.

Hey @zpm1066! Could you try running the suggested command from the project list operation:

goliothctl config set projectId aqw1066

Then try to list devices again? Also, would you mind sharing the output of goliothctl version?

Hi @hasheddan,

Thank you. I’m now able to list the devices.

$ goliothctl config set projectId aqw1066

$ goliothctl device list

id:"643c620df272169b4557ee61" hardware_ids:"20230416210101-aqw_xenon1" name:"aqw_xenon1"

id:"643c66b2f272169b4557ee63" hardware_ids:"20230416212050-aqw_xenon2" name:"aqw_xenon2"
1 Like

@zpm1066 wonderful! Have a nice day!

Hi @hasheddan ,

With the projectId set correctly, when I try to execute “goliothctl apikeys list”, I get an error. I didn’t expect that to happen. Any reason was to why? Thanks.

$goliothctl apikeys list
2023/06/01 06:55:29 failed to fetch API keys list :rpc error: code = PermissionDenied desc = failed to check permissions to access/modify this resource: user not allowed to call method

I receive that error when I try to list API keys for a project on which I am not the owner (but rather an invited user). Is that the case for you? The project list command should show which project you have selected and whether or not you’re the owner.

➜ goliothctl project list
[ ] id:"my-cool-project"  name:"My Cool Project"  roles:"owner"
[*] id:"ci"  name:"ci"  roles:"invitedUser"
➜ goliothctl apikeys list                                                       
2023/06/01 11:18:14 failed to fetch API keys list :rpc error: code = PermissionDenied desc = failed to check permissions to access/modify this resource: user n
ot allowed to call method

@mike,

I have the following:

$ goliothctl project list

[*] id:"aqw1066" name:"aqw1066" roles:"apikey"

How do I set roles to “owner”? Thanks.