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

Reduce roster lock conflicts by releasing locks on 'View Assignments' #1107

Closed
jefft opened this issue Dec 9, 2024 · 3 comments
Closed

Reduce roster lock conflicts by releasing locks on 'View Assignments' #1107

jefft opened this issue Dec 9, 2024 · 3 comments

Comments

@jefft
Copy link
Contributor

jefft commented Dec 9, 2024

Say we have users A and B:

  • User A clicks 'Edit Assignments'
  • User A immediately clicks 'View Assignments'
  • User B clicks 'Edit Assignments'

User B will get a lock error:

image

The lock will persist for the "Lock Length" config setting number of minutes, and there is no obvious way for user A to 'unlock' the roster.

The problem is that while 'Edit Assignments' gets a lock, clicking 'View Assignments' does not release the locks. I believe it should: if you are on 'Edit Assignments', and click 'View Assignments', that is cancelling your edit. There is no other 'Cancel' button (unlike, say, recording attendance).

How about if, after clicking 'Edit Assignments', before making changes, the editor clicks the 'Home' button or any other app link? There is the same problem: they retain their edit lock. Unfortunately we cannot release the lock for them, because the situation is indistinguishable from them opening another tab, clicking around, and returning to their 'Edit Assignments' page. I have no solution for the general case. But the case of clicking 'View Assignments' on the 'Edit Assignments' page is special. We know that editing is over (unlike in the general case). Therefore we can release the locks.

@jefft
Copy link
Contributor Author

jefft commented Dec 9, 2024

PR #1108

@tbar0970
Copy link
Owner

Related: #583

@tbar0970
Copy link
Owner

Related #1063

tbar0970 added a commit that referenced this issue Jan 13, 2025
Release locks when clicking from 'Edit Assignments' to 'View Assignments'. Fixes #1107
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants