workflow-ai 1.0.29 → 1.0.30

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/src/runner.mjs +6 -2
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "workflow-ai",
3
- "version": "1.0.29",
3
+ "version": "1.0.30",
4
4
  "description": "AI Agent Workflow Coordinator — kanban-based pipeline for AI coding agents",
5
5
  "type": "module",
6
6
  "bin": {
package/src/runner.mjs CHANGED
@@ -765,9 +765,13 @@ class StageExecutor {
765
765
  let agentId = stage.agent || this.pipeline.default_agent;
766
766
  const attempt = (stage.counter && this.counters[stage.counter]) || 0;
767
767
 
768
- if (attempt <= 1 && stage.agent_by_type && this.context.task_type) {
768
+ // Фоллбэк: если task_type не задан, вычисляем из префикса ticket_id (PMA-005 → pma)
769
+ const taskType = this.context.task_type
770
+ || (this.context.ticket_id && this.context.ticket_id.split('-')[0].toLowerCase())
771
+ || null;
772
+
773
+ if (attempt <= 1 && stage.agent_by_type && taskType) {
769
774
  // Первая попытка: выбор по типу задачи
770
- const taskType = this.context.task_type;
771
775
  if (stage.agent_by_type[taskType]) {
772
776
  agentId = stage.agent_by_type[taskType];
773
777
  if (this.logger) {