Homey Community Forum

Export Insights - backup all your Insights data to a NAS or web folder

tools
flow
app
insights
export
#1

https://apps.athom.com/app/com.gruijter.insights2csv

Export Insights

Make a backup of all your insights to your NAS or WebDAV compliant storage. The insights are zipped and stored in .csv format so you can open them in excel and create all kinds of statistics and charts. The export also includes a JSON version of the data.

Backups can be easily scheduled by using the trigger card in a flow. You can schedule a full backup, or a backup per app.

To setup enter the local share (NAS) information and/or the webDAV information. It is possible to use a local share and a webDAV storage simultaneously.

image

Note: making a backup can take a long time (more than 10 minutes), depending on how many insights you have. It is not possible to restore a backup into Homey.

For requests or remarks, visit the forum.

Donate:

If you like the app do not hesitate to donate a cool drink :slight_smile:

Paypal donate

===============================================================================

Version changelog: changelog.txt

6 Likes
#2


Screenshot_20190324-161615

#3

I just uploaded the new Homey V2 compatible version of the Export Insights app to the appstore. After approval it will be available in the beta stream. The stable release will still be for Homey V1, but will eventually be deprecated.

The new version allows you to store all Insights, or Insights of a specific app, to a network drive (NAS) or webDAV folder. It also includes Insights that you cannot get from Athoms Insights page!

Please give me some feedback, so I can improve it even more before making it stable. :kissing_heart:

1 Like
Insight graphs
Easiest way to export insight data to local NAS storage
Save insights on external source
Add all sensor values to insights
#4

The version 2.2.0 was just approved in the appstore, so you can start installing NOW. Note: it is the beta version :partying_face:

1 Like
#5

I tried it and it manages to export my “smaller” apps but gets an error on Fibaro devices. Not sure if it’s the specific app or if it’s because my vast majority of devices are fibaro.

Edit: It would be awesome to see if it could create a folder with incrementing numbers to put the files in. Say I want to export once every week and it puts it in a folder called 2019 and in a subfolder by week number or month or something :slight_smile:

2019-03-28 20:46:08 [err] [App] unhandledRejection! { rrdcached: rrd_fetch_r failed: mmaping file ‘/opt/user/manager/insights/8e4356272fd93eaadd7d86454c5d2137.rrd’: Invalid argument: rrdcached: rrd_fetch_r failed: mmaping file ‘/opt/user/manager/insights/8e4356272fd93eaadd7d86454c5d2137.rrd’: Invalid argument at /node_modules/athom-api/dist/index.js:1:1076029 at at process._tickCallback (internal/process/next_tick.js:189:7) name: ‘rrdcached: rrd_fetch_r failed: mmaping file ‘/opt/user/manager/insights/8e4356272fd93eaadd7d86454c5d2137.rrd’: Invalid argument’, code: 500, cause: t { __athom_api_type: ‘HomeyAPI.ManagerInsights.Error’, code: 500, error: ‘rrdcached: rrd_fetch_r failed: mmaping file ‘/opt/user/manager/insights/8e4356272fd93eaadd7d86454c5d2137.rrd’: Invalid argument’, error_description: ‘rrdcached: rrd_fetch_r failed: mmaping file ‘/opt/user/manager/insights/8e4356272fd93eaadd7d86454c5d2137.rrd’: Invalid argument’, ‘$stack’: undefined } }
2019-03-28 20:45:49 [log] [App] getting logs related to com.fibaro

#6

Hi John,

Thx for trying/testing the new app version! Concerning the error, could you please make an issue for that on Github? Since I cannot reproduce this error myself, I have some more questions for you :slight_smile: https://github.com/gruijter/com.gruijter.insights2csv/issues

Creating subfolders would make my app rather complex.I would somehow have to keep track of the previously created subfolders (and for each user that would be different). Or do you have another idea? And can you explain how this folder structure would be helpful to you? Maybe you can explain more how you want to use the exported data?

Would it help you if I move the creation date/time of the zips to the beginning of the filename? That way it is easy to sort all the files based on date (actually you can already do that now based on the file creation date).

cheers

#7

I’ll try to make an issue on GitHub. I’ve got no user there yet but I’ve been lurking a bit :stuck_out_tongue:

Regarding the folders, it’s no big deal. If it’s hard to implement maybe it was just a bad idea. It’s pretty easy to move things myself now and then.

At the moment my plan is to keep statistics on temperature and humidity on the outside and on 2 different places in my house (in the trusses). I will use the info to see if the conditions are good enough to prevent damage to the house at different parts of the year and see if things improve by taking different kinds of measures and comparing the data from the previoud year for example.

There will be a lot of data and automatically sorting the data in folders by date taken for example would help. And I was thinking folders since there were quite some files that got created each time so the folder it gets saved to will look quite busy in a short amount of time.

Like I said though it’s not a very big deal and can easily be done manually :slight_smile:

#8

Hi @Anders_P_Jensen, let’s continue the discussion here.

The goal of my app is to export the insights as data, not as a graph. But if you have another use case, please share what you need and why. Maybe we can find a solution together :slight_smile:

1 Like
Insights export
#9

Hi Gruijter, thanks for contributing!
I have installed your app, but I do not have a NAS or something else. I am looking for a way to download to a folder on the computer. Is that also possible? Where can I do the setup?

Thank you.
Max

#10

Yes, you can make a network share on your desktop computer. It then works the same as for a NAS. Just make sure your desktop/laptop is on and on the network when you start an export.

For Windows 10 you can find tutorials how to make a network share, e.g. this one: https://www.tenforums.com/tutorials/111783-share-files-folders-over-network-windows-10-a.html

#11

Hi @Camelen ,

I just finished v2.3.0 with significant stability changes. Can you check if that solves your issue with exporting Fibaro? v2.3.0 is now on Github, and will be released in the appstore as soon as Athom approves it.

#12

Great! I will try it as soon as they approve it and report back :slight_smile:

#13

V2.3.0 was just released in the appstore. It is now the stable version. Most important change is that I added internal queueing for export jobs. This reduces peak cpu and memory load on Homey.

This version only works on Homey V2. Users that are still on V1 can keep using the old app, but it is not possible to install it anymore from the appstore.

#14

Difference from before seems to be that it doesn’t stop when the error with fibaro comes but continues after and finishes the rest of the exports.

Same error seems to exist with the fibaro app for me.

2019-04-16 12:30:41 [err] [App] { rrdcached: rrd_fetch_r failed: mmaping file ‘/opt/user/manager/insights/8e4356272fd93eaadd7d86454c5d2137.rrd’: Invalid argument: rrdcached: rrd_fetch_r failed: mmaping file ‘/opt/user/manager/insights/8e4356272fd93eaadd7d86454c5d2137.rrd’: Invalid argument at /node_modules/athom-api/dist/index.js:1:1076029 at at process._tickCallback (internal/process/next_tick.js:189:7) name: ‘rrdcached: rrd_fetch_r failed: mmaping file ‘/opt/user/manager/insights/8e4356272fd93eaadd7d86454c5d2137.rrd’: Invalid argument’, code: 500, cause: t { __athom_api_type: ‘HomeyAPI.ManagerInsights.Error’, code: 500, error: ‘rrdcached: rrd_fetch_r failed: mmaping file ‘/opt/user/manager/insights/8e4356272fd93eaadd7d86454c5d2137.rrd’: Invalid argument’, error_description: ‘rrdcached: rrd_fetch_r failed: mmaping file ‘/opt/user/manager/insights/8e4356272fd93eaadd7d86454c5d2137.rrd’: Invalid argument’, ‘$stack’: undefined } }
2019-04-16 12:30:22 [log] [App] getting logs related to com.fibaro

#15

Could you make an issue on Github for this error? I have some more questions about it. Thx!

#16

I’ll try to find the time to do this.