arthurlockman / gatool-ui

gatool is a tool to provide FIRST® Game Announcers with up to date information while announcing events during the FIRST Robotics season. As a web-based tool, it uses up-to-date information about the event to provide a comprehensive set of useful data to Game Announcers. It is designed to work on desktops, laptops and tablet devices.
http://gatool.org
4 stars 0 forks source link

More clarity that a saved change may not actually be uploaded. (This was Week 1 event.) for codebase reference #294

Closed dgconder closed 7 months ago

dgconder commented 7 months ago

I collected some team info and probably forgot I was not on the network at the time but hit save anyway. Later I hooked up to the network. And then did a download expecting my changes to have made it up and back. The info I had thought I saved was now gone to the wind and I had to re collect it.

After this we just used one computer. and at the end did did one upload and a DL on another computer. We were paranoid of loosing data. Mostly because we were just unsure of how it worked.

If there was something more obvious by the team data after failed upload. I might not have did what I did and lost data.

You know you can make it "fool proof" but not "damn fool proof." There will always be some damn fool that comes along and breaks it again. :)

arthurlockman commented 7 months ago

@jameslockman I think we can make it so that if there are local changes that haven't been uploaded yet it won't overwrite them with what it downloads without without a confirmation.

jameslockman commented 7 months ago

We currently look for response code 204 as a successful write. If we get a code other than 204, we cache the request for uploading later. Also, if you have cached content, all interfaces display the cached content rather than anything that comes from gatool Cloud.

I am questioning whether that response code is accurate, based on this ticket. Looking at the API code, it only generates a code 204 regardless of success or failure of the write operation. @arthurlockman can you please investigate?

jameslockman commented 7 months ago

Examining the current behavior: if you are offline, we disable the Submit Changes and upload to gatool Cloud button. This will ensure that all changes while offline will be saved locally. image

When you are back on line, the upload button on the Setup Screen becomes active again and you can upload your local changes. FIRST_Game_Announcer_Tool

When you have locally saved changes, these overpower any changes that you might receive when you download updates from gatool Cloud. In this example, i have locally saved changes for team 78. When I Update Team Data from the setup screen, that content remains.

image

My concern is that you were, in fact, online at the time, as you would not have been able to submit changes to the Cloud (the green button) while offline.

jameslockman commented 7 months ago

We have changed the header for a team's data form. Cursor_and_FIRST_Game_Announcer_Tool_and_TeamDataPage_jsx_—_gatool-ui-beta

jameslockman commented 7 months ago

@arthurlockman is there any way to simulate a condition when data doesn't get stored on our side?