Problem with configuration


After upgrading my viktor-cli from 0.9.3 to 0.11.1, I ran into some problems. It felt similar to the discussion at Problem with ciktor-cli, but I cannot figure it out.

When I use viktor-cli I seem to have lost my authorizations. F.e. when using command viktor-cli version, I get:

viktor-cli v0.11.1
could not determine the latest version of viktor-cli

Likewise, when starting an installed app:

could not determine the latest version of viktor-cli
2021/12/13 10:48:04 Error 6
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "src/connector.pyx", line 191, in init connector
OSError: Not authorized.

My docker and systems are connected just fine, when using viktor-cli check-systems. I have used viktor-cli configure, but no change to my password was made.

What should I do?

Are you using Hyper-V or WSL2?

If you are using WSL2, what is printed if you run:

curl -I --fail

in the Linux terminal?

I have used viktor-cli configure, but no change to my password was made

Can you elaborate on this? Did the call return an error or not? What file did you check to confirm the password was not updated?

I don’t recall whether I use Hyper-V or WSL2, how can I check?

After running the command in my powershell I got the following message:

HTTP/1.1 200 OK
Content-Type: text/html
Content-Length: 3961
Connection: keep-alive
Last-Modified: Thu, 04 Nov 2021 18:27:33 GMT
Accept-Ranges: bytes
Server: AmazonS3
Date: Mon, 13 Dec 2021 04:21:43 GMT
ETag: "41f0211ff315bbd7e2b6dc2e98143935"
Vary: Accept-Encoding
Cache-Control: public, max-age=86400
X-Cache: Hit from cloudfront
Via: 1.1 (CloudFront)
X-Amz-Cf-Pop: AMS54-C1
X-Amz-Cf-Id: 3mmaqUA44YVk3fcGvANq_GaDsYK2W5MdFmAMNykUTaYfS6Xb5CtPxg==
Age: 26913

About the configure command, I did not provide an error. I have not checked in a file, whether it actually is the same still, but I can still log in on my development VIKTOR environment. My app did not start after upgrading viktor-cli, then I tried the configure command, setting the exact same login credentials as before.

The token you have to set in viktor-cli configure is NOT related to the password you set yourself for logging in to your dev-URL in the browser. It is the VIKTOR token you received from us when starting developing with VIKTOR. You cannot change the token yourself.

This also does explain the error you get. If the token is not correctly set, the viktor-cli version indeed returns the message you posted. Restoring the right token with viktor-cli configure should solve your problem.

EDIT: in an upcoming release there will be an additional verification message that the mail and token provided in viktor-cli config are valid (or not). This will help in tackling this issue in an earlier stage.

That worked. Thanks!