Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Creating backups or updating from SEPIA-Home v2.6.0 to v2.6.1 can fail due to missing old folder #155

Open
fquirin opened this issue Jan 30, 2022 · 15 comments
Labels
bug Something isn't working

Comments

@fquirin
Copy link
Contributor

fquirin commented Jan 30, 2022

The backup and update scripts in SEPIA-Home v2.6.0 can fail if you've installed a clean v2.6.0 and didn't import a backup of an older version! This is because the old, integrated reverse-proxy has been removed but is still included in the backup script.

To fix this issue please update your backup and update scripts. Go to your SEPIA folder (usually ~/SEPIA) and run:

rm update-sepia.sh && rm backup-sepia.sh
wget "https://raw.githubusercontent.com/SEPIA-Framework/sepia-installation-and-setup/master/sepia-custom-bundle-folder/update-sepia.sh"
wget "https://raw.githubusercontent.com/SEPIA-Framework/sepia-installation-and-setup/master/sepia-custom-bundle-folder/backup-sepia.sh"

Now you can run bash backup-sepia.sh and bash update-sepia.sh as you're used to :-).

If you don't want to replace the files manually there is a new update tool that can be used as well. Go to your user home folder (right outside of SEPIA) and run:

wget https://sepia-framework.github.io/install/sepia-home-rpi-update.sh && bash sepia-home-rpi-update.sh

After that simply follow the instructions on screen.

Sorry for the inconvenience,
Florian

@fquirin fquirin added the bug Something isn't working label Jan 30, 2022
@fquirin fquirin pinned this issue Jan 30, 2022
@royrogermcfreely
Copy link

royrogermcfreely commented Feb 1, 2022

hey,

first, great work. i love the graphhopper api. works great for weather and directions, im looking forward what we can do in the future with the possibilities of PoI and geo api. now nobody needs to give debitcard numbers to google ;)

when i backup SEPIA with the new backup script and do the update with the new script, the server are update to date but the option in the coresettings for graphhopper (default_po_api and default_directions_api) are not shown.

also when i set up a new machine with the newest release i get all coresettings. but after the import-backu.sh the options in the coresettings are removed.
also my personal teached sentences are not imported. do i have to copy them manualy?

i tried also to set them manualy but nothing changed.

/roy

@fquirin
Copy link
Contributor Author

fquirin commented Feb 1, 2022

first, great work. i love the graphhopper api. works great for weather and directions, im looking forward what we can do in the future with the possibilities of PoI and geo api. now nobody needs to give debitcard numbers to google ;)

Thanks 🙂 . Actually there are a few sentences for POI already for example "where is the nearest hospital?" should show you directions and a button with "alternative destinations" (something like that). Btw the directions API can be triggered with specific sentences as well like "how far is it from A to B?".

when i backup SEPIA with the new backup script and do the update with the new script, the server are update to date but the option in the coresettings for graphhopper (default_po_api and default_directions_api) are not shown.

Yes this is unfortunately because I cannot merge old and new settings properly right now, so the script simply overwrites the new file with the old one and uses defaults for missing entries. You can simply copy missing entries by hand to your properties file or add them via core-settings page (Control-HUB) using the custom field below the "known" settings.
Thinking about it ... I should be able to add the default fields to the core-settings page although they are not in the file 🤔 ... I'll put this on the list for the next update ^^.

also my personal teached sentences are not imported. do i have to copy them manualy?

This should not happen because they are stored in the database 😟. Or do you mean custom files in sepia-assist-server/Xtensions/Assistant/... ? Anyway both should be restored properly. Login with the old accounts works fine?

@royrogermcfreely
Copy link

yeah i tried the "how far example" :)

the old users, smart home devices and api keys were restored.

i mean the senteces you can teach inside the client.

@fquirin
Copy link
Contributor Author

fquirin commented Feb 1, 2022

the old users, smart home devices and api keys were restored.
i mean the sentences you can teach inside the client.

That is very weird because they are part of the DB as well. Can you double-check the core settings for enable_custom_commands and maybe enable_sdk (the SDK should not effect the Teach-UI but anyway ...). When you open the Teach-UI inside the app do you get any error message?

@royrogermcfreely
Copy link

custom_commands and skd are enabled.

Yes this is unfortunately because I cannot merge old and new settings properly right now, so the script simply overwrites the new file with the old one and uses defaults for missing entries. You can simply copy missing entries by hand to your properties file or add them via core-settings page (Control-HUB) using the custom field below the "known" settings.

i tried to add them from the control hub and the entries shows up but the geolocation is not working.

where is the properties file located so i can try to copy them

@fquirin
Copy link
Contributor Author

fquirin commented Feb 2, 2022

custom_commands and skd are enabled.

and the Teach-UI? Is it showing any data or throwing any errors?

but the geolocation is not working.

Geolocation in general or do you get the "API keys" info button? What is your current client? Raspberry Pi Bullseye?

where is the properties file located so i can try to copy them

SEPIA//sepia-assist-server/Xtensions/assist.custom.properties

You will see 3 files there. The "custom" file should be replaced with your old settings. You can compare it to one of the other files (preferably assist.properties) to get the "original".

@royrogermcfreely
Copy link

the geolocation in general, like for navigation, weather in diffrent cities etc. is not working, even the coresettings (key, poi/directions_api) are set correctly

im running sepia on a proxmox debian 11 vm.

the teach ui shows notthing,
i can create teach sentences and they work.
tried now diffrent ways to upgrade. everything works except the import of the my teach sentences and the geolocation (with hub set and also tried to write direct to the file)

@fquirin
Copy link
Contributor Author

fquirin commented Feb 3, 2022

the geolocation in general, like for navigation, weather in diffrent cities etc. is not working, even the coresettings (key, poi/directions_api) are set correctly

What exactly does SEPIA say when you try "how is the weather in Berlin?" for example? Do you see the "API Key" info button under the chat message?

im running sepia on a proxmox debian 11 vm.

I had some issues with Chromium 95 on Debian 11 for Raspberry Pi, but I don't think that effects the Geo stuff here, especially not if you ask for other cities like in the example above.

the teach ui shows notthing

ok so lets check if the DB is empty. If you log in to the Control HUB as admin and then go to the "speech recognition" page you can export your sentences for different languages. Can you try this for German and English and see if you get anything back?

@royrogermcfreely
Copy link

royrogermcfreely commented Feb 3, 2022

What exactly does SEPIA say when you try "how is the weather in Berlin?" for example? Do you see the "API Key" info button under the chat message?

Sepia says: Sorry, da gab es wohl einen Fehler. Versuch es doch noch mal bitte.
and there is no "API Key" info button.

ok so lets check if the DB is empty. If you log in to the Control HUB as admin and then go to the "speech recognition" page you can export your sentences for different languages. Can you try this for German and English and see if you get anything back?

thats my result for german and english on the sepia 2.6.1

{
  "result": {
    "sentences": []
  }
}

on the old machine i get all teached sentences

@fquirin
Copy link
Contributor Author

fquirin commented Feb 3, 2022

Sepia says: Sorry, da gab es wohl einen Fehler. Versuch es doch noch mal bitte.
and there is no "API Key" info button.

Looks like an internal error. Can you check SEPIA/sepia-assist-server/log.out to see if there are any errors logged?

on the old machine i get all teached sentences

I have no idea how its possible to get a partially working database where only the commands are missing :-|.
I'd suggest to simply copy over the whole SEPIA/es-data folder from your old machine and replace the new one.

@royrogermcfreely
Copy link

hey
copy the es-data folder worked. now i have all sentences i teached, smarthome dvices etc.

also the geolocation works now - i didnt saw that i wrote "graphopper" instead of "graphhopper". my fault mea culpa :)

but thanks everything works now and i can go on with my summary about nextcloud integration.
hopefully i can post it over the weekend.

/roy

@fquirin
Copy link
Contributor Author

fquirin commented Feb 3, 2022

great! 😃
I still wonder what the problem was with the database though. Maybe if you have time could you try to run the update once more just to test if it works now?

@royrogermcfreely
Copy link

when i run the "import-backup.sh" with the backup.zip again now, everything is here. (teached sentences, smart home devices etc)

@Shanmus1
Copy link

Shanmus1 commented May 9, 2022

I need help

@fquirin
Copy link
Contributor Author

fquirin commented May 9, 2022

I need help

What did you try so far and what is not working 😅 ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants