fix: restore migration 014, bump version to 0.2.50, harden pr-review workflow
- Restore 014_create_ai_providers migration and tests missing due to branch diverging from master before PR #34 merged - Bump version from 0.2.10 to 0.2.50 to match master and avoid regression - Trim diff input to 20 KB to prevent Ollama token overflow - Add --max-time 120 to curl to prevent workflow hanging indefinitely
This commit is contained in:
parent
1db1b20762
commit
44584d6302
@ -35,7 +35,7 @@ jobs:
|
||||
env:
|
||||
OLLAMA_URL: http://172.0.1.42:11434
|
||||
run: |
|
||||
DIFF_CONTENT=$(cat /tmp/pr_diff.txt)
|
||||
DIFF_CONTENT=$(head -c 20000 /tmp/pr_diff.txt)
|
||||
PR_TITLE="${{ github.event.pull_request.title }}"
|
||||
PROMPT="Analyze the following code changes for correctness, security issues, and best practices. PR Title: ${PR_TITLE}\n\nDiff:\n${DIFF_CONTENT}\n\nProvide a review with: 1) Summary, 2) Bugs/errors, 3) Security issues, 4) Best practices. Give specific comments with suggested fixes."
|
||||
BODY=$(jq -n \
|
||||
@ -44,7 +44,7 @@ jobs:
|
||||
'{model: $model, messages: [{role: "user", content: $content}], stream: false}')
|
||||
echo "Request body length: ${#BODY} bytes"
|
||||
echo "Calling Ollama API..."
|
||||
HTTP_CODE=$(curl -s -o /tmp/ollama_response.json -w "%{http_code}" \
|
||||
HTTP_CODE=$(curl -s --max-time 120 -o /tmp/ollama_response.json -w "%{http_code}" \
|
||||
-X POST "$OLLAMA_URL/api/chat" \
|
||||
-H "Content-Type: application/json" \
|
||||
-d "$BODY")
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"productName": "Troubleshooting and RCA Assistant",
|
||||
"version": "0.2.49",
|
||||
"version": "0.2.50",
|
||||
"identifier": "com.trcaa.app",
|
||||
"build": {
|
||||
"frontendDist": "../dist",
|
||||
|
||||
Loading…
Reference in New Issue
Block a user