-
Notifications
You must be signed in to change notification settings - Fork 91
Logo bug fix #654
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Logo bug fix #654
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR fixes a bug where custom logos uploaded via Admin Settings were not displaying across the application. The root cause was that the sanitize_settings_for_user() function was filtering out logo-related keys containing "base64" as a security measure, preventing templates from detecting whether custom logos exist.
Changes:
- Modified
sanitize_settings_for_user()to add boolean flags for logo/favicon existence after sanitization, allowing templates to check if custom logos exist without exposing actual base64 data - Added comprehensive functional tests to validate the fix and prevent regression
- Created detailed fix documentation explaining the issue, root cause, and solution
- Updated release notes with information about the fix
Reviewed changes
Copilot reviewed 9 out of 12 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| application/single_app/functions_settings.py | Core fix: Added boolean flag logic after sanitization loop to preserve logo existence information |
| functional_tests/test_custom_logo_sanitization_fix.py | Comprehensive test coverage for the sanitization fix including edge cases |
| docs/explanation/fixes/v0.237.002/CUSTOM_LOGO_NOT_DISPLAYING_FIX.md | Detailed documentation of the issue, root cause analysis, and solution |
| docs/explanation/release_notes.md | Release notes entry for the fix |
| application/single_app/config.py | Version increment (though inconsistent with PR title) |
| application/single_app/templates/profile.html | Additional retention policy dropdown options (unrelated to logo fix) |
| application/single_app/templates/control_center.html | Additional retention policy dropdown options (unrelated to logo fix) |
| application/single_app/templates/admin_settings.html | Additional retention policy dropdown options (unrelated to logo fix) |
| application/single_app/static/images/custom_logo.png | Static image file addition (purpose unclear) |
| application/single_app/static/images/custom_logo_dark.png | Static image file addition (purpose unclear) |
| application/single_app/static/images/favicon.ico | Static image file addition (purpose unclear) |
| .github/instructions/update_release_notes.instructions.md | Project documentation guidelines (unrelated to logo fix) |
| --- | ||
| applyTo: '**' | ||
| --- | ||
|
|
||
| # Release Notes Update Instructions | ||
|
|
||
| ## When to Update Release Notes | ||
|
|
||
| After completing a code change (bug fix, new feature, enhancement, or breaking change), always ask the user: | ||
|
|
||
| **"Would you like me to update the release notes in `docs/explanation/release_notes.md`?"** | ||
|
|
||
| ## If the User Confirms Yes | ||
|
|
||
| Update the release notes file following these guidelines: | ||
|
|
||
| ### 1. Location | ||
| Release notes are located at: `docs/explanation/release_notes.md` | ||
|
|
||
| ### 2. Version Placement | ||
| - Add new entries under the **current version** from `config.py` | ||
| - If the version has changed, create a new version section at the TOP of the file | ||
| - Format: `### **(vX.XXX.XXX)**` | ||
|
|
||
| ### 3. Entry Categories | ||
|
|
||
| Organize entries under the appropriate category: | ||
|
|
||
| #### New Features | ||
| ```markdown | ||
| #### New Features | ||
|
|
||
| * **Feature Name** | ||
| * Brief description of what the feature does and its benefits. | ||
| * Additional details about functionality or configuration. | ||
| * (Ref: relevant files, components, or concepts) | ||
| ``` | ||
|
|
||
| #### Bug Fixes | ||
| ```markdown | ||
| #### Bug Fixes | ||
|
|
||
| * **Fix Name** | ||
| * Description of what was broken and how it was fixed. | ||
| * Impact or affected areas. | ||
| * (Ref: relevant files, functions, or components) | ||
| ``` | ||
|
|
||
| #### User Interface Enhancements | ||
| ```markdown | ||
| #### User Interface Enhancements | ||
|
|
||
| * **Enhancement Name** | ||
| * Description of UI/UX improvements. | ||
| * (Ref: relevant templates, CSS, or JavaScript files) | ||
| ``` | ||
|
|
||
| #### Breaking Changes | ||
| ```markdown | ||
| #### Breaking Changes | ||
|
|
||
| * **Change Name** | ||
| * Description of what changed and why. | ||
| * **Migration**: Steps users need to take (if any). | ||
| ``` | ||
|
|
||
| ### 4. Entry Format Guidelines | ||
|
|
||
| - **Bold the title** of each entry | ||
| - Use bullet points for details | ||
| - Include a `(Ref: ...)` line with relevant file names, functions, or concepts | ||
| - Keep descriptions concise but informative | ||
| - Focus on user-facing impact, not implementation details | ||
|
|
||
| ### 5. Example Entry | ||
|
|
||
| ```markdown | ||
| * **Custom Logo Display Fix** | ||
| * Fixed issue where custom logos uploaded via Admin Settings would only display on the admin page but not on other pages (chat, sidebar, landing page). | ||
| * Root cause was overly aggressive sanitization removing logo URLs from public settings. | ||
| * (Ref: logo display, settings sanitization, template conditionals) | ||
| ``` | ||
|
|
||
| ### 6. Checklist Before Updating | ||
|
|
||
| - [ ] Confirm the current version in `config.py` | ||
| - [ ] Determine the correct category (New Feature, Bug Fix, Enhancement, Breaking Change) | ||
| - [ ] Write a clear, user-focused description | ||
| - [ ] Include relevant file/component references | ||
| - [ ] Place entry under the correct version section |
Copilot
AI
Jan 26, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The addition of release notes update instructions is unrelated to the logo display bug fix. While this may be a useful guideline for the project, it should be in a separate PR or the PR description should be updated to mention this is also adding project documentation guidelines. Mixing infrastructure/process changes with bug fixes makes PR review and change tracking more difficult.
| EXECUTOR_MAX_WORKERS = 30 | ||
| SESSION_TYPE = 'filesystem' | ||
| VERSION = "0.237.001" | ||
| VERSION = "0.237.003" |
Copilot
AI
Jan 26, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Version mismatch: The PR title and description indicate this is version "0.237.002", but the config.py file shows VERSION = "0.237.003". This creates confusion about which version this fix belongs to. Either the PR description should be updated to match v0.237.003, or the config.py version should be v0.237.002 to match the PR description and all documentation files.
| <option value="2">2 days</option> | ||
| <option value="3">3 days</option> | ||
| <option value="4">4 days</option> | ||
| <option value="5">5 days</option> | ||
| <option value="6">6 days</option> | ||
| <option value="7">7 days (1 week)</option> | ||
| <option value="10">10 days</option> | ||
| <option value="14">14 days (2 weeks)</option> |
Copilot
AI
Jan 26, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The retention policy dropdown additions (values 2, 3, 4, 6, 7, and 14 days) are unrelated to the logo display bug fix described in the PR. These changes should be in a separate PR or the PR description should be updated to document this additional feature. Mixing unrelated changes in a single PR makes it harder to review, track, and potentially revert changes if needed.
* updated the logging logic when running retention delete with archiving enabled (#642) * Corrected version to 0.236.011 (#645) * v0.237.001 (#649) * Use Microsoft python base image * Add python ENV vars * Add python ENV vars * Install deps to systme * Add temp dir to image and pip conf support * Add custom-ca-certificates dir * Logo bug fix (#654) * release note updating for github coplilot * fixed logo bug issue * added 2,3,4,5,6,14 days to rentention policy * added retention policy time updates --------- Co-authored-by: Ed Clark <clarked@microsoft.com> Co-authored-by: Bionic711 <13358952+Bionic711@users.noreply.github.com>
* updated the logging logic when running retention delete with archiving enabled (#642) * Corrected version to 0.236.011 (#645) * v0.237.001 (#649) * Use Microsoft python base image * Add python ENV vars * Add python ENV vars * Install deps to systme * Add temp dir to image and pip conf support * Add custom-ca-certificates dir * Logo bug fix (#654) * release note updating for github coplilot * fixed logo bug issue * added 2,3,4,5,6,14 days to rentention policy * added retention policy time updates * Rentention policy (#657) * Critical Retention Policy Deletion Fix * Create RETENTION_POLICY_NULL_LAST_ACTIVITY_FIX.md --------- Co-authored-by: Ed Clark <clarked@microsoft.com> Co-authored-by: Bionic711 <13358952+Bionic711@users.noreply.github.com>
(v0.237.003)
New Features
admin_settings.html,profile.html,control_center.html.Bug Fixes
sanitize_settings_for_user()function was strippingcustom_logo_base64,custom_logo_dark_base64, andcustom_favicon_base64keys entirely because they contained "base64" (a sensitive term filter), preventing templates from detecting logo existence.functions_settings.py(sanitize_settings_for_user()function).