Update main3.py
Browse files
main3.py
CHANGED
|
@@ -308,7 +308,7 @@ with open(f'{params["dir"]}/style.css', 'a') as cssFile:
|
|
| 308 |
subprocess.run([wget_path, '-O', f'{params["dir"]}/javascript/piw.js',
|
| 309 |
'https://huggingface.co/datasets/daasd/sd_backup/resolve/main/PNG_info_web.js'],
|
| 310 |
check=True)
|
| 311 |
-
#
|
| 312 |
with open(f'{params["dir"]}/modules/ui.py', 'r') as readFile:
|
| 313 |
content = readFile.read()
|
| 314 |
content = content.replace(''' for tabname, button in buttons.items():
|
|
@@ -323,3 +323,12 @@ content = content.replace(''' for tabname, button in buttons.item
|
|
| 323 |
)''', '')
|
| 324 |
with open(f'{params["dir"]}/modules/ui.py', 'w') as writeFile:
|
| 325 |
writeFile.write(content)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 308 |
subprocess.run([wget_path, '-O', f'{params["dir"]}/javascript/piw.js',
|
| 309 |
'https://huggingface.co/datasets/daasd/sd_backup/resolve/main/PNG_info_web.js'],
|
| 310 |
check=True)
|
| 311 |
+
# 拦截png_info
|
| 312 |
with open(f'{params["dir"]}/modules/ui.py', 'r') as readFile:
|
| 313 |
content = readFile.read()
|
| 314 |
content = content.replace(''' for tabname, button in buttons.items():
|
|
|
|
| 323 |
)''', '')
|
| 324 |
with open(f'{params["dir"]}/modules/ui.py', 'w') as writeFile:
|
| 325 |
writeFile.write(content)
|
| 326 |
+
|
| 327 |
+
# 11.11 httpx依赖更新
|
| 328 |
+
# 读取文件内容
|
| 329 |
+
with open(f'{params["dir"]}/requirements_versions.txt', 'r') as readFile:
|
| 330 |
+
content = readFile.read()
|
| 331 |
+
content += '\nhttpx==0.24.1'
|
| 332 |
+
with open(f'{params["dir"]}/requirements_versions.txt', 'w') as writeFile:
|
| 333 |
+
writeFile.write(content)
|
| 334 |
+
|