Skip to content

[BUG] Cannot drag a task from the "New" column to the "To Do" column on the Kanban board #391

@BenGWeeks

Description

@BenGWeeks

Description

Dragging a card from the New column onto the To Do column on the Kanban board does not move the card — the state change does not stick. Other column-to-column drags appear to work.

Steps to Reproduce

  1. Open the Kanban board.
  2. Pick a card currently in the New column.
  3. Drag it onto the To Do column and drop.
  4. Observe the card's column (and refresh once to confirm the persisted state).

Expected Behavior

The card moves to To Do and the underlying work item's state is updated accordingly in Azure DevOps.

Actual Behavior

The drag visually previews into the To Do column, but on drop the card snaps back / stays in New (or appears in To Do transiently and then reverts after refresh).

Likely Causes / Investigation Pointers

src/components/tickets/KanbanBoard.tsx (handleDragEnd around lines 212-259) just calls onTicketStateChange(activeItemId, targetState), with no client-side check of whether that state transition is permitted by the work item's process template. If the Azure DevOps WIQL/PATCH rejects the transition (e.g. New cannot move directly to To Do under the current template), the catch logs Failed to update item state and rolls back to the source state — which matches the symptom.

Worth checking:

  • Browser DevTools network tab while doing the drag: is the PATCH to /api/devops/tickets/{id} returning 400/409/422? What does the error body say?
  • Server logs / console.error('Failed to update item state:', error) from KanbanBoard.handleDragEnd.
  • The work item's process template — does it allow New → To Do directly, or does it require an intermediate state (e.g. Active)?
  • If transitions are template-restricted, the Kanban should either (a) hide the disallowed drop target, (b) take the user via the intermediate state automatically, or (c) surface a clearer error toast instead of silently reverting.

Environment

  • Version: 0.8.1
  • Page: /kanban
  • Browser: any

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions