vscode-openshift-tools icon indicating copy to clipboard operation
vscode-openshift-tools copied to clipboard

Registry view is empty by default when OpenShift extension is opened

Open odockal opened this issue 3 years ago • 1 comments

Env:

  • Linux, vscode 1.71.2, openshift vsix built from main branch,
  • OS connection About output:
$ "/home/odockal/.vscode/extensions/redhat.vscode-openshift-connector-0.7.0/out/tools/linux/odo" version
odo v3.0.0 (8694f1946)

Server: https://api.crc.testing:6443
Kubernetes: v1.24.0+b62823b

Two issues:

  • I would expect a default devfile registry to be present.
  • If I try to create a devfile registry manually, it can be done, although no component (from registry) is listed and if Refresh is pressed, created registry item disappears.

odockal avatar Oct 20 '22 13:10 odockal

Screenshot 2022-10-20 at 7 01 29 PM

There is Open Registry View action in the title. It opens the editor with all the registries present.

mohitsuman avatar Oct 20 '22 13:10 mohitsuman

@odockal cannot replicate, probably it is happening because you don't have odo preferences initialized yet. My guess it is done with first odo execution, which seems happening after tree content is built already. Will make sure that odo is called before building tree content.

dgolovin avatar Oct 26 '22 06:10 dgolovin

Seem like you are right @dgolovin, after I tried again and looked at registry view later, it is at place.

odockal avatar Oct 31 '22 12:10 odockal

I am reading settings directly as workaround for odo issue (not supporting -o json options for listing the registries). They fixed it in 3.1.0. If I use odo registry list -o json command issue would be fixed.

dgolovin avatar Nov 01 '22 07:11 dgolovin

No problem this time, seems like the patch is working.

odockal avatar Nov 04 '22 13:11 odockal

I have encounter the issue again (Linux). I tried to restart the vscode, log into OCP cluster, but nothing works. @lgrossma Also encountered the same issue on Mac 13.

odockal avatar Dec 07 '22 11:12 odockal

But I can create a component from the registry even though it is visibly missing.

odockal avatar Dec 07 '22 11:12 odockal

Good catch! That is another change in odo behavior. This time odo preferences view call now does not create ~/.odo/preferences.yaml file. But odo registry does.

dgolovin avatar Dec 08 '22 03:12 dgolovin