Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
S
Stable Diffusion Webui
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
List
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
novelai-storage
Stable Diffusion Webui
Commits
6091c4e4
Commit
6091c4e4
authored
Jun 14, 2023
by
w-e-w
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
terminate -> stop
parent
49fb2a33
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
3 deletions
+3
-3
.github/workflows/run_tests.yaml
.github/workflows/run_tests.yaml
+1
-1
modules/api/api.py
modules/api/api.py
+2
-2
No files found.
.github/workflows/run_tests.yaml
View file @
6091c4e4
...
@@ -50,7 +50,7 @@ jobs:
...
@@ -50,7 +50,7 @@ jobs:
python -m pytest -vv --junitxml=test/results.xml --cov . --cov-report=xml --verify-base-url test
python -m pytest -vv --junitxml=test/results.xml --cov . --cov-report=xml --verify-base-url test
-
name
:
Kill test server
-
name
:
Kill test server
if
:
always()
if
:
always()
run
:
curl -vv -XPOST http://127.0.0.1:7860/sdapi/v1/server-
terminate
&& sleep
10
run
:
curl -vv -XPOST http://127.0.0.1:7860/sdapi/v1/server-
stop
&& sleep
10
-
name
:
Show coverage
-
name
:
Show coverage
run
:
|
run
:
|
python -m coverage combine .coverage*
python -m coverage combine .coverage*
...
...
modules/api/api.py
View file @
6091c4e4
...
@@ -212,7 +212,7 @@ class Api:
...
@@ -212,7 +212,7 @@ class Api:
if
shared
.
cmd_opts
.
add_stop_route
:
if
shared
.
cmd_opts
.
add_stop_route
:
self
.
add_api_route
(
"/sdapi/v1/server-kill"
,
self
.
kill_webui
,
methods
=
[
"POST"
])
self
.
add_api_route
(
"/sdapi/v1/server-kill"
,
self
.
kill_webui
,
methods
=
[
"POST"
])
self
.
add_api_route
(
"/sdapi/v1/server-restart"
,
self
.
restart_webui
,
methods
=
[
"POST"
])
self
.
add_api_route
(
"/sdapi/v1/server-restart"
,
self
.
restart_webui
,
methods
=
[
"POST"
])
self
.
add_api_route
(
"/sdapi/v1/server-
terminate"
,
self
.
terminate
_webui
,
methods
=
[
"POST"
])
self
.
add_api_route
(
"/sdapi/v1/server-
stop"
,
self
.
stop
_webui
,
methods
=
[
"POST"
])
self
.
default_script_arg_txt2img
=
[]
self
.
default_script_arg_txt2img
=
[]
self
.
default_script_arg_img2img
=
[]
self
.
default_script_arg_img2img
=
[]
...
@@ -729,6 +729,6 @@ class Api:
...
@@ -729,6 +729,6 @@ class Api:
restart
.
restart_program
()
restart
.
restart_program
()
return
Response
(
status_code
=
501
)
return
Response
(
status_code
=
501
)
def
terminate
_webui
(
request
):
def
stop
_webui
(
request
):
shared
.
state
.
server_command
=
"stop"
shared
.
state
.
server_command
=
"stop"
return
Response
(
"Stopping."
)
return
Response
(
"Stopping."
)
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