Spaces:
Running
Running
Fixed the issue of failure to read options.md.
Browse files
app.py
CHANGED
@@ -768,8 +768,12 @@ def create_ui(app_config: ApplicationConfig):
|
|
768 |
optionsMd: str = None
|
769 |
readmeMd: str = None
|
770 |
try:
|
771 |
-
|
|
|
772 |
optionsMd = optionsFile.read()
|
|
|
|
|
|
|
773 |
with open("README.md", "r", encoding="utf-8") as readmeFile:
|
774 |
readmeMd = readmeFile.read()
|
775 |
except Exception as e:
|
|
|
768 |
optionsMd: str = None
|
769 |
readmeMd: str = None
|
770 |
try:
|
771 |
+
optionsPath = pathlib.Path("docs/options.md")
|
772 |
+
with open(optionsPath, "r", encoding="utf-8") as optionsFile:
|
773 |
optionsMd = optionsFile.read()
|
774 |
+
except Exception as e:
|
775 |
+
print("Error occurred during read options.md file: ", str(e))
|
776 |
+
try:
|
777 |
with open("README.md", "r", encoding="utf-8") as readmeFile:
|
778 |
readmeMd = readmeFile.read()
|
779 |
except Exception as e:
|