Skip to content

Commit 9e01fc9

Browse files
Merge branch 'AUTOMATIC1111:master' into patch-1
2 parents 070fe37 + 82a973c commit 9e01fc9

325 files changed

Lines changed: 48247 additions & 15432 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.eslintignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
extensions
2+
extensions-disabled
3+
repositories
4+
venv

.eslintrc.js

Lines changed: 98 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,98 @@
1+
/* global module */
2+
module.exports = {
3+
env: {
4+
browser: true,
5+
es2021: true,
6+
},
7+
extends: "eslint:recommended",
8+
parserOptions: {
9+
ecmaVersion: "latest",
10+
},
11+
rules: {
12+
"arrow-spacing": "error",
13+
"block-spacing": "error",
14+
"brace-style": "error",
15+
"comma-dangle": ["error", "only-multiline"],
16+
"comma-spacing": "error",
17+
"comma-style": ["error", "last"],
18+
"curly": ["error", "multi-line", "consistent"],
19+
"eol-last": "error",
20+
"func-call-spacing": "error",
21+
"function-call-argument-newline": ["error", "consistent"],
22+
"function-paren-newline": ["error", "consistent"],
23+
"indent": ["error", 4],
24+
"key-spacing": "error",
25+
"keyword-spacing": "error",
26+
"linebreak-style": ["error", "unix"],
27+
"no-extra-semi": "error",
28+
"no-mixed-spaces-and-tabs": "error",
29+
"no-multi-spaces": "error",
30+
"no-redeclare": ["error", {builtinGlobals: false}],
31+
"no-trailing-spaces": "error",
32+
"no-unused-vars": "off",
33+
"no-whitespace-before-property": "error",
34+
"object-curly-newline": ["error", {consistent: true, multiline: true}],
35+
"object-curly-spacing": ["error", "never"],
36+
"operator-linebreak": ["error", "after"],
37+
"quote-props": ["error", "consistent-as-needed"],
38+
"semi": ["error", "always"],
39+
"semi-spacing": "error",
40+
"semi-style": ["error", "last"],
41+
"space-before-blocks": "error",
42+
"space-before-function-paren": ["error", "never"],
43+
"space-in-parens": ["error", "never"],
44+
"space-infix-ops": "error",
45+
"space-unary-ops": "error",
46+
"switch-colon-spacing": "error",
47+
"template-curly-spacing": ["error", "never"],
48+
"unicode-bom": "error",
49+
},
50+
globals: {
51+
//script.js
52+
gradioApp: "readonly",
53+
executeCallbacks: "readonly",
54+
onAfterUiUpdate: "readonly",
55+
onOptionsChanged: "readonly",
56+
onUiLoaded: "readonly",
57+
onUiUpdate: "readonly",
58+
uiCurrentTab: "writable",
59+
uiElementInSight: "readonly",
60+
uiElementIsVisible: "readonly",
61+
//ui.js
62+
opts: "writable",
63+
all_gallery_buttons: "readonly",
64+
selected_gallery_button: "readonly",
65+
selected_gallery_index: "readonly",
66+
switch_to_txt2img: "readonly",
67+
switch_to_img2img_tab: "readonly",
68+
switch_to_img2img: "readonly",
69+
switch_to_sketch: "readonly",
70+
switch_to_inpaint: "readonly",
71+
switch_to_inpaint_sketch: "readonly",
72+
switch_to_extras: "readonly",
73+
get_tab_index: "readonly",
74+
create_submit_args: "readonly",
75+
restart_reload: "readonly",
76+
updateInput: "readonly",
77+
onEdit: "readonly",
78+
//extraNetworks.js
79+
requestGet: "readonly",
80+
popup: "readonly",
81+
// profilerVisualization.js
82+
createVisualizationTable: "readonly",
83+
// from python
84+
localization: "readonly",
85+
// progrssbar.js
86+
randomId: "readonly",
87+
requestProgress: "readonly",
88+
// imageviewer.js
89+
modalPrevImage: "readonly",
90+
modalNextImage: "readonly",
91+
// localStorage.js
92+
localSet: "readonly",
93+
localGet: "readonly",
94+
localRemove: "readonly",
95+
// resizeHandle.js
96+
setupResizeHandle: "writable"
97+
}
98+
};

.git-blame-ignore-revs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
# Apply ESlint
2+
9c54b78d9dde5601e916f308d9a9d6953ec39430
Lines changed: 57 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -1,62 +1,67 @@
11
name: Bug Report
2-
description: You think somethings is broken in the UI
2+
description: You think something is broken in the UI
33
title: "[Bug]: "
44
labels: ["bug-report"]
55

66
body:
7+
- type: markdown
8+
attributes:
9+
value: |
10+
> The title of the bug report should be short and descriptive.
11+
> Use relevant keywords for searchability.
12+
> Do not leave it blank, but also do not put an entire error log in it.
713
- type: checkboxes
814
attributes:
9-
label: Is there an existing issue for this?
10-
description: Please search to see if an issue already exists for the bug you encountered, and that it hasn't been fixed in a recent build/commit.
15+
label: Checklist
16+
description: |
17+
Please perform basic debugging to see if extensions or configuration is the cause of the issue.
18+
Basic debug procedure
19+
 1. Disable all third-party extensions - check if extension is the cause
20+
 2. Update extensions and webui - sometimes things just need to be updated
21+
 3. Backup and remove your config.json and ui-config.json - check if the issue is caused by bad configuration
22+
 4. Delete venv with third-party extensions disabled - sometimes extensions might cause wrong libraries to be installed
23+
 5. Try a fresh installation webui in a different directory - see if a clean installation solves the issue
24+
Before making a issue report please, check that the issue hasn't been reported recently.
1125
options:
12-
- label: I have searched the existing issues and checked the recent builds/commits
13-
required: true
26+
- label: The issue exists after disabling all extensions
27+
- label: The issue exists on a clean installation of webui
28+
- label: The issue is caused by an extension, but I believe it is caused by a bug in the webui
29+
- label: The issue exists in the current version of the webui
30+
- label: The issue has not been reported before recently
31+
- label: The issue has been reported before but has not been fixed yet
1432
- type: markdown
1533
attributes:
1634
value: |
17-
*Please fill this form with as much information as possible, don't forget to fill "What OS..." and "What browsers" and *provide screenshots if possible**
35+
> Please fill this form with as much information as possible. Don't forget to "Upload Sysinfo" and "What browsers" and provide screenshots if possible
1836
- type: textarea
1937
id: what-did
2038
attributes:
2139
label: What happened?
2240
description: Tell us what happened in a very clear and simple way
41+
placeholder: |
42+
txt2img is not working as intended.
2343
validations:
2444
required: true
2545
- type: textarea
2646
id: steps
2747
attributes:
2848
label: Steps to reproduce the problem
29-
description: Please provide us with precise step by step information on how to reproduce the bug
30-
value: |
31-
1. Go to ....
32-
2. Press ....
49+
description: Please provide us with precise step by step instructions on how to reproduce the bug
50+
placeholder: |
51+
1. Go to ...
52+
2. Press ...
3353
3. ...
3454
validations:
3555
required: true
3656
- type: textarea
3757
id: what-should
3858
attributes:
3959
label: What should have happened?
40-
description: tell what you think the normal behavior should be
60+
description: Tell us what you think the normal behavior should be
61+
placeholder: |
62+
WebUI should ...
4163
validations:
4264
required: true
43-
- type: input
44-
id: commit
45-
attributes:
46-
label: Commit where the problem happens
47-
description: Which commit are you running ? (copy the **Commit hash** shown in the cmd/terminal when you launch the UI)
48-
- type: dropdown
49-
id: platforms
50-
attributes:
51-
label: What platforms do you use to access UI ?
52-
multiple: true
53-
options:
54-
- Windows
55-
- Linux
56-
- MacOS
57-
- iOS
58-
- Android
59-
- Other/Cloud
6065
- type: dropdown
6166
id: browsers
6267
attributes:
@@ -68,14 +73,33 @@ body:
6873
- Brave
6974
- Apple Safari
7075
- Microsoft Edge
76+
- Android
77+
- iOS
78+
- Other
7179
- type: textarea
72-
id: cmdargs
80+
id: sysinfo
7381
attributes:
74-
label: Command Line Arguments
75-
description: Are you using any launching parameters/command line arguments (modified webui-user.py) ? If yes, please write them below
82+
label: Sysinfo
83+
description: System info file, generated by WebUI. You can generate it in settings, on the Sysinfo page. Drag the file into the field to upload it. If you submit your report without including the sysinfo file, the report will be closed. If needed, review the report to make sure it includes no personal information you don't want to share. If you can't start WebUI, you can use --dump-sysinfo commandline argument to generate the file.
84+
placeholder: |
85+
1. Go to WebUI Settings -> Sysinfo -> Download system info.
86+
If WebUI fails to launch, use --dump-sysinfo commandline argument to generate the file
87+
2. Upload the Sysinfo as a attached file, Do NOT paste it in as plain text.
88+
validations:
89+
required: true
90+
- type: textarea
91+
id: logs
92+
attributes:
93+
label: Console logs
94+
description: Please provide **full** cmd/terminal logs from the moment you started UI to the end of it, after the bug occurred. If it's very long, provide a link to pastebin or similar service.
7695
render: Shell
96+
validations:
97+
required: true
7798
- type: textarea
7899
id: misc
79100
attributes:
80-
label: Additional information, context and logs
81-
description: Please provide us with any relevant additional info, context or log output.
101+
label: Additional information
102+
description: |
103+
Please provide us with any relevant additional info or context.
104+
Examples:
105+
 I have updated my GPU driver recently.

.github/ISSUE_TEMPLATE/config.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
blank_issues_enabled: false
2+
contact_links:
3+
- name: WebUI Community Support
4+
url: https://github.com/AUTOMATIC1111/stable-diffusion-webui/discussions
5+
about: Please ask and answer questions here.

.github/ISSUE_TEMPLATE/feature_request.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
name: Feature request
22
description: Suggest an idea for this project
33
title: "[Feature Request]: "
4-
labels: ["suggestion"]
4+
labels: ["enhancement"]
55

66
body:
77
- type: checkboxes

.github/PULL_REQUEST_TEMPLATE/pull_request_template.md

Lines changed: 0 additions & 28 deletions
This file was deleted.

.github/pull_request_template.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
## Description
2+
3+
* a simple description of what you're trying to accomplish
4+
* a summary of changes in code
5+
* which issues it fixes, if any
6+
7+
## Screenshots/videos:
8+
9+
10+
## Checklist:
11+
12+
- [ ] I have read [contributing wiki page](https://github.com/AUTOMATIC1111/stable-diffusion-webui/wiki/Contributing)
13+
- [ ] I have performed a self-review of my own code
14+
- [ ] My code follows the [style guidelines](https://github.com/AUTOMATIC1111/stable-diffusion-webui/wiki/Contributing#code-style)
15+
- [ ] My code passes [tests](https://github.com/AUTOMATIC1111/stable-diffusion-webui/wiki/Tests)
Lines changed: 27 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -1,42 +1,38 @@
1-
# See https://github.com/actions/starter-workflows/blob/1067f16ad8a1eac328834e4b0ae24f7d206f810d/ci/pylint.yml for original reference file
2-
name: Run Linting/Formatting on Pull Requests
1+
name: Linter
32

43
on:
54
- push
65
- pull_request
7-
# See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#onpull_requestpull_request_targetbranchesbranches-ignore for syntax docs
8-
# if you want to filter out branches, delete the `- pull_request` and uncomment these lines :
9-
# pull_request:
10-
# branches:
11-
# - master
12-
# branches-ignore:
13-
# - development
146

157
jobs:
16-
lint:
8+
lint-python:
9+
name: ruff
1710
runs-on: ubuntu-latest
11+
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name
1812
steps:
1913
- name: Checkout Code
20-
uses: actions/checkout@v3
21-
- name: Set up Python 3.10
22-
uses: actions/setup-python@v3
14+
uses: actions/checkout@v4
15+
- uses: actions/setup-python@v5
2316
with:
24-
python-version: 3.10.6
25-
- uses: actions/cache@v2
17+
python-version: 3.11
18+
# NB: there's no cache: pip here since we're not installing anything
19+
# from the requirements.txt file(s) in the repository; it's faster
20+
# not to have GHA download an (at the time of writing) 4 GB cache
21+
# of PyTorch and other dependencies.
22+
- name: Install Ruff
23+
run: pip install ruff==0.3.3
24+
- name: Run Ruff
25+
run: ruff .
26+
lint-js:
27+
name: eslint
28+
runs-on: ubuntu-latest
29+
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name
30+
steps:
31+
- name: Checkout Code
32+
uses: actions/checkout@v4
33+
- name: Install Node.js
34+
uses: actions/setup-node@v4
2635
with:
27-
path: ~/.cache/pip
28-
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }}
29-
restore-keys: |
30-
${{ runner.os }}-pip-
31-
- name: Install PyLint
32-
run: |
33-
python -m pip install --upgrade pip
34-
pip install pylint
35-
# This lets PyLint check to see if it can resolve imports
36-
- name: Install dependencies
37-
run : |
38-
export COMMANDLINE_ARGS="--skip-torch-cuda-test --exit"
39-
python launch.py
40-
- name: Analysing the code with pylint
41-
run: |
42-
pylint $(git ls-files '*.py')
36+
node-version: 18
37+
- run: npm i --ci
38+
- run: npm run lint

0 commit comments

Comments
 (0)