deprecate-workflow-node

Deprecates FastGPT workflow nodes while preserving backward compatibility for existing workflows.

29.5k|7.3k|Updated Feb 23, 2023
One-click install
npx skills add https://github.com/labring/FastGPT --skill deprecate-workflow-node
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: deprecate-workflow-node
Source: https://github.com/labring/FastGPT/tree/main/.agents/skills/core/workflow/deprecate_workflow_node
Command: npx skills add https://github.com/labring/FastGPT --skill deprecate-workflow-node

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Removing a workflow node outright breaks existing user workflows that still reference it. This Skill standardizes the deprecation process in the FastGPT codebase so a node is hidden from the template panel for new workflows while old workflows continue to load, render, and run.

Core Features & Use Cases

  • Guided deprecation checklist: Covers every touchpoint including template definitions, dispatchers, constants files, callback maps, and UI references.
  • Node-level status badges: Adds status: PluginStatusEnum.SoonOffline so deprecated nodes show a yellow "coming offline" badge with replacement tooltip in the canvas.
  • Anti-pattern guardrails: Explicitly prevents deleting enum values, removing entries from moduleTemplatesFlat or the dispatch callbackMap, and deleting i18n keys.
  • Use Case: When the team decides to retire the LoopNode or RunAppModule node, follow this Skill to move files into abandoned/ directories, update constants, and verify old workflows still run.

Quick Start

Ask the AI to deprecate the workflow node named LoopNode while keeping existing workflows functional.

Frequently Asked Questions about deprecate-workflow-node

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I deprecate a workflow node in FastGPT without breaking existing workflows?

Move the node's template and dispatcher files into the abandoned directories, remove it from the systemNodes list, but keep it in moduleTemplatesFlat and the dispatch callbackMap. Add status PluginStatusEnum.SoonOffline to show a deprecation badge on existing nodes.

What is the difference between node-level deprecation and field-level deprecated flags in FastGPT?

Node-level deprecation uses the template status field to retire an entire node while keeping it runnable. Field-level deprecated flags on FlowNodeInputItemType or FlowNodeOutputItemType retire individual inputs or outputs while the node itself stays active.

Can I delete the FlowNodeTypeEnum value when deprecating a node?

No. Existing workflow JSON still references the enum value, so deleting it breaks loading and rendering of old workflows. The enum, i18n keys, React node components, and callbackMap entries must all be retained.

Why does a deprecated FastGPT node fail to render on the canvas?

Rendering fails if the node was removed from moduleTemplatesFlat or the nodeTypes mapping in Flow/index.tsx. Both must be preserved because the canvas resolves node definitions from moduleTemplatesFlat at load time.

When should I use SoonOffline versus Offline status for a FastGPT node?

Use SoonOffline when the node is deprecated but still runs, which shows a yellow badge prompting replacement. Use Offline only when the node is changed to throw an error at runtime, displaying a red badge warning that it interrupts execution.