The upload of a backup seems to be allowed in read-only mode

סיכום מבוסס בינה מלאכותית

The discussion revolves around the behavior of uploading backups in read-only mode. dax reports that the system allows backup uploads in read-only mode without warning, which should not be permitted. codinghorror questions whether uploads should be allowed at all in this mode. zogstrip confirms that uploads work as expected and asks for a repro. jomaxro notes that while the upload succeeds, the backup doesn’t appear immediately in the list due to a background task. zogstrip explains the delay and suggests refreshing the list via the logs. codinghorror agrees the real issue is the lack of a warning message. zogstrip resolves this by implementing an automatic update of the backup list and adds a clearer UI message to inform users of the upload status.

If you are in read-only mode and you try to upload a backup via gui, the site go ahead and seems to upload the backup even if this is not true.

When you are in read-only mode there should be an alert telling you that you can not load the backup before you disable that mode.

3 לייקים

Hmm shouldn’t uploading a backup be OK in read only mode? I am not sure, @zogstrip?

לייק 1

:thinking: I just tested and uploading a backup while in read-only mode works as expected.

@dax do you have a repro?

Did the backup show up? I was able to upload and get the “uploaded successfully” message, but the backup never appeared in the list.

לייק 1

They take a little while to appear since there is a background task that needs to run in sidekiq to merge the uploaded chunks. Waiting one minute is often enough.

PRO TIP: clicking Logs and then Backups will force a refresh of the backups list.

2 לייקים

Closing this but clearly the UI message presented should warn about the refresh @zogstrip that’s the real “bug” here.. and should be fixed.

2 לייקים

I’ve added some code to push the new list of backups once the file is merged so it automagically updates :fireworks:

https://github.com/discourse/discourse/commit/d233ecbe34f319a8f41ae995c9175fe7a127a353

Also, here’s the new message

6 לייקים