[ANN] SAFE CLI, Go Library, and Integration Tests - Alpha Release

+1 … (seriously - do we need this 20 char min? can’t it be deactivated?)

Please add -v to show the debug output. It should show the exact HTTP call. If this is a problem with the launcher, please open an issue on that github project. If it is a problem w/ the HTTP call I am making, feel free to open an issue on my project.

Here it is with an existing, but newly created, username. The launcher is 0.4.4 (from testnet3)

$ go-safeclient -v dnsaddservice bluebird2 test1 /testdir
2016/05/29 19:10:26 Calling GET http://localhost:8100/auth                                                                                  
2016/05/29 19:10:41 RESP BODY: OK                                                                                                           
2016/05/29 19:10:41 Calling PUT http://localhost:8100/dns                                                                                   
2016/05/29 19:10:41 REQ BODY: {"longName":"bluebird2","serviceName":"test1","serviceHomeDirPath":"/testdir","isPathShared":false}           
2016/05/29 19:10:41 RESP BODY: {"errorCode":-1502,"description":"FfiError::PathNotFound"}                                                   
2016/05/29 19:10:41 Unable to add service: Server error 400: {"errorCode":-1502,"description":"FfiError::PathNotFound"}

EDIT: Am I right in assuming that the directory is created along with the service?

No. See the example at the bottom of https://github.com/cretz/go-safeclient/#usage where you have to mkdir first.

1 Like

OK, I misconstrued the hierarchy of objects (duh).

It appears to be:

LOGIN ID, NAME, DIRECTORIES, SERVICES

With each object containing one or more instances of the object to its right. So you need to create them in that order.

However, the sequence of events in the Demo App misleads one to think that the correct order of creation is: LOGIN ID, NAME, SERVICES, DIRECTORIES because it first asks you to create a name, then a service, and finally to upload a folder. What the Demo app actually does is create a folder called “public” at the time it creates the service, and that’s what I thought the Go app was doing.