Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
chenpangpang
open-webui
Commits
74ca4189
Commit
74ca4189
authored
May 25, 2024
by
Timothy J. Baek
Browse files
fix
parent
7f77b3ad
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
1 deletion
+5
-1
backend/config.py
backend/config.py
+5
-1
No files found.
backend/config.py
View file @
74ca4189
...
@@ -27,6 +27,8 @@ from constants import ERROR_MESSAGES
...
@@ -27,6 +27,8 @@ from constants import ERROR_MESSAGES
BACKEND_DIR
=
Path
(
__file__
).
parent
# the path containing this file
BACKEND_DIR
=
Path
(
__file__
).
parent
# the path containing this file
BASE_DIR
=
BACKEND_DIR
.
parent
# the path containing the backend/
BASE_DIR
=
BACKEND_DIR
.
parent
# the path containing the backend/
print
(
BASE_DIR
)
try
:
try
:
from
dotenv
import
load_dotenv
,
find_dotenv
from
dotenv
import
load_dotenv
,
find_dotenv
...
@@ -121,7 +123,9 @@ def parse_section(section):
...
@@ -121,7 +123,9 @@ def parse_section(section):
try
:
try
:
changelog_content
=
(
BASE_DIR
/
"CHANGELOG.md"
).
read_text
()
with
open
(
BASE_DIR
/
"CHANGELOG.md"
,
"r"
)
as
file
:
changelog_content
=
file
.
read
()
except
:
except
:
changelog_content
=
(
pkgutil
.
get_data
(
"open_webui"
,
"CHANGELOG.md"
)
or
b
""
).
decode
()
changelog_content
=
(
pkgutil
.
get_data
(
"open_webui"
,
"CHANGELOG.md"
)
or
b
""
).
decode
()
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment