diff --git a/.github/workflows/pr.yml b/.github/workflows/pr.yml index b180456f..3d3097ad 100644 --- a/.github/workflows/pr.yml +++ b/.github/workflows/pr.yml @@ -20,14 +20,17 @@ jobs: OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }} steps: - - uses: actions/checkout@v4 + - name: Checkout code + uses: actions/checkout@v4 + with: + fetch-depth: 0 - - uses: actions/setup-node@v3 + - uses: actions/setup-node@v4 with: node-version: 20 - name: Setup bun - uses: oven-sh/setup-bun@v1 + uses: oven-sh/setup-bun@v2 with: bun-version: latest @@ -50,4 +53,4 @@ jobs: run: bun run start:review --ci=github --model=gpt-4o --debug - name: Run prompt tests - run: bun run dev:test + run: bun run start:test diff --git a/package.json b/package.json index 03cc24c6..7ce87f9d 100644 --- a/package.json +++ b/package.json @@ -45,6 +45,7 @@ "gpt3", "openai", "gpt4", + "gpt4o", "vertexai", "huggingface", "ai", diff --git a/src/common/git/getFilesWithChanges.ts b/src/common/git/getFilesWithChanges.ts index 5fc1d732..7f2917cd 100644 --- a/src/common/git/getFilesWithChanges.ts +++ b/src/common/git/getFilesWithChanges.ts @@ -19,11 +19,14 @@ export const getFilesWithChanges = async (isCi: string | undefined): Promise { const fileContent = await readFile(fileName, "utf8") const changedLines = await getChangedFileLines(isCi, fileName) + logger.debug(`Changed lines for file: ${fileName}. Got ${changedLines.length} lines.`) return { fileName, fileContent, changedLines } }) ) + logger.debug(`Found ${files.length} files with changes.`) + return files } catch (error) { throw new Error(`Failed to get files with changes: ${error}`)