You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by "davsclaus (via GitHub)" <gi...@apache.org> on 2026/10/05 18:24:39 UTC

[PR] CAMEL-25358: camel-jbang - Log tab: Shift+F8 (fix with AI) on an ERROR on the screen [camel]

davsclaus opened a new pull request, #27387:
URL: https://github.com/apache/camel/pull/27387

   https://issues.apache.org/jira/browse/CAMEL-25358 — **stacked on #27386**, review that one first. Base: `fix/CAMEL-25358`.
   
   ## Why
   
   Looking at the log and seeing an ERROR is the most natural moment to ask for help. #27386 brought *Shift+F8* (fix with AI) to failing lines in the Source editor and to the Errors tab; this does the same for the Log tab.
   
   ## What
   
   - **Shift+F8 in the Log tab** asks about the ERROR on the screen, including one whose stack trace is on the screen but whose first line is not.
     - **Failed exchange:** Camel's ERROR has a Message History whose last row is the step that failed (`orders.camel.yaml:34  billing/throwException2`), so the AI is asked to fix that line of the route, with the same question as #27386.
     - **`log` EIP with `loggingLevel: ERROR`:** in dev mode the logger is named after the source location, so it maps to that line too.
     - **Any other ERROR:** the AI is asked to explain it (ERROR line, exception, up to three `Caused by:`) and fix it when the cause is in the project (`AiFixPrompt.ofLogError`, `AskAi.explainLogError`).
   - **Several different ERRORs on the screen:** a pick list comes up, newest first. The same error repeated (ids and numbers masked) is listed once with its count. With none on screen, a hint says to scroll to one, or use F8.
   - **Fix: follow mode with word wrap.** The view took the last N entries by count, so wrapped lines (the Message History table) pushed the newest entries below the screen and the log looked frozen. It now shows the entries that fit when wrapped, newest last, and *Shift+F8* sees exactly the entries on the screen.
   - **Docs:** the observe page and the F1 help of the Log and Errors tabs, with a screenshot.
   
   ![Shift+F8 in the Log tab with two different ERRORs on the screen](https://github.com/apache/camel/raw/fix/CAMEL-25358-log-tab/docs/user-manual/modules/ROOT/images/jbang/camel-tui-log-fix-with-ai-pick.png)
   
   ## Tests
   
   - New `LogErrorsTest` (6 tests), built from the log lines Camel writes for a failed exchange: source line and exception, the same error counted once with different ones newest first, a stack trace belonging to the ERROR above the screen, a log EIP error mapped through its logger, no ERROR on screen, and the question.
   - `LogTabRenderTest`: wrapped-row counting, the newest line visible when following with word wrap (fails without the fix), and the pick list rendering.
   - Whole `camel-jbang-plugin-tui` module: 1741 tests pass.
   - Checked in the running TUI against an app with a `throwException` route, a `direct:` endpoint no route consumes, and a `log` at ERROR level; the screenshot is from that run.
   
   _Claude Code on behalf of davsclaus_
   
   🤖 Generated with [Claude Code](https://claude.com/claude-code)
   
   https://claude.ai/code/session_01DDRLJAyf8cDXSg8iX785My


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@camel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] CAMEL-25358: camel-jbang - Log tab: Shift+F8 (fix with AI) on an ERROR on the screen [camel]

Posted by "davsclaus (via GitHub)" <gi...@apache.org>.
davsclaus closed pull request #27387: CAMEL-25358: camel-jbang - Log tab: Shift+F8 (fix with AI) on an ERROR on the screen
URL: https://github.com/apache/camel/pull/27387


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@camel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] CAMEL-25358: camel-jbang - Log tab: Shift+F8 (fix with AI) on an ERROR on the screen [camel]

Posted by "davsclaus (via GitHub)" <gi...@apache.org>.
davsclaus commented on PR #27387:
URL: https://github.com/apache/camel/pull/27387#issuecomment-6009871063

   Superseded by #27398 (rebased onto main after #27386 was merged; this PR closed when its stacked base branch was deleted).
   
   _Claude Code on behalf of davsclaus_


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@camel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] CAMEL-25358: camel-jbang - Log tab: Shift+F8 (fix with AI) on an ERROR on the screen [camel]

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #27387:
URL: https://github.com/apache/camel/pull/27387#issuecomment-6000561689

   :star2: Thank you for your contribution to the Apache Camel project! :star2:
     :robot: CI automation will test this PR automatically.
   
     :camel: Apache Camel Committers, please review the following items:
   
     * First-time contributors **require MANUAL approval** for the GitHub Actions to run
     * You can use the command `/component-test (camel-)component-name1 (camel-)component-name2..` to request a test from the test bot although they are normally detected and executed by CI.
     * You can label PRs using `skip-tests` and `test-dependents` to fine-tune the checks executed by this PR.
     * Build and test logs are available in the summary page. **Only** [Apache Camel committers](https://camel.apache.org/community/team/#committers) have access to the summary.
     
     :warning: Be careful when sharing logs. Review their contents before sharing them publicly.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@camel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org