{"record":{"id":"ac165a2ac6df8bfe","repo":"gitlabhq/gitlabhq","slug":"tasklisttoggle-is-not-available-the-work-items","errorCode":null,"errorMessage":"`taskListToggle` is not available. The `work_items_task_list_toggle` feature flag is disabled.","messagePattern":"`taskListToggle` is not available\\. The `work_items_task_list_toggle` feature flag is disabled\\.","errorType":"exception","errorClass":"Gitlab::Graphql::Errors::ArgumentError","httpStatus":null,"severity":"error","filePath":"app/graphql/mutations/work_items/update.rb","lineNumber":168,"sourceCode":"          attributes.delete(:move_after_id)\n        )\n      end\n\n      def can_update?(work_item)\n        current_user.can?(:update_work_item, work_item)\n      end\n\n      # The task list toggle arrives in the description widget, but it's executed\n      # by `update_task` (IssuableBaseService#update_task_event), which doesn't\n      # run widget callbacks => no widget-level permission checking.\n      #\n      # We move it into the base attributes to ensure it triggers the `can_update?` check.\n      def extract_task_list_toggle!(work_item, attributes, widget_params)\n        toggle = widget_params[:description_widget]&.delete(:task_list_toggle)\n        return unless toggle\n\n        if Feature.disabled?(:work_items_task_list_toggle, work_item.resource_parent)\n          raise Gitlab::Graphql::Errors::ArgumentError,\n            '`taskListToggle` is not available. The `work_items_task_list_toggle` feature flag is disabled.'\n        end\n\n        # `update_task` path doesn't run any other normal update processing,\n        # so deny combining toggle with anything else.\n        if attributes.present? || widget_params.except(:description_widget).present?\n          raise Gitlab::Graphql::Errors::ArgumentError,\n            '`taskListToggle` cannot be combined with other arguments'\n        end\n\n        widget_params.delete(:description_widget)\n\n        attributes[:update_task] = {\n          checked: toggle[:checked],\n          line_source: toggle[:line_source],\n          line_sourcepos: toggle[:line_sourcepos]\n        }\n      end","sourceCodeStart":150,"sourceCodeEnd":186,"githubUrl":"https://github.com/gitlabhq/gitlabhq/blob/55ee20384a1f55cb0e362dee1d07149613b1b9bf/app/graphql/mutations/work_items/update.rb#L150-L186","documentation":"Thrown by `workItemUpdate`'s `extract_task_list_toggle!` when a `taskListToggle` input is present in the description widget but `Feature.disabled?(:work_items_task_list_toggle, work_item.resource_parent)` is true. The task-list toggle feature is rollout-gated per project/group; until the flag is enabled for the item's `resource_parent`, the input is rejected.","triggerScenarios":"Sending `workItemUpdate(id: gid, descriptionWidget: { taskListToggle: { ... } })` for an item whose project/group does not have the `work_items_task_list_toggle` feature flag enabled.","commonSituations":"Frontend shipped ahead of the flag rollout; self-managed instances where the flag is off by default; flag enabled on some groups but the item lives in another namespace; stale flag state after a rollout rollback.","solutions":["Remove `taskListToggle` and update the description text directly (rewriting the markdown checkbox) until the flag is enabled.","Ask an admin to enable the flag: `Feature.enable(:work_items_task_list_toggle)` or scoped to the project's group.","Gate the UI checkbox interaction on the flag's availability before building the mutation."],"exampleFix":"# before\nworkItemUpdate(id: gid, descriptionWidget: { taskListToggle: { checked: true, lineSource: \"- [ ] a\", lineSourcepos: 1 } })\n# after (flag disabled path)\nworkItemUpdate(id: gid, descriptionWidget: { description: \"- [x] a\" })","handlingStrategy":"validation","validationCode":"# Send taskListToggle only when the feature is available for the item's parent:\nquery { project(fullPath: $path) { ... } }\n# In-app: gate the checkbox on the client feature check tied to work_items_task_list_toggle;\n# otherwise fall back:\nworkItemUpdate(id: gid, descriptionWidget: { description: toggled_markdown })","typeGuard":null,"tryCatchPattern":"When the response errors array contains 'work_items_task_list_toggle feature flag is disabled', retry once with the plain description rewrite instead of the taskListToggle input.","preventionTips":["Gate checkbox interactions on the flag before building the mutation.","On self-managed, confirm the flag is enabled for the project/group before shipping UI that depends on it.","Keep a description-rewrite fallback path for the toggle."],"tags":["graphql","work-items","task-list","feature-flag","gitlab"],"backgroundTag":"feature-flag-disabled","analyzedSha":"55ee20384a1f55cb0e362dee1d07149613b1b9bf","analyzedAt":"2026-08-21T14:22:27.782Z","schemaVersion":2},"datasetVersion":"2026-08-21T18:17:14.833Z"}