How do I upgrade python3 version in venv

I’m a little fuzzy on the exact way this all fits together, but inside my hass venv I get version 3.4.2 of python. I installed 3.6.0 outside of the venv.

Is there a way to upgrade the venv? Or do I just need to run the install of 3.6.0 again from inside venv?

Google searches have been fruitless, and I understand that my python version is causing errors in some sensors I’m trying to use in hass 0.39.0

I don’t think there is a clean way of doing it. I think you would have to create a new virtualenv

Thanks, I’ll give that a try next time I’ve got a bit of time.

Looks like if you use venv to make the environment you can upgrade though

Any updates on how to do this? A step by step walkthough would be nice?
Also,

  1. Do I have to re-install homeassistant
  2. How does it impact my zwave configuration?
  3. Other than YAML files in the .homeassistant directory, are there any others I need to make sure I backup?
  4. Anything else I forgot?
1 Like

I agree that it would be smart to get some instructions for this, given that the podcast today suggested that people update to the new version of python.

In theory you should be able to backup all your HA configuration, wipe the virtualenv, reinstall with python 3.6, install the latest HA version and restore your config files. Theoretically everything should be back to normal just with a newer python under the hood. I haven tried yet but maybe I get around to do that on the weekend.

Great, it’s settled, you will be our test case. Report back to us Monday and document, document, document :slight_smile:

Yay, what could possible go wrong. :slight_smile:
I have to say that I don’t have any zwave components.

that’s ok, as long as the AD structure stays in tact, those should follow.

What do you mean by AD?

Sorry wrong acronym. AD is AppDaemon, meant to say HA = homeassistant

Hehe, for me AD is short for Active Directory :wink: Slightly ambiguous.

I can see where that would be confusing. It’s all in the context of the conversation I guess. I was at a site the other day where people were talking about an access point, and pointing to the wall. For the life of me I couldn’t see anything that even remotely looked like an access point. Till they went over and showed me this huge cabinet (not a wiring cabinet) marked as high voltage. It was a point where they could access their building automation system’s network interface, so it was an Access Point.

1 Like

Ok, weekends over. How’s the documentation looking??? :slight_smile: LOL

I installed 3.6 outside of the virtual environment so it’s on the server and ready to go…

1 Like

Unfortunately it’s still on my list. Sorry.

I know that feeling. LOL

I have a virtual environment on a Pi3, inside the environment

python3 -V
returns Python 3.5.3

I have python 3.6.3 installed
in /home/pi/berryconda3/bin/python3
which is outside the virtual environment

doing a bit of reading, it may be possible to insert symlinks into the /srv/homeassistant/lib/python3.5 directory

looks like loads of people have the same issue?
seems very extreme?

It may be possible, but it is simpler to move the existing venv and create a new one, specifying the python version you want to use.

However, I really don’t see why you would want to change from 3.5 to 3.6. What advantage do you think you would gain?

1 Like