mirror of
https://github.com/QwenLM/qwen-code.git
synced 2026-05-19 16:28:28 +00:00
Some checks failed
Qwen Code CI / Classify PR (push) Waiting to run
Qwen Code CI / Lint (push) Blocked by required conditions
Qwen Code CI / Test (macos-latest, Node 22.x) (push) Blocked by required conditions
Qwen Code CI / Test (ubuntu-latest, Node 22.x) (push) Blocked by required conditions
Qwen Code CI / Test (windows-latest, Node 22.x) (push) Blocked by required conditions
Qwen Code CI / Post Coverage Comment (push) Blocked by required conditions
Qwen Code CI / CodeQL (push) Blocked by required conditions
E2E Tests / E2E Test (Linux) - sandbox:docker (push) Waiting to run
E2E Tests / E2E Test (Linux) - sandbox:none (push) Waiting to run
E2E Tests / E2E Test - macOS (push) Waiting to run
SDK Python / Classify PR (push) Has been cancelled
SDK Python / SDK Python (3.10) (push) Has been cancelled
SDK Python / SDK Python (3.11) (push) Has been cancelled
SDK Python / SDK Python (3.12) (push) Has been cancelled
* revert(deps): downgrade ink 7.0.2 → 6.x to fix Static-remount regression from #3860 PR #3860 upgraded ink 6.2.3 → 7.0.2 with the claim of "no business code changes." In production this turns out to break the TUI: - After `/clear`, the next user message and AI response do not render to the static history area — only the dynamic spinner/input area is visible (#3860 + chore/upgrade-ink-7 branch reproduce this). - After Ctrl+O (TOGGLE_COMPACT_MODE), the screen is cleared and stays blank. - Any `refreshStatic()` call path (auth refresh, model change, render- mode switch, /clear, Ctrl+O) puts the UI into the same "muted" state. Root cause is an ink 7 regression: when `<Static>` is remounted by changing its `key` prop, the new instance's items are never written to stdout. A 30-line minimal repro (pure ink + Static + key++) confirms this independently of qwen-code. Closest upstream issue: vadimdemedes/ink#773 (useLayoutEffect-driven child stripping in <Static>). PR #905 ("Fix dangling staticNode reference") merged into ink 7 fixed the unmount-OOM path but not this remount path. No upstream issue yet matches the "remount loses content" case — we should file one and ship a re-upgrade once it is resolved. Scope of this revert (intentional partial revert of #3860): - ink ^7.0.2 → ^6.2.3 (cli + root hoist) - react / react-dom 19.2.4 pin → ^19.1.0 (cli direct, root overrides removed) - wrap-ansi ^10.0.0 → 9.0.2 (cli direct, root override restored) - react-devtools-core kept at ^6.1.5 (still ink-6 compatible — ink 6.8.0's peerOptional requires >=6.1.2; downgrading to 4.x would re-introduce a conflict) - @vitest/eslint-plugin pin "1.3.4" → "^1.3.4" - "@types/node" override removed (was only needed for ink 7's Node 22 type drift) What this revert keeps: - Node engines >=22 across root / cli / core / sdk / web-templates and the matching Dockerfile / .nvmrc / CI matrix work. PR #1876 followed up by adding Node 24 support to the matrix, and rolling those back would conflict with that work. The visible bug is the ink runtime regression, not the engine bump. - doctorChecks.ts MIN_NODE_MAJOR = 22 (matches engines). - The test gating that #3860 added for ink-7 input throttle (AuthDialog / AskUserQuestionDialog / InputPrompt). With ink 6 these tests would pass un-gated, but leaving the gate in place is harmless and a follow-up can un-gate them. Keeping this revert minimal. Verification (local, ink 6.8.0 single instance): - npm ls ink → single ink@6.8.0 - npm ls react → single react@19.2.4 (kept by vscode-ide-companion workspace pin; ink 6 is fine on 19.2) - npm run typecheck --workspace=packages/cli → clean - AppContainer.test.tsx 61/61 pass - MainContent.test.tsx 6/6 pass - clearCommand.test.ts 13/13 pass Re-upgrade path: once ink ships a fix for the Static-remount regression, redo this upgrade behind the feat/virtual-viewport-on-ink7 branch where the `<Static>` + clearTerminal combo is replaced by an overflowY=hidden self-managed viewport. Generated with AI Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com> * ci(fix): keep wrap-ansi 10 + skip 1 ink-7-specific TableRenderer test The initial revert downgraded wrap-ansi to 9.0.2 (the pre-PR-#3860 state). After rebasing onto current main, PR #4050 (preserve table ANSI color across wrapped lines) brought in a new test ("does not preserve foreground after an explicit foreground reset") whose wrap point depends on ink 7's <Text> wrapping behavior. Two-part fix: 1. Restore wrap-ansi to 10 (cli direct dep). The wrap-ansi version is independent of the ink regression we're reverting — wrap-ansi 10 has no peer-dep tie to ink 7 — and #4050's TableRenderer code on main already assumes wrap-ansi 10. Keeping the wrap-ansi bump removes the root override for wrap-ansi (was forcing all transitives to 9.0.2) so cli's TableRenderer gets the wrap-ansi 10 it expects, while ink 6's transitive wrap-ansi naturally resolves to 9 (its own declared range) — no conflict. 2. Skip the one new test that asserts a specific wrap position. The other assertions in that test (foreground cleared, equal visible widths) still pass on ink 6 — only `expectWrappedContinuation` is ink-7-specific. The sibling test 'does not preserve foreground after an explicit reset' (using \\u001b[0m instead of \\u001b[39m) still passes unmodified on ink 6, so the ANSI-handling logic itself is verified end-to-end. The TODO marker references the re-upgrade path. Local verification: - TableRenderer.test.tsx: 54/54 pass + 1 skipped - AppContainer.test.tsx: 61/61 pass - MainContent.test.tsx: 6/6 pass - clearCommand.test.ts: 13/13 pass - npm run typecheck --workspace=packages/cli: clean - npm ls ink → single ink@6.8.0 - npm ls wrap-ansi → cli direct: 10.0.0; ink 6 transitive: 9.0.2 (no conflict, no override) Generated with AI Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com> --------- Co-authored-by: 秦奇 <gary.gq@alibaba-inc.com> Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
153 lines
7.1 KiB
JSON
153 lines
7.1 KiB
JSON
{
|
|
"name": "@qwen-code/qwen-code",
|
|
"version": "0.15.10",
|
|
"engines": {
|
|
"node": ">=22.0.0"
|
|
},
|
|
"type": "module",
|
|
"workspaces": [
|
|
"packages/*",
|
|
"packages/channels/base",
|
|
"packages/channels/telegram",
|
|
"packages/channels/weixin",
|
|
"packages/channels/dingtalk",
|
|
"packages/channels/plugin-example"
|
|
],
|
|
"repository": {
|
|
"type": "git",
|
|
"url": "git+https://github.com/QwenLM/qwen-code.git"
|
|
},
|
|
"config": {
|
|
"sandboxImageUri": "ghcr.io/qwenlm/qwen-code:0.15.10"
|
|
},
|
|
"scripts": {
|
|
"start": "cross-env node scripts/start.js",
|
|
"dev": "node scripts/dev.js",
|
|
"debug": "cross-env DEBUG=1 node --inspect-brk scripts/start.js",
|
|
"generate": "node scripts/generate-git-commit-info.js",
|
|
"generate:settings-schema": "node --import tsx/esm scripts/generate-settings-schema.ts",
|
|
"build": "node scripts/build.js",
|
|
"build-and-start": "npm run build && npm run start",
|
|
"build:vscode": "node scripts/build_vscode_companion.js",
|
|
"build:all": "npm run build && npm run build:sandbox && npm run build:vscode",
|
|
"build:packages": "npm run build --workspaces",
|
|
"build:sandbox": "node scripts/build_sandbox.js",
|
|
"bundle": "npm run generate && node esbuild.config.js && node scripts/copy_bundle_assets.js",
|
|
"test": "npm run test --workspaces --if-present --parallel",
|
|
"test:ci": "npm run test:ci --workspaces --if-present --parallel && npm run test:scripts",
|
|
"test:scripts": "vitest run --config ./scripts/tests/vitest.config.ts",
|
|
"test:e2e": "cross-env VERBOSE=true KEEP_OUTPUT=true npm run test:integration:sandbox:none",
|
|
"test:integration:all": "npm run test:integration:sandbox:none && npm run test:integration:sandbox:docker && npm run test:integration:sandbox:podman",
|
|
"test:integration:sandbox:none": "cross-env QWEN_SANDBOX=false vitest run --root ./integration-tests",
|
|
"test:integration:sandbox:docker": "cross-env QWEN_SANDBOX=docker npm run build:sandbox && QWEN_SANDBOX=docker vitest run --root ./integration-tests",
|
|
"test:integration:sandbox:podman": "cross-env QWEN_SANDBOX=podman vitest run --root ./integration-tests",
|
|
"test:integration:sdk:sandbox:none": "cross-env QWEN_SANDBOX=false vitest run --root ./integration-tests --poolOptions.threads.maxThreads 2 sdk-typescript",
|
|
"test:integration:sdk:sandbox:docker": "cross-env QWEN_SANDBOX=docker npm run build:sandbox && QWEN_SANDBOX=docker vitest run --root ./integration-tests --poolOptions.threads.maxThreads 2 sdk-typescript",
|
|
"test:sdk:python": "python3 -m pytest -c packages/sdk-python/pyproject.toml packages/sdk-python/tests -q",
|
|
"test:integration:cli:sandbox:none": "cross-env QWEN_SANDBOX=false vitest run --root ./integration-tests cli",
|
|
"test:integration:cli:sandbox:docker": "cross-env QWEN_SANDBOX=docker npm run build:sandbox && QWEN_SANDBOX=docker vitest run --root ./integration-tests cli",
|
|
"test:integration:interactive:sandbox:none": "cross-env QWEN_SANDBOX=false vitest run --root ./integration-tests interactive",
|
|
"test:integration:interactive:sandbox:docker": "cross-env QWEN_SANDBOX=docker npm run build:sandbox && QWEN_SANDBOX=docker vitest run --root ./integration-tests interactive",
|
|
"test:terminal-bench": "cross-env VERBOSE=true KEEP_OUTPUT=true vitest run --config ./vitest.terminal-bench.config.ts --root ./integration-tests",
|
|
"test:terminal-bench:oracle": "cross-env VERBOSE=true KEEP_OUTPUT=true vitest run --config ./vitest.terminal-bench.config.ts --root ./integration-tests -t 'oracle'",
|
|
"test:terminal-bench:qwen": "cross-env VERBOSE=true KEEP_OUTPUT=true vitest run --config ./vitest.terminal-bench.config.ts --root ./integration-tests -t 'qwen'",
|
|
"lint": "eslint . --ext .ts,.tsx && eslint integration-tests",
|
|
"lint:fix": "eslint . --fix && eslint integration-tests --fix",
|
|
"lint:ci": "eslint . --ext .ts,.tsx --max-warnings 0 && eslint integration-tests --max-warnings 0",
|
|
"lint:sdk:python": "python3 -m ruff check --config packages/sdk-python/pyproject.toml packages/sdk-python",
|
|
"lint:all": "node scripts/lint.js",
|
|
"format": "prettier --experimental-cli --write .",
|
|
"typecheck": "npm run typecheck --workspaces --if-present",
|
|
"typecheck:sdk:python": "python3 -m mypy --config-file packages/sdk-python/pyproject.toml packages/sdk-python/src",
|
|
"smoke:sdk:python": "python3 packages/sdk-python/scripts/smoke_real.py",
|
|
"build:sdk:python": "python3 -m build packages/sdk-python",
|
|
"check-i18n": "npm run check-i18n --workspace=packages/cli",
|
|
"preflight": "npm run clean && npm ci && npm run format && npm run lint:ci && npm run build && npm run typecheck && npm run test:ci",
|
|
"prepare": "husky && npm run build && npm run bundle",
|
|
"prepare:package": "node scripts/prepare-package.js",
|
|
"package:standalone": "node scripts/create-standalone-package.js",
|
|
"package:standalone:release": "node scripts/build-standalone-release.js",
|
|
"release:version": "node scripts/version.js",
|
|
"telemetry": "node scripts/telemetry.js",
|
|
"check:lockfile": "node scripts/check-lockfile.js",
|
|
"clean": "node scripts/clean.js",
|
|
"pre-commit": "node scripts/pre-commit.js"
|
|
},
|
|
"overrides": {
|
|
"ansi-regex": "6.2.2",
|
|
"cliui": {
|
|
"wrap-ansi": "7.0.0"
|
|
},
|
|
"baseline-browser-mapping": "^2.9.19",
|
|
"normalize-package-data": "^7.0.1"
|
|
},
|
|
"bin": {
|
|
"qwen": "dist/cli.js"
|
|
},
|
|
"files": [
|
|
"dist/",
|
|
"README.md",
|
|
"LICENSE"
|
|
],
|
|
"devDependencies": {
|
|
"@types/marked": "^5.0.2",
|
|
"@types/mime-types": "^3.0.1",
|
|
"@types/minimatch": "^5.1.2",
|
|
"@types/mock-fs": "^4.13.4",
|
|
"@types/shell-quote": "^1.7.5",
|
|
"@types/uuid": "^10.0.0",
|
|
"@vitest/coverage-v8": "^3.1.1",
|
|
"@vitest/eslint-plugin": "^1.3.4",
|
|
"@xterm/headless": "^5.5.0",
|
|
"@xterm/xterm": "^6.0.0",
|
|
"cross-env": "^7.0.3",
|
|
"esbuild": "^0.25.0",
|
|
"esbuild-plugin-wasm": "^1.1.0",
|
|
"eslint": "^9.24.0",
|
|
"eslint-config-prettier": "^10.1.2",
|
|
"eslint-plugin-import": "^2.31.0",
|
|
"eslint-plugin-license-header": "^0.8.0",
|
|
"eslint-plugin-react": "^7.37.5",
|
|
"eslint-plugin-react-hooks": "^5.2.0",
|
|
"glob": "^10.5.0",
|
|
"globals": "^16.0.0",
|
|
"husky": "^9.1.7",
|
|
"json": "^11.0.0",
|
|
"lint-staged": "^16.1.6",
|
|
"memfs": "^4.42.0",
|
|
"mnemonist": "^0.40.3",
|
|
"mock-fs": "^5.5.0",
|
|
"msw": "^2.10.4",
|
|
"npm-run-all": "^4.1.5",
|
|
"prettier": "^3.5.3",
|
|
"react-devtools-core": "^6.1.5",
|
|
"semver": "^7.7.2",
|
|
"strip-ansi": "^7.1.2",
|
|
"tsx": "^4.20.3",
|
|
"typescript-eslint": "^8.30.1",
|
|
"vitest": "^3.2.4",
|
|
"yargs": "^17.7.2"
|
|
},
|
|
"dependencies": {
|
|
"@testing-library/dom": "^10.4.1",
|
|
"ink": "^6.2.3",
|
|
"simple-git": "^3.28.0"
|
|
},
|
|
"optionalDependencies": {
|
|
"@lydell/node-pty": "1.2.0-beta.10",
|
|
"@lydell/node-pty-darwin-arm64": "1.2.0-beta.10",
|
|
"@lydell/node-pty-darwin-x64": "1.2.0-beta.10",
|
|
"@lydell/node-pty-linux-x64": "1.2.0-beta.10",
|
|
"@lydell/node-pty-win32-arm64": "1.2.0-beta.10",
|
|
"@lydell/node-pty-win32-x64": "1.2.0-beta.10"
|
|
},
|
|
"lint-staged": {
|
|
"*.{js,jsx,ts,tsx}": [
|
|
"prettier --write",
|
|
"eslint --fix --max-warnings 0 --no-warn-ignored"
|
|
],
|
|
"*.{json,md}": [
|
|
"prettier --write"
|
|
]
|
|
}
|
|
}
|