You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
As commented in #37. If you use "filename": "snapshot_name" and you create snapshots without a unique name things get a bit weird. (i.e. only calling the snapshot "snapshot" or creating more than one a day only with the date.
It means that the addon will keep trying to replace the snapshot, as it will find a file with the same name but different contents. I can see a couple of options:
Look at all the snapshot names and report an error if the names are not unique and the snapshot_name strategy is used.
Add the slug or date to the end of the snapshot name. This could look a little ugly, but it would be easiest.
Provide a new naming strategy which is "snapshot_date", this will save the snapshots as "Snapshot 2018-11-15 08:34:02" and ignore any name given in Hass.io This would then lose any useful information added in the snapshot name.
The easiest solution is for users to create a unique snapshot name. This is trivial with something like this, which will work unless you make more than one snapshot a second (then you probably have bigger issues!).
I'm therefore inclined to update the example in the README to add the time and go with option 1 and display an error and quit if the names are not unique (and the snapshot_name option is used). My only concern here is the repeated support requests as this trips up new users in the future.
The text was updated successfully, but these errors were encountered:
The process doesn't really work if we are uploading based on filename,
and the filename isn't unique.
The safest option is probably then to just drop out and error. We could
improve this in the future, but this change will prevent the addon
constantly re-uploading and overwriting snapshots in dropbox.
Related #40
As commented in #37. If you use
"filename": "snapshot_name"
and you create snapshots without a unique name things get a bit weird. (i.e. only calling the snapshot "snapshot" or creating more than one a day only with the date.It means that the addon will keep trying to replace the snapshot, as it will find a file with the same name but different contents. I can see a couple of options:
snapshot_name
strategy is used.The easiest solution is for users to create a unique snapshot name. This is trivial with something like this, which will work unless you make more than one snapshot a second (then you probably have bigger issues!).
I'm therefore inclined to update the example in the README to add the time and go with option 1 and display an error and quit if the names are not unique (and the snapshot_name option is used). My only concern here is the repeated support requests as this trips up new users in the future.
The text was updated successfully, but these errors were encountered: