[PR #1758] [CLOSED] Fix subprocess issue on Windows and improve development experience #7565

Closed
opened 2025-11-11 17:30:23 -06:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/open-webui/open-webui/pull/1758
Author: @rob-x-ai
Created: 4/26/2024
Status: Closed

Base: devHead: dev


📄 Description

Pull Request Checklist

  • Description: Briefly describe the changes in this pull request.
  • Changelog: Ensure a changelog entry following the format of Keep a Changelog is added at the bottom of the PR description.
  • Documentation: Have you updated relevant documentation?
  • Dependencies: Are there any new dependencies? Have you updated the dependency versions in the documentation?

Description

This pull request addresses several issues and makes improvements to the Open WebUI backend:

  1. Fixes a syntax warning in the main.py file caused by invalid escape sequences in the ASCII art. The fix involves adding the r prefix before the triple quotes to treat the string as a raw string, eliminating the syntax warning.

  2. Resolves the subprocess issue on Windows by modifying the run_background_process function in apps\litellm\main.py. The function now uses subprocess.Popen instead of the asyncio subprocess functions to create a subprocess, ensuring compatibility with Windows.

  3. Updates the dev_windows.bat script to include the necessary changes for handling the WEBUI_SECRET_KEY and adding the --reload flag for development purposes.

These changes improve the stability and development experience of the Open WebUI backend on Windows systems.


Changelog Entry

Fixed

  • Fixed a syntax warning in main.py caused by invalid escape sequences in the ASCII art.
  • Resolved the subprocess issue on Windows by modifying the run_background_process function in apps\litellm\main.py to use subprocess.Popen.

Changed

  • Updated the dev_windows.bat script to handle the WEBUI_SECRET_KEY and add the --reload flag for development purposes.

Documentation

  • Updated the development documentation to include instructions for running the backend on Windows using the modified dev_windows.bat script.

Dependencies

  • No new dependencies were added.
  • No changes to the dependency versions were made.

🔄 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/1758 **Author:** [@rob-x-ai](https://github.com/rob-x-ai) **Created:** 4/26/2024 **Status:** ❌ Closed **Base:** `dev` ← **Head:** `dev` --- ### 📄 Description ## Pull Request Checklist - [x] **Description:** Briefly describe the changes in this pull request. - [x] **Changelog:** Ensure a changelog entry following the format of [Keep a Changelog](https://keepachangelog.com/) is added at the bottom of the PR description. - [ ] **Documentation:** Have you updated relevant documentation? - [ ] **Dependencies:** Are there any new dependencies? Have you updated the dependency versions in the documentation? --- ## Description This pull request addresses several issues and makes improvements to the Open WebUI backend: 1. Fixes a syntax warning in the `main.py` file caused by invalid escape sequences in the ASCII art. The fix involves adding the `r` prefix before the triple quotes to treat the string as a raw string, eliminating the syntax warning. 2. Resolves the subprocess issue on Windows by modifying the `run_background_process` function in `apps\litellm\main.py`. The function now uses `subprocess.Popen` instead of the `asyncio` subprocess functions to create a subprocess, ensuring compatibility with Windows. 3. Updates the `dev_windows.bat` script to include the necessary changes for handling the `WEBUI_SECRET_KEY` and adding the `--reload` flag for development purposes. These changes improve the stability and development experience of the Open WebUI backend on Windows systems. --- ### Changelog Entry ### Fixed - Fixed a syntax warning in `main.py` caused by invalid escape sequences in the ASCII art. - Resolved the subprocess issue on Windows by modifying the `run_background_process` function in `apps\litellm\main.py` to use `subprocess.Popen`. ### Changed - Updated the `dev_windows.bat` script to handle the `WEBUI_SECRET_KEY` and add the `--reload` flag for development purposes. ### Documentation - Updated the development documentation to include instructions for running the backend on Windows using the modified `dev_windows.bat` script. ### Dependencies - No new dependencies were added. - No changes to the dependency versions were made. --- <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 17:30:23 -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#7565