openhab / openhab-vscode

VS Code extension for openHAB configuration files
https://marketplace.visualstudio.com/items?itemName=openhab.openhab
Eclipse Public License 2.0
159 stars 47 forks source link

Sitemap preview does not work: resource not available #109

Closed nanosonde closed 5 years ago

nanosonde commented 6 years ago

The sitemap preview does not work in 0.4.0.

Expected Behavior

A click on the openHAB2 icon opens the sitemap preview in basicui mode since basicui is set as preview mode.

Current Behavior

When clicking on the openHAB2 icon in the right-top corner it gives the error message: "home cannot be opened: resource is not available"

"home" is the name of the sitemap: home.sitemap

Further infos

The debug console gives:

textModelResolverService.ts:88 Unable to open 'openHAB://search?%7B%22hostname%22%3A%22http%3A%2F%2F192.168.10.13%3A8080%22%2C%22route%22%3A%22%2Fbasicui%2Fapp%3Fsitemap%3Dhome%22%7D' resource is not available.

The decoded URL looks like this:

openHAB://search?{"hostname":"http://192.168.10.13:8080","route":"/basicui/app?sitemap=home"}

When calling the URL http://192.168.10.13:8080/basicui/app?sitemap=home manually in the browser, the correct sitemap is shown in basicui.

Your Environment

openHAB2:

VSCode:

udo1toni commented 6 years ago

According to https://community.openhab.org/t/vs-code-openhab-extension/30205/268?u=udo_hartmann this is the same as #108

Confectrician commented 5 years ago

Adressed in #117