Skip to content

fix(settings): add profile button when no profiles exist#513

Merged
pancacake merged 1 commit into
HKUDS:devfrom
wedone:fix/add-profile-button-empty-state
May 27, 2026
Merged

fix(settings): add profile button when no profiles exist#513
pancacake merged 1 commit into
HKUDS:devfrom
wedone:fix/add-profile-button-empty-state

Conversation

@wedone

@wedone wedone commented May 24, 2026

Copy link
Copy Markdown
Contributor

Description

Fix a dead-end in the LLM/Embedding/Search settings page where no profile exists.

When the settings page has no configured profiles, the UI displays "No profiles configured. Add a profile to start." but provides no button to actually add one. The "+ Profile" button only renders inside the profile editor, which never appears when the list is empty — creating a dead end for new users.

This also explains why manually editing model_catalog.json and then clicking Apply or refreshing the page overwrites the file — the frontend draft is always the empty catalog, so Apply POSTs the empty value back to the backend.

Fix: Add a "+ Profile" button in the empty-state view, matching the existing button style used in the profile editor.

Related Issues

Module(s) Affected

  • agents
  • api
  • config
  • core
  • knowledge
  • logging
  • services
  • tools
  • utils
  • web (Frontend)
  • docs (Documentation)
  • scripts
  • tests
  • Other: ...

Checklist

  • I have read and followed the contribution guidelines.
  • My code follows the project's coding standards.
  • I have run pre-commit run --all-files and fixed any issues.
  • I have added relevant tests for my changes.
  • I have updated the documentation (if necessary).
  • My changes do not introduce any new security vulnerabilities.

Additional Notes

Changed file: web/components/settings/ServiceConfigEditor.tsx (1 file, +9 -1)

Root cause analysis:

Symptom Cause
No "Add Profile" button Empty-state branch only renders text; button only renders when activeProfile exists
Manual JSON edit overwritten on Apply Frontend draft is still empty catalog; Apply POSTs empty value to overwrite file
Config lost after refresh Apply already overwrote the file; refresh reads the overwritten empty content

When the LLM/Embedding/Search settings page has no profiles configured, the UI displayed 'No profiles configured. Add a profile to start.' but provided no button to actually add one. The add-profile button was only visible inside the profile editor, which never rendered when the list was empty - creating a dead end for new users.

Add a '+ Profile' button in the empty-state view, matching the existing button style used in the profile editor.

Closes HKUDS#512, Closes HKUDS#505
@wedone wedone force-pushed the fix/add-profile-button-empty-state branch 2 times, most recently from bed642a to b468c9b Compare May 26, 2026 15:47
@pancacake pancacake merged commit 71e4396 into HKUDS:dev May 27, 2026
@pancacake

Copy link
Copy Markdown
Collaborator

Thanks for your contribution!

pancacake added a commit that referenced this pull request May 27, 2026
Security: lock down the TutorBot tool sandbox (shell exec is opt-in, all
filesystem/shell access confined to the bot workspace) and isolate per-user
resources, closing #518, #517, #516, #515, #514 and #506 (first hardened in
#507).

Bug fixes: chat input disabled after the first turn (#520), KB embedding
failure on long documents (#521 / #509), profile creation under Docker
(#512 / #513), Qwen reasoning models failing native tool calling (#527 / #528),
the GPT-5 init-wizard token parameter (#508), and oversized session-event
truncation (#524).

Features: HTTP/SSE API for multi-turn chat with a specific TutorBot (#511),
multimodal image fallback for vision-capable providers without a capability
entry, safe ZIP knowledge upload, and a /settings/network page with model
fetching (community PRs #522 and #523 reimplemented locally).

Also bumps __version__ to 1.4.1, adds the v1.4.1 release notes, updates the
README Releases section, and ships the Astro + Starlight docs site under site/.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@wedone wedone deleted the fix/add-profile-button-empty-state branch June 9, 2026 14:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants