Question
· Apr 4

VSCode connect to non-existing namespace - unable to select other namespace

My VSCode folder was set up to connect to a namespace, but the namespace was deleted. I tried changing the namespace from the menu but it fails (could not retrieve list of namespaces), but I do get the following error message:

This server does not have specified namespace 'FEAT-1-MY-FIRST-ISSUE'.

You must select one of the following: %SYS, CICD-DEMO, CUSTOMER, HSCUSTOM, HSLIB, HSSYS, PERSONAL, PHONEBOOK, USER.

Check your server details in Settings (gitlab-cicd-dev[FEAT-1-MY-FIRST-ISSUE]).

I solved this by recreating the namespace on the server, after that I could change the namespace again in VSCode. (and delete the temporary namespace)

Is this a known issue/what is the easiest way to deal with this? In this specific use case we are going to create temporary namespaces for working on features, and delete them when they are merged into the main development branch, so this might happen more often.

VSCode is up-to-date 

Product version: IRIS 2023.1
Discussion (9)7
Log in or sign up to continue

Hello, I encountered a similar issue but managed to resolve it.

If you were connected directly to the server-side folders, try the following steps: 
1. Click: View -> Command Palette -> Open Workspace Settings (JSON) 

2. In the "folders" property of the JSON you should see something like: 

"folders": [
	{
		"name": "<server_folder_name>:<namespace>",
		"uri": "isfs://<server_name>:<namespace>/"
	}
]

3. Try replacing the old one with the new one. 

If you were working on a local folder that was connected to a server, you should have a .vscode folder in your VSC workspace.

1. Try editing the settings.json file inside the folder. You should see something similar to: 

"objectscript.conn": {
    "server": "<server name>",
    "ns": "<namespace name>",
    "active": true
}

2. Edit the connection with the name of the server you want to reach

You can try signing out of the account.  Then you would have to go through the sign-in process again.  Look for the Accounts icon in the lower left corner of VCS. 

 

Click it and find the namespace you are logging into in the list.  Click the arrow to the right of the name and sign out.

If you have a folder associated with a namespace that is still blocking you this folder should appear in the Explorer window on the left side of VCS.  Right click the top level of the folder and find the "Remove Folder from Workspace" option.  It should be in the middle of the menu.  That will remove it from your workspace and allow you to switch.

These are kind of "citizen developers", using the folder structure using one namespace at a time. Each feature which they work on has its own namespace, which might be deleted when the feature is approved and merged into the main branch. They can understand that a namespace has been deleted, but not being able to select another one by using the normal VSCode UI will be a bad experience for them as this might happen quite regularly.