@alibaba-group/open-code-review 1.11.4 → 1.11.6

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/README.ja-JP.md CHANGED
@@ -182,7 +182,7 @@ ocr delegate rule src/main.go src/handler.go
182
182
  - [デフォルト(OCR が管理)](https://open-codereview.ai/docs/configuration) — OCR が設定済みの LLM を使用してレビューを実行
183
183
  - [デリゲートモード](https://open-codereview.ai/docs/delegate) — コーディングエージェントが自身の LLM を使用してレビューを実行。OCR の API キーは不要
184
184
  - [CI/CD 連携](https://open-codereview.ai/docs/cicd) — GitHub Actions、GitLab CI、GitFlic CI、Gerrit との統合
185
- - [セッションビューアー](https://open-codereview.ai/docs/viewer) — ブラウザでレビューセッションを閲覧・再生
185
+ - [セッションビューアー](https://open-codereview.ai/docs/viewer) — ブラウザでレビューセッションを閲覧・再生、コメントを修正済み/無視としてマークして非表示にできます
186
186
  - [テレメトリー](https://open-codereview.ai/docs/telemetry) — 可観測性のためのOpenTelemetry統合
187
187
  - [FAQ](https://open-codereview.ai/docs/faq) — よくある質問とトラブルシューティング
188
188
 
package/README.ko-KR.md CHANGED
@@ -182,7 +182,7 @@ ocr delegate rule src/main.go src/handler.go
182
182
  - [기본 모드(OCR 관리)](https://open-codereview.ai/docs/configuration) — OCR이 설정된 LLM을 사용해 리뷰 수행
183
183
  - [위임 모드](https://open-codereview.ai/docs/delegate) — 코딩 에이전트가 자체 LLM을 사용해 리뷰 수행; OCR API 키 불필요
184
184
  - [CI/CD 연동](https://open-codereview.ai/docs/cicd) — GitHub Actions, GitLab CI, GitFlic CI, Gerrit 통합
185
- - [세션 뷰어](https://open-codereview.ai/docs/viewer) — 브라우저에서 리뷰 세션 탐색 및 재생
185
+ - [세션 뷰어](https://open-codereview.ai/docs/viewer) — 브라우저에서 리뷰 세션 탐색 및 재생, 코멘트를 수정됨/무시됨으로 표시하고 숨길 수 있습니다
186
186
  - [텔레메트리](https://open-codereview.ai/docs/telemetry) — 관측성을 위한 OpenTelemetry 통합
187
187
  - [FAQ](https://open-codereview.ai/docs/faq) — 자주 묻는 질문과 문제 해결
188
188
 
package/README.md CHANGED
@@ -182,7 +182,7 @@ Full documentation lives at **[open-codereview.ai/docs](https://open-codereview.
182
182
  - [Default (OCR-managed)](https://open-codereview.ai/docs/configuration) — OCR runs the review using its configured LLM
183
183
  - [Delegation Mode](https://open-codereview.ai/docs/delegate) — your coding agent runs the review using its own LLM; no OCR API key required
184
184
  - [CI/CD Integration](https://open-codereview.ai/docs/cicd) — GitHub Actions, GitLab CI, GitFlic CI, and Gerrit integration
185
- - [Session Viewer](https://open-codereview.ai/docs/viewer) — browse and replay review sessions in browser
185
+ - [Session Viewer](https://open-codereview.ai/docs/viewer) — browse and replay review sessions in browser, mark comments as fixed or ignored and hide them while you work through the findings
186
186
  - [Telemetry](https://open-codereview.ai/docs/telemetry) — OpenTelemetry integration for observability
187
187
  - [FAQ](https://open-codereview.ai/docs/faq) — common questions and troubleshooting
188
188
 
package/README.ru-RU.md CHANGED
@@ -182,7 +182,7 @@ ocr delegate rule src/main.go src/handler.go
182
182
  - [По умолчанию (под управлением OCR)](https://open-codereview.ai/docs/configuration) — OCR выполняет ревью с помощью настроенной LLM
183
183
  - [Режим делегирования](https://open-codereview.ai/docs/delegate) — кодинг-агент выполняет ревью с помощью собственной LLM; API-ключ для OCR не требуется
184
184
  - [Интеграция с CI/CD](https://open-codereview.ai/docs/cicd) — GitHub Actions, GitLab CI, GitFlic CI и Gerrit
185
- - [Просмотр сессий](https://open-codereview.ai/docs/viewer) — просмотр и воспроизведение сессий ревью в браузере
185
+ - [Просмотр сессий](https://open-codereview.ai/docs/viewer) — просмотр и воспроизведение сессий ревью в браузере, отметка комментариев как исправленных/игнорируемых и их скрытие
186
186
  - [Телеметрия](https://open-codereview.ai/docs/telemetry) — интеграция с OpenTelemetry для наблюдаемости
187
187
  - [FAQ](https://open-codereview.ai/docs/faq) — частые вопросы и устранение неполадок
188
188
 
package/README.zh-CN.md CHANGED
@@ -182,7 +182,7 @@ ocr delegate rule src/main.go src/handler.go
182
182
  - [默认模式(OCR 驱动)](https://open-codereview.ai/docs/configuration) —— OCR 使用其已配置的 LLM 执行评审
183
183
  - [委托模式](https://open-codereview.ai/docs/delegate) —— 编程 Agent 使用自身的 LLM 执行评审;无需 OCR API Key
184
184
  - [CI/CD 集成](https://open-codereview.ai/docs/cicd) —— 支持 GitHub Actions、GitLab CI、GitFlic CI、Gerrit 集成
185
- - [会话查看器](https://open-codereview.ai/docs/viewer) —— 在浏览器中浏览和回放评审会话
185
+ - [会话查看器](https://open-codereview.ai/docs/viewer) —— 在浏览器中浏览和回放评审会话,可将评审意见标记为已修复/已忽略并在处理时隐藏
186
186
  - [遥测](https://open-codereview.ai/docs/telemetry) —— OpenTelemetry 集成,用于可观测性
187
187
  - [FAQ](https://open-codereview.ai/docs/faq) —— 常见问题与故障排查
188
188
 
package/bin/ocr.js CHANGED
@@ -5,7 +5,7 @@
5
5
 
6
6
  "use strict";
7
7
 
8
- const { spawnSync, spawn } = require("child_process");
8
+ const { spawn } = require("child_process");
9
9
  const path = require("path");
10
10
  const fs = require("fs");
11
11
  const os = require("os");
@@ -25,7 +25,39 @@ function launcherExitCode(result) {
25
25
  return result.status ?? (result.error ? 1 : 0);
26
26
  }
27
27
 
28
- module.exports = { launcherExitCode };
28
+ // Returns a signal handler that forwards the signal to a child process.
29
+ function forwardSignal(child, signal) {
30
+ return () => {
31
+ child.kill(signal);
32
+ };
33
+ }
34
+
35
+ function installSignalHandlers(child, platform, signalTarget) {
36
+ const handlers = [];
37
+ function add(signal, handler) {
38
+ handlers.push([signal, handler]);
39
+ signalTarget.on(signal, handler);
40
+ }
41
+
42
+ // Windows sends console Ctrl+C to both attached processes. Keep the wrapper
43
+ // alive so it can wait for the binary, but do not call child.kill("SIGINT"):
44
+ // Node maps that operation to an abrupt TerminateProcess call on Windows.
45
+ if (platform === "win32") {
46
+ add("SIGINT", () => {});
47
+ } else {
48
+ for (const signal of ["SIGINT", "SIGTERM"]) {
49
+ add(signal, forwardSignal(child, signal));
50
+ }
51
+ }
52
+
53
+ return () => {
54
+ for (const [signal, handler] of handlers) {
55
+ signalTarget.removeListener(signal, handler);
56
+ }
57
+ };
58
+ }
59
+
60
+ module.exports = { launcherExitCode, forwardSignal, installSignalHandlers };
29
61
 
30
62
  if (require.main !== module) {
31
63
  // Required as a module (tests); the launcher body below must not run.
@@ -77,9 +109,33 @@ if (!process.env.OCR_NO_UPDATE) {
77
109
  }
78
110
  }
79
111
 
80
- const result = spawnSync(binaryPath, process.argv.slice(2), {
112
+ const child = spawn(binaryPath, process.argv.slice(2), {
81
113
  stdio: "inherit",
82
114
  env: process.env,
83
115
  });
84
116
 
85
- process.exit(launcherExitCode(result));
117
+ const removeSignalHandlers = installSignalHandlers(
118
+ child,
119
+ process.platform,
120
+ process
121
+ );
122
+
123
+ let settled = false;
124
+ function settle(result) {
125
+ if (settled) return;
126
+ settled = true;
127
+ removeSignalHandlers();
128
+ process.exitCode = launcherExitCode(result);
129
+ }
130
+
131
+ // Spawn failures surface through "error", not "close" alone. Setting
132
+ // exitCode lets a piped diagnostic drain before the wrapper terminates.
133
+ child.on("error", (err) => {
134
+ console.error(`[ERROR] Failed to start ${binaryPath}: ${err.message}`);
135
+ settle({ error: err });
136
+ });
137
+
138
+ // Wait for child to exit and propagate its exit status
139
+ child.on("close", (code, signal) => {
140
+ settle({ status: code, signal: signal });
141
+ });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@alibaba-group/open-code-review",
3
- "version": "1.11.4",
3
+ "version": "1.11.6",
4
4
  "description": "OpenCodeReview CLI — AI-powered code review tool",
5
5
  "bin": {
6
6
  "ocr": "bin/ocr.js"
@@ -31,12 +31,12 @@
31
31
  "checksumPattern": "https://github.com/alibaba/open-code-review/releases/download/v{version}/sha256sum.txt"
32
32
  },
33
33
  "optionalDependencies": {
34
- "@alibaba-group/ocr-darwin-arm64": "1.11.4",
35
- "@alibaba-group/ocr-darwin-x64": "1.11.4",
36
- "@alibaba-group/ocr-linux-arm64": "1.11.4",
37
- "@alibaba-group/ocr-linux-x64": "1.11.4",
38
- "@alibaba-group/ocr-win32-arm64": "1.11.4",
39
- "@alibaba-group/ocr-win32-x64": "1.11.4"
34
+ "@alibaba-group/ocr-darwin-arm64": "1.11.6",
35
+ "@alibaba-group/ocr-darwin-x64": "1.11.6",
36
+ "@alibaba-group/ocr-linux-arm64": "1.11.6",
37
+ "@alibaba-group/ocr-linux-x64": "1.11.6",
38
+ "@alibaba-group/ocr-win32-arm64": "1.11.6",
39
+ "@alibaba-group/ocr-win32-x64": "1.11.6"
40
40
  },
41
41
  "engines": {
42
42
  "node": ">=14"