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

Excess number of backup videos being created with version 1 #1397

Closed
susanodd opened this issue Nov 26, 2024 · 5 comments
Closed

Excess number of backup videos being created with version 1 #1397

susanodd opened this issue Nov 26, 2024 · 5 comments

Comments

@susanodd
Copy link
Collaborator

susanodd commented Nov 26, 2024

For some reason, numerous video uploads are being done for the same gloss repeatedly, each creating a new backup of the previous video upload. Sometimes upwards of 30 video files. There are matching requests for each of these. "Op hol slaan"

@Jetske
Copy link
Collaborator

Jetske commented Nov 26, 2024

After asking @rem0g it turns out this was probably an upload script stuck in a loop. Has been fixed.

To clean up the duplicate backup files, is there already command for that (if so I can't find it)? Or what would be the best way to do this?

@susanodd
Copy link
Collaborator Author

susanodd commented Nov 26, 2024

There were some more today, so I don't know if it's totally fixed. Regardless, there is nothing to stop the API user from uploading the same video file over and over again.

There isn't a command for them. The files need to be deleted before you can delete the objects.
But then the version numbers need to be modified, because they won't be correct anymore.
I was working on that for the old format "bak.bak" files. But I didn't delete files. I only removed objects if there was no file.
Then enumerated over what was left to give them new version numbers.
I'm guessing though that all the backup files created can safely be deleted.

I guess we could implement a command to do that in the admin.
The files need to be "unlinked". You can see that in the video code.

If you just remove the files you can also just remove the objects.
We don't really know how extensive this is.

If you look at the files in the terminal screen, it's kind of impossible to determine just by looking what is to delete. All the file names start with the same first two characters, then you need to browse to the end to see if it's the same gloss or not.
So it would be time consuming to do by hand.
It would also be difficult to keep searching in the admin for ones to select, to delete. (Assuming a new admin command.)
It's also unfortunate that all the new backup files have version 1.
An admin command to "delete a backup video" would need to

  1. unlink the file if a file exists
  2. delete the object
  3. renumber all the versions of all the other backup videos for the same gloss

@Jetske I'll make a command as such.

Probably in the API request, it ought to check if the "new" video is the same as the "existing" video. There's an OS command for that.

@susanodd

This comment was marked as outdated.

@susanodd susanodd added the API label Nov 27, 2024
susanodd added a commit that referenced this issue Nov 27, 2024
after selection was deleted, version numbers adjusted for new set. Change extension of backup file if it has the wrong video extension for its format.
susanodd pushed a commit that referenced this issue Nov 29, 2024
change file extension command, match file type
@susanodd
Copy link
Collaborator Author

susanodd commented Dec 5, 2024

See #1412 a command has been added to the Manage Video Storage to repair incorrect version numbering

@susanodd susanodd changed the title Excess number of backup videos being created by the API Excess number of backup videos being created with version 1 Dec 5, 2024
@susanodd susanodd added the bug label Dec 5, 2024
@susanodd
Copy link
Collaborator Author

susanodd commented Dec 9, 2024

This is fixed now. Some administration functionality is being added in order to repair the wrongly numbered gloss video objects and their files, if necessary. (#1406 )

@susanodd susanodd closed this as completed Dec 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants