Home Assistant Community Add-on: Visual Studio Code

Experiencing the same thing. If you press CTRL+Z after pasting, it does return to the original indent.

1 Like

Many Thanks, I’ll give that a try.

Tried it - It works - A1
:+1:

How the hell did you find that short-cut ???

CTRL+Z is my favorite shortcut :smile:

Hi @all

I have a Problem with all the wonderful new features under 0.113.0 / 0.113.1. In all the automations I received in visual studio the error message “property not allowed”. Uninstall and install from VS again was no solution. When I check the configuration, the System display no errors. I guess this is a problem on my Visual Studio. Any Idea what can I do?

Many thanks
Frank

The vsc addon for home assistant needs time to catch up with the latest release of HA and the implications of the new structures available.
Be patient it will get there.
I’m sure Frenck is working on it right now
:smiley:

Yep, it should have been released already, but is currently pending on an a couple of PRs I’ve opened against the vscode extensions for Home Assistant.

Furthermore, there is a compatibility issue with code-server (what powers the add-on) and the HA vscode extension.

This isn’t an easy change/fix, this might take a bit.

1 Like

Thanks for the fast response, but my friend receive not the errors with the same code. That is what I not understand.

The behavoir you are showing is correct. It should throw an error with that version (although, that is of course not wished for)

ok, then i will waiting :slight_smile:

Thank you very much for the fast assistant!!!

Just started and installed home assistant on docker (using the bash script) everything setup.
installed the vscode addon. If I understand correctly it should work out of the box. But immediatly it throws an error: cannot connect (see screenshot) any ideas what’s wrong? The dnsname it tries to connect to responds fine if I ping it in the terminal.

Versions I have installed:

Home Assistant version: 0.113.1
arch: x86_64
docker_version : 19.03.12
hassio: true
installation_type : Home Assistant Supervised
Supervisor version: 229
VS Code addon version: 2.3.0

already removed and reinstalled the addon.
also tried the reset-settings option in terminal.

Some logging:

WebSocket Connection to Home Assistant closed with an error: Disconnected from Home Assistant with a WebSocket error with message: Unexpected server response: 502
[Auth Phase] Connecting to Home Assistant... Tries left: 2
WebSocket Connection to Home Assistant closed with an error: Disconnected from Home Assistant with a WebSocket error with message: Unexpected server response: 502
[Auth Phase] Connecting to Home Assistant... Tries left: 1
WebSocket Connection to Home Assistant closed with an error: Disconnected from Home Assistant with a WebSocket error with message: Unexpected server response: 502
[Auth Phase] Connecting to Home Assistant... Tries left: 0
WebSocket Connection to Home Assistant closed with an error: Disconnected from Home Assistant with a WebSocket error with message: Unexpected server response: 502

As you have the x86 base I assume you have installed vsc as the HA addon ?
How are you exposing your config ?
And are you connecting to that from vsc ?
I run vsc on a workstation so no direct experience of the above but exposing via samba always makes this easier

I installed the addon using the addon store in supervisor.
I can open and see all the .yaml config files. But integration is not working because there is no autocomplete for devices when I’m writing code.

See here how it looks:

I don’t understand how to get automatic suggestions for devices etc. it is not working, I’ve seen youtube videos where it show a list when typing.

—UPDATE 28-07-2020—

It has something to do with VScode running inside docker. I tried two vscode docker images and installed the extension manually. It also shows a lot of errors. I got rid of the the whole hassio on docker and now running only HA Core as docker. And use VScode on my local machine. This works fine :slight_smile:

Hi Frenck , I still can’t use the new features? I have restart home assistant today again, but no chance for use all the new commands. always the message “property is not allowed”. sure, that is no issue by my home assistant instance? :wink:

Sorry, maybe I’m too impatient? :-)))

Greetings
Frank

The issues are known, solutions are being implemented. Please have a bit of patience, thanks. :+1:

1 Like
2 Likes

Great Job! Sorry for my big Patience’s :wink: - Now, all is fine on my site! :slight_smile:

1 Like

Can someone tell me how I can access the .storage folder and files in VSC. Thank you.

In setting search ‘hidden’ or ‘hide’. By default the folder is hidden.

2 Likes

Thank you, I tried hidden but not hide, hide bought it up.

On the latest release, the VSCode icon on the sidebar is not displaying (altough its working normally, just missing the icon). Anyone else having this?