Skip to content

Commit f7d16e2

Browse files
authored
Merge pull request #3 from ffp5/update_kilocode_last_commits
Update to the lastest Kilocode commit
2 parents 0a495d7 + 0f787ec commit f7d16e2

File tree

355 files changed

+20159
-11222
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

355 files changed

+20159
-11222
lines changed

.dockerignore

Lines changed: 77 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,91 @@
1-
# Build artifacts
1+
# git
2+
.git
3+
4+
# build artifacts
25
bin/
3-
!bin/roo-code-latest.vsix
46
dist/
57
**/dist/
68
out/
79
**/out/
10+
src/webview-ui/
811

9-
# Dependencies
12+
# dependencies
1013
node_modules/
1114
**/node_modules/
1215

13-
# Test and development files
16+
# testing
1417
coverage/
1518
**/.vscode-test/
19+
**/mock/
1620

21+
# devtools
1722
knip.json
1823
.husky/
24+
25+
# monorepo
26+
.turbo/
27+
**/.turbo/
28+
29+
# next.js
30+
**/.next/
31+
.vercel
32+
33+
# Ignore common development files
34+
node_modules
35+
.git
36+
.gitignore
37+
.dockerignore
38+
.env*
39+
.vscode
40+
.idea
41+
42+
# Ignore build artifacts
43+
dist
44+
build
45+
*.log
46+
*.tmp
47+
.cache
48+
coverage
49+
50+
# Ignore OS files
51+
.DS_Store
52+
Thumbs.db
53+
54+
# Ignore test files
55+
__tests__
56+
*.test.js
57+
*.spec.js
58+
*.test.ts
59+
*.spec.ts
60+
61+
# Ignore development config files
62+
.eslintrc*
63+
.prettierrc*
64+
jest.config*
65+
66+
# Ignore most directories except what we need for the build
67+
apps/
68+
evals/
69+
webview-ui/node_modules
70+
src/node_modules
71+
72+
# Keep essential files for the build
73+
!README.md
74+
!CHANGELOG.md
75+
!package.json
76+
!pnpm-lock.yaml
77+
!pnpm-workspace.yaml
78+
!scripts/bootstrap.mjs
79+
!apps/web-evals/
80+
!src/
81+
!webview-ui/
82+
!packages/evals/.docker/entrypoints/runner.sh
83+
!packages/build/
84+
!packages/cloud/
85+
!packages/config-eslint/
86+
!packages/config-typescript/
87+
!packages/evals/
88+
!packages/ipc/
89+
!packages/telemetry/
90+
!packages/types/
91+
!locales/

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,3 +42,4 @@ logs
4242
# IntelliJ and Qodo plugin folders
4343
.idea/
4444
.qodo/
45+
.vercel

.vscode/extensions.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
"esbenp.prettier-vscode",
77
"csstools.postcss",
88
"bradlc.vscode-tailwindcss",
9-
"connor4312.esbuild-problem-matchers"
9+
"connor4312.esbuild-problem-matchers",
10+
"yoavbls.pretty-ts-errors"
1011
]
1112
}

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
# kilo-code
22

3+
## [v4.34.0]
4+
5+
### Minor Changes
6+
7+
- [#636](https://github.com/Kilo-Org/kilocode/pull/636) [`6193029`](https://github.com/Kilo-Org/kilocode/commit/6193029fb1d5e5ec09dd57acb9547179ff01c2b1) Thanks [@kevinvandijk](https://github.com/kevinvandijk)! - Include changes from Roo Code v3.19.4
8+
39
## [v4.33.2]
410

511
### Patch Changes

MONOREPO.md

Lines changed: 33 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,9 +34,40 @@ To fully stress the monorepo setup, run the following:
3434
pnpm clean && pnpm lint
3535
pnpm clean && pnpm check-types
3636
pnpm clean && pnpm test
37-
pnpm clean && pnpm bundle
3837
pnpm clean && pnpm build
38+
pnpm clean && pnpm bundle
39+
pnpm clean && pnpm bundle:nightly
40+
3941
pnpm clean && pnpm npx turbo watch:bundle
4042
pnpm clean && pnpm npx turbo watch:tsc
41-
cd apps/vscode-e2e && pnpm test:ci
43+
44+
pnpm --filter @roo-code/vscode-e2e test:ci
45+
46+
pnpm clean && \
47+
pnpm vsix -- --out ../bin/roo-code.vsix && \
48+
code --install-extension bin/roo-code.vsix
49+
50+
pnpm clean && \
51+
pnpm vsix:nightly -- --out ../../../bin/roo-code-nightly.vsix && \
52+
code --install-extension bin/roo-code-nightly.vsix
4253
```
54+
55+
### Turborepo
56+
57+
Note that this excludes the `build` task for next.js apps (@roo-code/web-\*).
58+
59+
Tasks: `build` -> `bundle` -> `vsix`
60+
61+
build:
62+
63+
- `@roo-code/build` [input: src, package.json, tsconfig.json | output: dist]
64+
- `@roo-code/types` [input: src, package.json, tsconfig.json, tsup.config.ts | output: dist]
65+
- `@roo-code/webview-ui` [input: src, package.json, tsconfig.json, vite.config.ts | output: ../src/webview-ui]
66+
67+
bundle:
68+
69+
- `roo-cline` [input: * | output: dist]
70+
71+
vsix:
72+
73+
- `roo-cline` [input: dist | output: bin]

apps/vscode-nightly/esbuild.mjs

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -48,10 +48,9 @@ async function main() {
4848
console.log(`[${name}] buildDir: ${buildDir}`)
4949
console.log(`[${name}] distDir: ${distDir}`)
5050

51-
// Clean build directory before starting new build
52-
if (fs.existsSync(buildDir)) {
53-
console.log(`[${name}] Cleaning build directory: ${buildDir}`)
54-
fs.rmSync(buildDir, { recursive: true, force: true })
51+
if (fs.existsSync(distDir)) {
52+
console.log(`[${name}] Cleaning dist directory: ${distDir}`)
53+
fs.rmSync(distDir, { recursive: true, force: true })
5554
}
5655

5756
/**

apps/vscode-nightly/turbo.json

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
{
2+
"$schema": "https://turbo.build/schema.json",
3+
"extends": ["//"],
4+
"tasks": {
5+
"bundle:nightly": {
6+
"dependsOn": ["^build", "@roo-code/vscode-webview#build:nightly"],
7+
"outputs": ["build/**"]
8+
},
9+
"vsix:nightly": {
10+
"dependsOn": ["bundle:nightly"],
11+
"inputs": ["build/**"],
12+
"outputs": ["../../../bin/**"]
13+
}
14+
}
15+
}
File renamed without changes.

apps/web-docs/README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
TODO

apps/web-evals/.env

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
DATABASE_URL=postgres://postgres:password@localhost:5432/evals_development

apps/web-evals/.gitignore

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
# .env
2+
!.env
3+
4+
# next.js
5+
.next
6+
7+
# typescript
8+
tsconfig.tsbuildinfo
File renamed without changes.

evals/apps/web/eslint.config.mjs renamed to apps/web-evals/eslint.config.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { nextJsConfig } from "@evals/eslint-config/next-js"
1+
import { nextJsConfig } from "@roo-code/config-eslint/next-js"
22

33
/** @type {import("eslint").Linter.Config} */
44
export default [

apps/web-evals/next-env.d.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
/// <reference types="next" />
2+
/// <reference types="next/image-types/global" />
3+
4+
// NOTE: This file should not be edited
5+
// see https://nextjs.org/docs/app/api-reference/config/typescript for more information.

apps/web-evals/next.config.ts

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
import type { NextConfig } from "next"
2+
3+
const nextConfig: NextConfig = {
4+
webpack: (config) => {
5+
config.resolve.extensionAlias = { ".js": [".ts", ".tsx", ".js", ".jsx"] }
6+
return config
7+
},
8+
}
9+
10+
export default nextConfig
Lines changed: 20 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,16 @@
11
{
2-
"name": "@evals/web",
3-
"private": true,
2+
"name": "@roo-code/web-evals",
3+
"version": "0.0.0",
4+
"type": "module",
45
"scripts": {
56
"lint": "next lint",
67
"check-types": "tsc -b",
7-
"dev": "dotenvx run -f ../../.env -- next dev --turbopack",
8+
"dev": "scripts/check-services.sh && next dev --turbopack",
89
"format": "prettier --write src",
910
"build": "next build",
1011
"start": "next start"
1112
},
1213
"dependencies": {
13-
"@evals/db": "workspace:^",
14-
"@evals/ipc": "workspace:^",
15-
"@evals/types": "workspace:^",
1614
"@hookform/resolvers": "^4.1.3",
1715
"@radix-ui/react-alert-dialog": "^1.1.7",
1816
"@radix-ui/react-dialog": "^1.1.6",
@@ -26,33 +24,36 @@
2624
"@radix-ui/react-slot": "^1.1.2",
2725
"@radix-ui/react-tabs": "^1.1.3",
2826
"@radix-ui/react-tooltip": "^1.1.8",
27+
"@roo-code/evals": "workspace:^",
28+
"@roo-code/types": "workspace:^",
2929
"@tanstack/react-query": "^5.69.0",
3030
"class-variance-authority": "^0.7.1",
3131
"clsx": "^2.1.1",
3232
"cmdk": "^1.1.0",
3333
"fuzzysort": "^3.1.0",
34-
"lucide-react": "^0.511.0",
35-
"next": "15.3.3",
34+
"lucide-react": "^0.513.0",
35+
"next": "^15.2.5",
3636
"next-themes": "^0.4.6",
3737
"p-map": "^7.0.3",
38-
"ps-tree": "^1.2.0",
39-
"react": "^19.0.0",
40-
"react-dom": "^19.0.0",
41-
"react-hook-form": "^7.54.2",
38+
"react": "^18.3.1",
39+
"react-dom": "^18.3.1",
40+
"react-hook-form": "^7.57.0",
4241
"react-use": "^17.6.0",
43-
"sonner": "^2.0.2",
44-
"tailwind-merge": "^3.0.2",
42+
"redis": "^5.5.5",
43+
"sonner": "^2.0.5",
44+
"tailwind-merge": "^3.3.0",
4545
"tailwindcss-animate": "^1.0.7",
4646
"vaul": "^1.1.2",
4747
"zod": "^3.24.2"
4848
},
4949
"devDependencies": {
50-
"@evals/eslint-config": "workspace:^",
51-
"@evals/typescript-config": "workspace:^",
50+
"@roo-code/config-eslint": "workspace:^",
51+
"@roo-code/config-typescript": "workspace:^",
5252
"@tailwindcss/postcss": "^4",
5353
"@types/ps-tree": "^1.1.6",
54-
"@types/react": "^19",
55-
"@types/react-dom": "^19",
56-
"tailwindcss": "^4"
54+
"@types/react": "^18.3.23",
55+
"@types/react-dom": "^18.3.5",
56+
"tailwindcss": "^4",
57+
"vitest": "^3.2.1"
5758
}
5859
}
File renamed without changes.

apps/web-evals/public/.gitkeep

Whitespace-only changes.
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
#!/bin/bash
2+
3+
if ! docker info &> /dev/null; then
4+
echo "❌ Docker is not running. Please start Docker Desktop and try again."
5+
exit 1
6+
fi
7+
8+
if ! nc -z localhost 5432 2>/dev/null; then
9+
echo "❌ PostgreSQL is not running on port 5432"
10+
echo "💡 Start it with: pnpm --filter @roo-code/evals db:start"
11+
exit 1
12+
fi
13+
14+
if ! nc -z localhost 6379 2>/dev/null; then
15+
echo "❌ Redis is not running on port 6379"
16+
echo "💡 Start it with: pnpm --filter @roo-code/evals redis:start"
17+
exit 1
18+
fi
19+
20+
echo "✅ All required services are running"
Lines changed: 71 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
import type { NextRequest } from "next/server"
2+
3+
import { taskEventSchema } from "@roo-code/types"
4+
import { findRun } from "@roo-code/evals"
5+
6+
import { SSEStream } from "@/lib/server/sse-stream"
7+
import { redisClient } from "@/lib/server/redis"
8+
9+
export const dynamic = "force-dynamic"
10+
11+
export async function GET(request: NextRequest, { params }: { params: Promise<{ id: string }> }) {
12+
const { id } = await params
13+
const requestId = crypto.randomUUID()
14+
const stream = new SSEStream()
15+
const run = await findRun(Number(id))
16+
const redis = await redisClient()
17+
18+
let isStreamClosed = false
19+
const channelName = `evals:${run.id}`
20+
21+
const onMessage = async (data: string) => {
22+
if (isStreamClosed || stream.isClosed) {
23+
return
24+
}
25+
26+
try {
27+
const taskEvent = taskEventSchema.parse(JSON.parse(data))
28+
// console.log(`[stream#${requestId}] task event -> ${taskEvent.eventName}`)
29+
const writeSuccess = await stream.write(JSON.stringify(taskEvent))
30+
31+
if (!writeSuccess) {
32+
await disconnect()
33+
}
34+
} catch (_error) {
35+
console.error(`[stream#${requestId}] invalid task event:`, data)
36+
}
37+
}
38+
39+
const disconnect = async () => {
40+
if (isStreamClosed) {
41+
return
42+
}
43+
44+
isStreamClosed = true
45+
46+
try {
47+
await redis.unsubscribe(channelName)
48+
console.log(`[stream#${requestId}] unsubscribed from ${channelName}`)
49+
} catch (error) {
50+
console.error(`[stream#${requestId}] error unsubscribing:`, error)
51+
}
52+
53+
try {
54+
await stream.close()
55+
} catch (error) {
56+
console.error(`[stream#${requestId}] error closing stream:`, error)
57+
}
58+
}
59+
60+
await redis.subscribe(channelName, onMessage)
61+
62+
request.signal.addEventListener("abort", () => {
63+
console.log(`[stream#${requestId}] abort`)
64+
65+
disconnect().catch((error) => {
66+
console.error(`[stream#${requestId}] cleanup error:`, error)
67+
})
68+
})
69+
70+
return stream.getResponse()
71+
}

0 commit comments

Comments
 (0)