fix(setup-higress): surface HTTP errors instead of silent WARNINGs - #1104
Open
RerankerGuo wants to merge 1 commit into
Open
fix(setup-higress): surface HTTP errors instead of silent WARNINGs#1104RerankerGuo wants to merge 1 commit into
RerankerGuo wants to merge 1 commit into
Conversation
The higress_api helper used to swallow nearly every Console API failure as a log-level WARNING with exit 0: success:false responses, HTML responses (missing </html> variant), HTTP 405 Method Not Allowed, and curl transport errors were all silently accepted. This caused the every-boot IDEMPOTENT token-plan reload (LLM provider + AI route update) to appear to succeed in logs while workers later failed with "Model not exist / HTTP 400" because Higress never received the new configuration. Fix: - higress_api now returns the real exit code (non-zero on error) - Extended HTML detection to match any <html[> tag (not only <!DOCTYPE html>) - Added explicit HTTP 405 branch with actionable error - success:false is now ERROR (exit 1) instead of WARNING - Introduced higress_api_soft wrapper for first-boot NON-IDEMPOTENT steps where a prior run may have already created the resource - All IDEMPOTENT callers use so a real failure stops the boot sequence instead of producing a silently broken AI gateway Closes agentscope-ai#908
|
Caution The consumer version of Gemini Code Assist on GitHub has been sunset. All code review activity has officially ceased. |
RerankerGuo
force-pushed
the
fix/issue-908-higress-setup-silent-failures
branch
from
July 30, 2026 00:53
2a8a511 to
cff5d04
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Closes #908
The
higress_apihelper insetup-higress.shused to swallow nearly every Console API failure as a log-level WARNING with exit 0:"success":falseresponses → only logged WARNING, caller never noticed<!DOCTYPE html>(not<html>)|| true) → completely ignoredThis produced the exact symptom reported in #908: after a K8s token-plan hot-reload, the every-boot IDEMPOTENT section would log "OK" but workers would later fail with "Model not exist / HTTP 400" because Higress had never accepted the new routes (HTTP 405 or a session-expired HTML page being silently dropped).
Changes
manager/scripts/init/setup-higress.sh
success:false, or any unexpected HTTP code)<!DOCTYPE html>and<html...>tagshigress_api_softwrapper — for NON-IDEMPOTENT first-boot steps where a prior boot may have already created the resource and an error is non-fatalhigress_api_soft— preserves the old tolerant behaviour for one-time setup, since those resources are marker-protected and may already exist on a retryhigress_apierror — every call appends|| exit 1so the AI Gateway / LLM provider hot-reload cannot silently produce a broken configchangelog/current.md
Added bug-fix entry referencing #908.
Test Plan
bash -n setup-higress.shpasses