Install SQLAlchemy - migration db problem

Hi all,
just tried tovupgrad hass. Thanks for all the great work you guys are doing!!!

for a reason it is not upgrading to 24. I don’t know. probably i am to soon with the upgrading?

I installed SQLAlchemy without any problem with the virtual env environment. But I cannot get the script working. I get this message:

(hass_venv) hass@beaglebone:~$ hass --script db_migrator --config /home/hass
usage: hass [-h] [--version] [-c path_to_config_dir] [--demo-mode] [--debug]
            [--open-ui] [--skip-pip] [-v] [--pid-file path_to_pid_file]
            [--log-rotate-days LOG_ROTATE_DAYS] [--install-osx]
            [--uninstall-osx] [--restart-osx] [--runner] [--daemon]
hass: error: unrecognized arguments: --script db_migrator

What am i doing wrong?

Are you running the dev branch?

No, I don’t think so. I installed the basics by using the fabric installer.

Ok, than your are still on version 0.23. You can not run that command before 0.24 is out.
The blog post about version 0.24 is probably published by a mistake

true, but for a reason I cannot update to 24. Am i to early and do I have to try tomorrow again? normally I update without a problem, but this time I ran the update proces, but nothing has changed (but it installed a new version). Still on 23.1

0.24 is not released yet, so you have to wait

I reacted to soon. As I understand you, officially 24 is out :-). and I see now your last post coming in. Thanks for getting me out of this confusion :smile:

Sorry, I merged the docs already but the release will come in the next hour or so.

1 Like

Hey Fabaff,
updating was without a problem this morning :smile:

But the script for the database doesn’t work for me. Is it possible that I don’t have the .homeassistant directory.
I have my configuration file in this directory:
/home/hass$ dir
configuration.yaml home-assistant.db known_devices.yaml
deps home-assistant.log phue.conf

Do i have to change the script?
Thanks!

Try:

hass --script db_migrator --config /home/hass/

Already tried but the script returned with the message that it could find .homeassistant/home-assistant.db

Can you post the exact error message?

(hass_venv) hass@beaglebone:/home/bart$ hass --script db_migrator --config /home/hass/
Fatal Error: Old format database ‘/home/hass/.homeassistant/home-assistant.db’ does not exist

It might be a bug in the script. You can try to remove line: 86 and 87 in home-assistant/homeassistant/scripts/db_migrator.py

It might be wise to have backup of your database before you do this

I cannot get the migrator to work… I cannot even find it in the virtualenv environment. At this moment I see the both files next to each other in the hass dir.
I think I just let it go. Start with a new history :slight_smile:. Thanks for you help anyway.