CCL1043: SNC CLI cannot find an active connection to an instance

Ryan Magsam1
Mega Guru

When I run the command to scaffold a new project I get this error:


$ snc ui-component project --name now-experience-dashboard --description "My first NXF component built at CreatorCon"
Could not find an active connection to a ServiceNow instance.

I made sure my instance was unpaused and re-ran the profile configuration command. I get the following output.


$ snc configure profile set
✔ Connection to https://nowlearning-lpt0397125-001.lab.service-now.com successful.
✗ This instance does not support dynamic commands. Functionality will be limited.
Profile default has been saved

When I re-run the command to scaffold the project, I get the same error saying that it cant find an active connection.

Environment:

  • macOs Catalina
  • node version 12.22.1
  • snc version 1.1.0
  • ui-component extension version: 19.0.0
1 ACCEPTED SOLUTION

ThierryD1
Mega Expert

Hi Ryan,

I don't know why, but now it's OK for me !

Here are the following steps I tried :

- firstly, I create a named profile related to another instance (release = Paris).

- I tried the "snc ui-component project" command (after adding --profle the_name_of_my_named_profile)

- it was succesful

- then I relaunched the command with my default profile (related to my quebec instance)

- It was successful too !!!

 

I can't explain why... But maybe, you could try.

 

View solution in original post

8 REPLIES 8

ugly bug... almost broke my head searching for a solution.

When I try to Login using that command I get 

Connection to "instance url..." failed. Credentials not saved.
self-signed certificate in certificate chain

Ive tried adding profiles to a PDI and a paid instance and tried using both those profiles as parameters by adding [--profile NAME] to the command. Even when using different profiles I get that error. Any Ideas?

System                            : Win 10

Node version                 : v12.16.1

NPM version                 : 6.13.4

SNC version                   : 1.1.2

UI component version  : 24.0.1

Instance versions          : Tokyo & Vancouver

 

I also get the warning: 

This instance does not support dynamic commands. Functionality will be limited.

Not sure if that's relevant. 

I just dusted off an old ui component and tested out my connections. Everything seems to be working for me on my since upgraded instances (W and V) 

 

The only hint I have, is that second line. Perhaps the connection is not trusted because of the self-signed certificate. If you are using a work laptop with weird VPN / security measures, try the same on a personal computer to connect to the PDI.

 

There may be a way to set snc command to ignore this but you would probably have to re-compile from source with the changes.

Thanks for the response. 

I did try it using my personal laptop instead of work laptop and it worked flawlessly. Took me a while to realize it was a laptop issue as opposed to a ServiceNow or Node issue.