Skip to content

fix: remove debug print statement in bot health check endpoint - #1308

Closed
sjhddh wants to merge 1 commit into
volcengine:mainfrom
sjhddh:fix/remove-debug-print-bot-health
Closed

sjhddh wants to merge 1 commit into
volcengine:mainfrom
sjhddh:fix/remove-debug-print-bot-health

Conversation

@sjhddh

@sjhddh sjhddh commented Apr 8, 2026

Copy link
Copy Markdown
Contributor

Summary

Removes a leftover print() debug statement introduced in #1285 (merged 2026-04-07) when the bot proxy router was added.

The offending line in openviking/server/routers/bot.py (was line 53):

print(f"url={f'{bot_url}/bot/v1/health'}")

This writes the internal bot service URL to stdout on every health check request. Every other log call in this file uses the logger object — this print() was clearly a debug leftover that slipped through.

Change

Single line deletion — no behavior change, no functional impact.

-            print(f"url={f'{bot_url}/bot/v1/health'}")
             # Forward to Vikingbot OpenAPIChannel health endpoint

@CLAassistant

CLAassistant commented Apr 8, 2026 •

Copy link
Copy Markdown

CLA assistant check
All committers have signed the CLA.

The catch-all exception handler was returning str(exc) directly in the
API response, leaking internal filesystem paths, backend error messages,
and configuration details to clients (information disclosure).

- Replace str(exc) with a static "Internal server error" message
- Upgrade logger.warning to logger.exception so the full traceback is
  preserved in server logs for debugging

Closes volcengine#1233
@sjhddh
sjhddh force-pushed the fix/remove-debug-print-bot-health branch from 69cb3be to dc815eb Compare April 8, 2026 17:05
@github-actions

github-actions Bot commented Apr 8, 2026

Copy link
Copy Markdown
Contributor

PR Reviewer Guide 🔍

Here are some key observations to aid the review process:

🎫 Ticket compliance analysis ❌

1285 - Not compliant

Non-compliant requirements:

  • Add lark-oapi
⏱️ Estimated effort to review: 1 🔵⚪⚪⚪⚪
🏅 Score: 90
🧪 No relevant tests
🔒 No security concerns identified
✅ No TODO sections
🔀 No multiple PR themes
⚡ No major issues detected

@github-actions

github-actions Bot commented Apr 8, 2026

Copy link
Copy Markdown
Contributor

PR Code Suggestions ✨

No code suggestions found for the PR.

@qin-ctx

qin-ctx commented May 29, 2026

Copy link
Copy Markdown
Collaborator

Thanks for the cleanup.

I am going to close this PR because the debug print it removes is no longer present on current main; the bot health-check code has changed since this branch was opened, so there is no longer a patch to apply here.

If another debug print or noisy log remains in the current bot path, please open a new focused cleanup PR and we can take it from there.

@qin-ctx qin-ctx closed this May 29, 2026
@github-project-automation github-project-automation Bot moved this from Backlog to Done in OpenViking project May 29, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

3 participants