job51-gitlab-cr-node-jt-1 2.4.10 → 2.5.0
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.
- package/index.js +7 -0
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -77,6 +77,13 @@ class GitLabCodeReviewer {
|
|
|
77
77
|
const tmpFileName = path.join(process.cwd(), fileName);
|
|
78
78
|
|
|
79
79
|
try {
|
|
80
|
+
// 打印 diff 块完整信息(用于调试行号问题)
|
|
81
|
+
debugLog(`========== Diff Block ${blockIndex} 开始 ==========`);
|
|
82
|
+
debugLog(`文件路径:${diffObject.new_path || diffObject.old_path}`);
|
|
83
|
+
debugLog(`line_info: old_start=${diffObject.line_info?.old_start}, old_count=${diffObject.line_info?.old_count}, new_start=${diffObject.line_info?.new_start}, new_count=${diffObject.line_info?.new_count}`);
|
|
84
|
+
debugLog(`diff 内容预览(前 500 字符):${diffObject.diff?.substring(0, 500)}`);
|
|
85
|
+
debugLog(`========== Diff Block ${blockIndex} 结束 ==========`);
|
|
86
|
+
|
|
80
87
|
// 构造包含元数据的 diff 内容
|
|
81
88
|
const diffContentWithMetadata = `=== File Information ===
|
|
82
89
|
New Path: ${diffObject.new_path || 'N/A'}
|