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
0411eced
Commit
0411eced
authored
Mar 10, 2024
by
AUTOMATIC1111
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add names to callbacks
parent
6136db14
Changes
2
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
91 additions
and
52 deletions
+91
-52
modules/extensions.py
modules/extensions.py
+17
-0
modules/script_callbacks.py
modules/script_callbacks.py
+74
-52
No files found.
modules/extensions.py
View file @
0411eced
...
...
@@ -186,6 +186,7 @@ class Extension:
def
list_extensions
():
extensions
.
clear
()
extension_paths
.
clear
()
if
shared
.
cmd_opts
.
disable_all_extensions
:
print
(
"***
\"
--disable-all-extensions
\"
arg was used, will not load any extensions ***"
)
...
...
@@ -220,6 +221,7 @@ def list_extensions():
is_builtin
=
dirname
==
extensions_builtin_dir
extension
=
Extension
(
name
=
extension_dirname
,
path
=
path
,
enabled
=
extension_dirname
not
in
shared
.
opts
.
disabled_extensions
,
is_builtin
=
is_builtin
,
metadata
=
metadata
)
extensions
.
append
(
extension
)
extension_paths
[
extension
.
path
]
=
extension
loaded_extensions
[
canonical_name
]
=
extension
# check for requirements
...
...
@@ -238,4 +240,19 @@ def list_extensions():
continue
def
find_extension
(
filename
):
parentdir
=
os
.
path
.
dirname
(
os
.
path
.
realpath
(
filename
))
while
parentdir
!=
filename
:
extension
=
extension_paths
.
get
(
parentdir
)
if
extension
is
not
None
:
return
extension
filename
=
parentdir
parentdir
=
os
.
path
.
dirname
(
filename
)
return
None
extensions
:
list
[
Extension
]
=
[]
extension_paths
:
dict
[
str
,
Extension
]
=
{}
modules/script_callbacks.py
View file @
0411eced
This diff is collapsed.
Click to expand it.
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