Skip to content

Kitsu Schedule Interface "Invalid date" Error #1977

@Magasul

Description

@Magasul

When using the Schedule view's "Assign Tasks" panel, clicking Apply results in a 400 BAD REQUEST. The frontend correctly calculates the start date and total estimation minutes, but fails to generate a valid timestamp for the due_date, sending the literal string "Invalid date" to the server instead.

Studio name: Freelancer
Kitsu version: 1.0.20
Production type: Any

Technical Details:

  • Endpoint: PUT /api/data/tasks/[task-id]
  • Payload Example:
JSON

{
  "estimation": 7680, 
  "start_date": "2026-04-13", 
  "due_date": "Invalid date"
}
  • Server Error:
Plaintext

sqlalchemy.exc.DataError: (psycopg.errors.InvalidDatetimeFormat) 
invalid input syntax for type timestamp: "Invalid date"
[SQL: UPDATE task SET estimation=%(estimation)s, start_date=%(start_date)s::TIMESTAMP, 
due_date=%(due_date)s::TIMESTAMP ... ]
  • Frontend Error: TypeError at ProductionSchedule.vue:1134 (likely occurring when the UI tries to render the broken date bar).

Observed Math Logic:
The estimation values (5760, 2880, 7680) show that the engine is correctly calculating Total Labor Minutes (Days × Working Hours × 60m × Personnel Count).

  • Example: 6 working days × 16 labor hours (2 people) × 60m = 5760 minutes.
  • The math is correct, but the Calendar Mapping fails to produce a due_date.

Database Findings:

  • Upon inspection of the self-hosted instance:
  • The organisation and studio tables are missing explicit columns for monday...friday.
  • The working_day table does not exist.
  • The project.data JSONB field appears to be missing a working_days array.
  • Hypothesis: The JS scheduler crashes because it cannot find the "Working Days" definition in the project/studio metadata to anchor the calculated minutes to the calendar.

Screenshot_01
Screenshot_02
Screenshot_03

If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

  • OS: Ubuntu (Dockerized Kitsu/Zou)
  • Browser Edge (English language preferred)
  • Version Version 146.0.3856.84 (Official build) (64-bit)
  • Locale: Hungary (CET)
  • Date Context
assignBug.mp4

: Testing with April 2026 dates. Format YYYY-MM-DD

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions