[PR #18325] [CLOSED] fix: Bug fix or error correction #11552

Closed
opened 2025-11-11 19:34:42 -06:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/open-webui/open-webui/pull/18325
Author: @hiwylee
Created: 10/14/2025
Status: Closed

Base: mainHead: vector-search-branch


📝 Commits (2)

  • 630a6bf bugfix - init variable
  • ce27de0 Merge pull request #1 from hiwylee/vector-search-branch-bugfix

📊 Changes

1 file changed (+1 additions, -0 deletions)

View changed files

📝 backend/open_webui/retrieval/vector/dbs/oracle23ai.py (+1 -0)

📄 Description

Pull Request Checklist

Note to first-time contributors: Please open a discussion post in Discussions and describe your changes before submitting a pull request.

Before submitting, make sure you've checked the following:

  • [ O] Target branch: Verify that the pull request targets the dev branch. Not targeting the dev branch may lead to immediate closure of the PR.
  • [ O] Description: Provide a concise description of the changes made in this pull request.
  • [ O] Changelog: Ensure a changelog entry following the format of Keep a Changelog is added at the bottom of the PR description.
  • [ O] Documentation: If necessary, update relevant documentation Open WebUI Docs like environment variables, the tutorials, or other documentation sources.
  • [ O] Dependencies: Are there any new dependencies? Have you updated the dependency versions in the documentation?
  • [O ] Testing: Perform manual tests to verify the implemented fix/feature works as intended AND does not break any other functionality. Take this as an opportunity to make screenshots of the feature/fix and include it in the PR description.
  • [ O] Agentic AI Code:: Confirm this Pull Request is not written by any AI Agent or has at least gone through additional human review and manual testing. If any AI Agent is the co-author of this PR, it may lead to immediate closure of the PR.
  • [O ] Code review: Have you performed a self-review of your code, addressing any coding standard issues and ensuring adherence to the project's coding standards?
  • Title Prefix: To clearly categorize this pull request, prefix the pull request title using one of the following:
    • BREAKING CHANGE: Significant changes that may affect compatibility
    • build: Changes that affect the build system or external dependencies
    • ci: Changes to our continuous integration processes or workflows
    • chore: Refactor, cleanup, or other non-functional code changes
    • docs: Documentation update or addition
    • feat: Introduces a new feature or enhancement to the codebase
    • fix: Bug fix or error correction
    • i18n: Internationalization or localization changes
    • perf: Performance improvement
    • refactor: Code restructuring for better maintainability, readability, or scalability
    • style: Changes that do not affect the meaning of the code (white space, formatting, missing semi-colons, etc.)
    • test: Adding missing tests or correcting existing tests
    • WIP: Work in progress, a temporary label for incomplete or ongoing work

Changelog Entry

Description

  • [fix: initialize 'limit' before use to prevent UnboundLocalError]
  File "/home/opc/open-webui/backend/open_webui/retrieval/utils.py", line 139, in get_doc
    result = VECTOR_DB_CLIENT.get(collection_name=collection_name)
             │                │                   └ '7dcfeaf5-be44-4c93-a1bc-fa022e41090d'
             │                └ <function Oracle23aiClient.get at 0x7ff9cb99b560>
             └ <open_webui.retrieval.vector.dbs.oracle23ai.Oracle23aiClient object at 0x7ff9cc3e4770>

  File "/home/opc/open-webui/backend/open_webui/retrieval/vector/dbs/oracle23ai.py", line 715, in get
    limit = limit or 1000

UnboundLocalError: cannot access local variable 'limit' where it is not associated with a value

Added

  • [N/A]

Changed

  • [N/A]

Deprecated

  • [N/A]

Removed

  • [N/A]

Fixed

  • [fix: initialize 'limit' before use to prevent UnboundLocalError]

Security

  • [N/A]

Breaking Changes

  • BREAKING CHANGE: [N/A]

Additional Information

  • [N/A]
    • [Reference any related issues, commits, or other relevant information]

Screenshots or Videos

  • [N/A]

Contributor License Agreement

By submitting this pull request, I confirm that I have read and fully agree to the Contributor License Agreement (CLA), and I am providing my contributions under its terms.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/open-webui/open-webui/pull/18325 **Author:** [@hiwylee](https://github.com/hiwylee) **Created:** 10/14/2025 **Status:** ❌ Closed **Base:** `main` ← **Head:** `vector-search-branch` --- ### 📝 Commits (2) - [`630a6bf`](https://github.com/open-webui/open-webui/commit/630a6bf5ae8af98cc0a2733fb9df0f64fd8147d4) bugfix - init variable - [`ce27de0`](https://github.com/open-webui/open-webui/commit/ce27de051608b6f08c5ad6b1940b227c815ebc5c) Merge pull request #1 from hiwylee/vector-search-branch-bugfix ### 📊 Changes **1 file changed** (+1 additions, -0 deletions) <details> <summary>View changed files</summary> 📝 `backend/open_webui/retrieval/vector/dbs/oracle23ai.py` (+1 -0) </details> ### 📄 Description # Pull Request Checklist ### Note to first-time contributors: Please open a discussion post in [Discussions](https://github.com/open-webui/open-webui/discussions) and describe your changes before submitting a pull request. **Before submitting, make sure you've checked the following:** - [ O] **Target branch:** Verify that the pull request targets the `dev` branch. Not targeting the `dev` branch may lead to immediate closure of the PR. - [ O] **Description:** Provide a concise description of the changes made in this pull request. - [ O] **Changelog:** Ensure a changelog entry following the format of [Keep a Changelog](https://keepachangelog.com/) is added at the bottom of the PR description. - [ O] **Documentation:** If necessary, update relevant documentation [Open WebUI Docs](https://github.com/open-webui/docs) like environment variables, the tutorials, or other documentation sources. - [ O] **Dependencies:** Are there any new dependencies? Have you updated the dependency versions in the documentation? - [O ] **Testing:** Perform manual tests to verify the implemented fix/feature works as intended AND does not break any other functionality. Take this as an opportunity to make screenshots of the feature/fix and include it in the PR description. - [ O] **Agentic AI Code:**: Confirm this Pull Request is **not written by any AI Agent** or has at least gone through additional human review **and** manual testing. If any AI Agent is the co-author of this PR, it may lead to immediate closure of the PR. - [O ] **Code review:** Have you performed a self-review of your code, addressing any coding standard issues and ensuring adherence to the project's coding standards? - [ ] **Title Prefix:** To clearly categorize this pull request, prefix the pull request title using one of the following: - **BREAKING CHANGE**: Significant changes that may affect compatibility - **build**: Changes that affect the build system or external dependencies - **ci**: Changes to our continuous integration processes or workflows - **chore**: Refactor, cleanup, or other non-functional code changes - **docs**: Documentation update or addition - **feat**: Introduces a new feature or enhancement to the codebase - **fix**: Bug fix or error correction - **i18n**: Internationalization or localization changes - **perf**: Performance improvement - **refactor**: Code restructuring for better maintainability, readability, or scalability - **style**: Changes that do not affect the meaning of the code (white space, formatting, missing semi-colons, etc.) - **test**: Adding missing tests or correcting existing tests - **WIP**: Work in progress, a temporary label for incomplete or ongoing work # Changelog Entry ### Description - [fix: initialize 'limit' before use to prevent UnboundLocalError] ``` File "/home/opc/open-webui/backend/open_webui/retrieval/utils.py", line 139, in get_doc result = VECTOR_DB_CLIENT.get(collection_name=collection_name) │ │ └ '7dcfeaf5-be44-4c93-a1bc-fa022e41090d' │ └ <function Oracle23aiClient.get at 0x7ff9cb99b560> └ <open_webui.retrieval.vector.dbs.oracle23ai.Oracle23aiClient object at 0x7ff9cc3e4770> File "/home/opc/open-webui/backend/open_webui/retrieval/vector/dbs/oracle23ai.py", line 715, in get limit = limit or 1000 UnboundLocalError: cannot access local variable 'limit' where it is not associated with a value ``` ### Added - [N/A] ### Changed - [N/A] ### Deprecated - [N/A] ### Removed - [N/A] ### Fixed - [fix: initialize 'limit' before use to prevent UnboundLocalError] ### Security - [N/A] ### Breaking Changes - **BREAKING CHANGE**: [N/A] --- ### Additional Information - [N/A] - [Reference any related issues, commits, or other relevant information] ### Screenshots or Videos - [N/A] ### Contributor License Agreement By submitting this pull request, I confirm that I have read and fully agree to the [Contributor License Agreement (CLA)](https://github.com/open-webui/open-webui/blob/main/CONTRIBUTOR_LICENSE_AGREEMENT), and I am providing my contributions under its terms. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2025-11-11 19:34:42 -06:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/open-webui#11552