{"record":{"id":"1ef7071c9b7d3d53","repo":"usebruno/bruno","slug":"migration-aborted-parseerrors-length-file-s","errorCode":null,"errorMessage":"Migration aborted — ${parseErrors.length} file(s) failed to parse:\n${parseErrors.join('\\n')}","messagePattern":"Migration aborted — (.+?) file\\(s\\) failed to parse:\n(.+?)","errorType":"exception","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"packages/bruno-electron/src/ipc/yml-migration.js","lineNumber":141,"sourceCode":"          const requestData = await parseRequestViaWorker(bruContent, { format: 'bru' });\n          ymlPath = bruFilePath.replace(/\\.bru$/, '.yml');\n          ymlContent = await stringifyRequestViaWorker(requestData, { format: 'yml' });\n        }\n\n        checkCancelled();\n        conversionPlan.push({ ymlPath, ymlContent });\n        tabPathMap[bruFilePath] = ymlPath;\n      } catch (parseError) {\n        if (parseError?.message === MIGRATION_CANCELLED_MESSAGE) {\n          throw parseError;\n        }\n        parseErrors.push(`${bruFilePath}: ${parseError.message}`);\n      }\n      emitProgress('parsing', i + 1, bruFiles.length);\n    }\n\n    if (parseErrors.length > 0) {\n      throw new Error(`Migration aborted — ${parseErrors.length} file(s) failed to parse:\\n${parseErrors.join('\\n')}`);\n    }\n\n    const collisions = conversionPlan\n      .map(({ ymlPath }) => ymlPath)\n      .filter((ymlPath) => fs.existsSync(ymlPath));\n    if (fs.existsSync(ocYmlPath)) {\n      collisions.push(ocYmlPath);\n    }\n    if (collisions.length > 0) {\n      throw new Error(`Migration aborted — target yml file(s) already exist:\\n${collisions.join('\\n')}`);\n    }\n\n    // Phase 2: write the converted yml files\n    const totalWrites = conversionPlan.length + 1;\n    for (let i = 0; i < conversionPlan.length; i++) {\n      checkCancelled();\n      const { ymlPath, ymlContent } = conversionPlan[i];\n      await writeFile(ymlPath, ymlContent);","sourceCodeStart":123,"sourceCodeEnd":159,"githubUrl":"https://github.com/usebruno/bruno/blob/9bdd81c7bdc57006e5f5ebffb79321a8d979f712/packages/bruno-electron/src/ipc/yml-migration.js#L123-L159","documentation":"Error \"Migration aborted — ${parseErrors.length} file(s) failed to parse:\n${parseErrors.join('\\n')}\" thrown in usebruno/bruno.","triggerScenarios":"Thrown at packages/bruno-electron/src/ipc/yml-migration.js:141 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Fix the listed files' syntax so they parse, then re-run the migration.","Exclude or repair malformed bru files before migrating."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"9bdd81c7bdc57006e5f5ebffb79321a8d979f712","analyzedAt":"2026-08-13T04:09:25.751Z","schemaVersion":2},"datasetVersion":"2026-08-13T04:17:16.726Z"}