-
-
Notifications
You must be signed in to change notification settings - Fork 149
Description
Context
Kitsu version: 0.20.101, 0.20.89
Production type: 3D Animation
Describe the bug
I have accidently set a Sunday as a day off for an artist and now I can not delete it.
Normally to delete a day off added in error, you add a day off again to the same date, and it removes the day off.
Because the day is a weekend, the calendar in the Add Day Off dialog won't let me select it.
I've tried marking the previous Friday through to the next Monday as days off, but it throws an error saying there is already a day off in the range.
How this happened: When I went to add a day off, I went to the timesheet for the person in question, I set the date to 2025-10-27, clicked Day Off, and didn't realize that the pop up had the calendar set to one day earlier, Sunday 2025-10-26, when I clicked Confirm.
The date on the Add Day Off sets itself to one day earlier than the day you are looking at on the timesheet. This seems wrong.
At some point, I think this was when I tried deleting multiple days off covering the Friday and Monday surrounding the weekend, the Add Day Off dialog posted this error:
(psycopg.errors.CheckViolation) new row for relation "day_off" violates check constraint "day_off_date_check" DETAIL: Failing row contains (ea0e4e3f-d247-4f33-b477-9447dad7036a, 2025-10-29 08:08:10.189767, 2025-10-29 08:08:10.189777, 2025-10-27, 18fa43d5-4077-4efb-80bf-998586fefd90, 2025-10-26, null). [SQL: INSERT INTO day_off (date, end_date, description, person_id, id, created_at, updated_at) VALUES (%(date)s::DATE, %(end_date)s::DATE, %(description)s::VARCHAR, %(person_id)s::UUID, %(id)s::UUID, %(created_at)s::TIMESTAMP WITHOUT TIME ZONE, %(updated_at)s::TIMESTAMP WITHOUT TIME ZONE)] [parameters: {'date': '2025-10-27T22:00:00.000Z', 'end_date': '2025-10-26T22:00:00.000Z', 'description': None, 'person_id': '18fa43d5-4077-4efb-80bf-998586fefd90', 'id': 'ea0e4e3f-d247-4f33-b477-9447dad7036a', 'created_at': datetime.datetime(2025, 10, 29, 8, 8, 10, 189767), 'updated_at': datetime.datetime(2025, 10, 29, 8, 8, 10, 189777)}] (Background on this error at: https://sqlalche.me/e/20/gkpj)
Another weird thing, If I have set a persons day off as today, I can't enter time spent for any earlier days for them, as the time sliders are not appearing. Also trying to set a day off for any other date brings up "Days off are currently applied from 2025-10-29 to 2025-10-29. Are you sure you want to remove this period?" 2025-10-29 being the current date I tried this on.
- OS: Windows 10
- Browser: Brave, Firefox