Upload 16 files
Browse files- .github/ISSUE_TEMPLATE/bug-report.yml +48 -0
- .github/ISSUE_TEMPLATE/config.yml +11 -0
- .github/ISSUE_TEMPLATE/feature-request.yml +32 -0
- .github/ISSUE_TEMPLATE/user-support.yml +32 -0
- .github/workflows/pullrequest-ci-run.yml +53 -0
- .github/workflows/ruff.yml +23 -0
- .github/workflows/stable-release.yml +104 -0
- .github/workflows/stale-issues.yml +21 -0
- .github/workflows/test-build.yml +31 -0
- .github/workflows/test-ci.yml +96 -0
- .github/workflows/test-launch.yml +45 -0
- .github/workflows/test-unit.yml +30 -0
- .github/workflows/update-version.yml +58 -0
- .github/workflows/windows_release_dependencies.yml +71 -0
- .github/workflows/windows_release_nightly_pytorch.yml +91 -0
- .github/workflows/windows_release_package.yml +100 -0
    	
        .github/ISSUE_TEMPLATE/bug-report.yml
    ADDED
    
    | @@ -0,0 +1,48 @@ | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | 
|  | |
| 1 | 
            +
            name: Bug Report
         | 
| 2 | 
            +
            description: "Something is broken inside of ComfyUI. (Do not use this if you're just having issues and need help, or if the issue relates to a custom node)"
         | 
| 3 | 
            +
            labels: ["Potential Bug"]
         | 
| 4 | 
            +
            body:
         | 
| 5 | 
            +
              - type: markdown
         | 
| 6 | 
            +
                attributes:
         | 
| 7 | 
            +
                  value: |
         | 
| 8 | 
            +
                    Before submitting a **Bug Report**, please ensure the following:
         | 
| 9 | 
            +
             | 
| 10 | 
            +
                    - **1:** You are running the latest version of ComfyUI.
         | 
| 11 | 
            +
                    - **2:** You have looked at the existing bug reports and made sure this isn't already reported.
         | 
| 12 | 
            +
                    - **3:** You confirmed that the bug is not caused by a custom node. You can disable all custom nodes by passing
         | 
| 13 | 
            +
                    `--disable-all-custom-nodes` command line argument.
         | 
| 14 | 
            +
                    - **4:** This is an actual bug in ComfyUI, not just a support question. A bug is when you can specify exact
         | 
| 15 | 
            +
                    steps to replicate what went wrong and others will be able to repeat your steps and see the same issue happen.
         | 
| 16 | 
            +
             | 
| 17 | 
            +
                    If unsure, ask on the [ComfyUI Matrix Space](https://app.element.io/#/room/%23comfyui_space%3Amatrix.org) or the [Comfy Org Discord](https://discord.gg/comfyorg) first.
         | 
| 18 | 
            +
              - type: textarea
         | 
| 19 | 
            +
                attributes:
         | 
| 20 | 
            +
                  label: Expected Behavior
         | 
| 21 | 
            +
                  description: "What you expected to happen."
         | 
| 22 | 
            +
                validations:
         | 
| 23 | 
            +
                  required: true
         | 
| 24 | 
            +
              - type: textarea
         | 
| 25 | 
            +
                attributes:
         | 
| 26 | 
            +
                  label: Actual Behavior
         | 
| 27 | 
            +
                  description: "What actually happened. Please include a screenshot of the issue if possible."
         | 
| 28 | 
            +
                validations:
         | 
| 29 | 
            +
                  required: true
         | 
| 30 | 
            +
              - type: textarea
         | 
| 31 | 
            +
                attributes:
         | 
| 32 | 
            +
                  label: Steps to Reproduce
         | 
| 33 | 
            +
                  description: "Describe how to reproduce the issue. Please be sure to attach a workflow JSON or PNG, ideally one that doesn't require custom nodes to test. If the bug open happens when certain custom nodes are used, most likely that custom node is what has the bug rather than ComfyUI, in which case it should be reported to the node's author."
         | 
| 34 | 
            +
                validations:
         | 
| 35 | 
            +
                  required: true
         | 
| 36 | 
            +
              - type: textarea
         | 
| 37 | 
            +
                attributes:
         | 
| 38 | 
            +
                  label: Debug Logs
         | 
| 39 | 
            +
                  description: "Please copy the output from your terminal logs here."
         | 
| 40 | 
            +
                  render: powershell
         | 
| 41 | 
            +
                validations:
         | 
| 42 | 
            +
                  required: true
         | 
| 43 | 
            +
              - type: textarea
         | 
| 44 | 
            +
                attributes:
         | 
| 45 | 
            +
                  label: Other
         | 
| 46 | 
            +
                  description: "Any other additional information you think might be helpful."
         | 
| 47 | 
            +
                validations:
         | 
| 48 | 
            +
                  required: false
         | 
    	
        .github/ISSUE_TEMPLATE/config.yml
    ADDED
    
    | @@ -0,0 +1,11 @@ | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | 
|  | |
| 1 | 
            +
            blank_issues_enabled: true
         | 
| 2 | 
            +
            contact_links:
         | 
| 3 | 
            +
              - name: ComfyUI Frontend Issues
         | 
| 4 | 
            +
                url: https://github.com/Comfy-Org/ComfyUI_frontend/issues
         | 
| 5 | 
            +
                about: Issues related to the ComfyUI frontend (display issues, user interaction bugs), please go to the frontend repo to file the issue
         | 
| 6 | 
            +
              - name: ComfyUI Matrix Space
         | 
| 7 | 
            +
                url: https://app.element.io/#/room/%23comfyui_space%3Amatrix.org
         | 
| 8 | 
            +
                about: The ComfyUI Matrix Space is available for support and general discussion related to ComfyUI (Matrix is like Discord but open source).
         | 
| 9 | 
            +
              - name: Comfy Org Discord
         | 
| 10 | 
            +
                url: https://discord.gg/comfyorg
         | 
| 11 | 
            +
                about: The Comfy Org Discord is available for support and general discussion related to ComfyUI.
         | 
    	
        .github/ISSUE_TEMPLATE/feature-request.yml
    ADDED
    
    | @@ -0,0 +1,32 @@ | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | 
|  | |
| 1 | 
            +
            name: Feature Request
         | 
| 2 | 
            +
            description: "You have an idea for something new you would like to see added to ComfyUI's core."
         | 
| 3 | 
            +
            labels: [ "Feature" ]
         | 
| 4 | 
            +
            body:
         | 
| 5 | 
            +
                - type: markdown
         | 
| 6 | 
            +
                  attributes:
         | 
| 7 | 
            +
                    value: |
         | 
| 8 | 
            +
                            Before submitting a **Feature Request**, please ensure the following:
         | 
| 9 | 
            +
             | 
| 10 | 
            +
                            **1:** You are running the latest version of ComfyUI.
         | 
| 11 | 
            +
                            **2:** You have looked to make sure there is not already a feature that does what you need, and there is not already a Feature Request listed for the same idea.
         | 
| 12 | 
            +
                            **3:** This is something that makes sense to add to ComfyUI Core, and wouldn't make more sense as a custom node.
         | 
| 13 | 
            +
             | 
| 14 | 
            +
                            If unsure, ask on the [ComfyUI Matrix Space](https://app.element.io/#/room/%23comfyui_space%3Amatrix.org) or the [Comfy Org Discord](https://discord.gg/comfyorg) first.
         | 
| 15 | 
            +
                - type: textarea
         | 
| 16 | 
            +
                  attributes:
         | 
| 17 | 
            +
                        label: Feature Idea
         | 
| 18 | 
            +
                        description: "Describe the feature you want to see."
         | 
| 19 | 
            +
                  validations:
         | 
| 20 | 
            +
                        required: true
         | 
| 21 | 
            +
                - type: textarea
         | 
| 22 | 
            +
                  attributes:
         | 
| 23 | 
            +
                            label: Existing Solutions
         | 
| 24 | 
            +
                            description: "Please search through available custom nodes / extensions to see if there are existing custom solutions for this. If so, please link the options you found here as a reference."
         | 
| 25 | 
            +
                  validations:
         | 
| 26 | 
            +
                            required: false
         | 
| 27 | 
            +
                - type: textarea
         | 
| 28 | 
            +
                  attributes:
         | 
| 29 | 
            +
                            label: Other
         | 
| 30 | 
            +
                            description: "Any other additional information you think might be helpful."
         | 
| 31 | 
            +
                  validations:
         | 
| 32 | 
            +
                            required: false
         | 
    	
        .github/ISSUE_TEMPLATE/user-support.yml
    ADDED
    
    | @@ -0,0 +1,32 @@ | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | 
|  | |
| 1 | 
            +
            name: User Support
         | 
| 2 | 
            +
            description: "Use this if you need help with something, or you're experiencing an issue."
         | 
| 3 | 
            +
            labels: [ "User Support" ]
         | 
| 4 | 
            +
            body:
         | 
| 5 | 
            +
                - type: markdown
         | 
| 6 | 
            +
                  attributes:
         | 
| 7 | 
            +
                    value: |
         | 
| 8 | 
            +
                        Before submitting a **User Report** issue, please ensure the following:
         | 
| 9 | 
            +
             | 
| 10 | 
            +
                        **1:** You are running the latest version of ComfyUI.
         | 
| 11 | 
            +
                        **2:** You have made an effort to find public answers to your question before asking here. In other words, you googled it first, and scrolled through recent help topics.
         | 
| 12 | 
            +
             | 
| 13 | 
            +
                            If unsure, ask on the [ComfyUI Matrix Space](https://app.element.io/#/room/%23comfyui_space%3Amatrix.org) or the [Comfy Org Discord](https://discord.gg/comfyorg) first.
         | 
| 14 | 
            +
                - type: textarea
         | 
| 15 | 
            +
                  attributes:
         | 
| 16 | 
            +
                        label: Your question
         | 
| 17 | 
            +
                        description: "Post your question here. Please be as detailed as possible."
         | 
| 18 | 
            +
                  validations:
         | 
| 19 | 
            +
                        required: true
         | 
| 20 | 
            +
                - type: textarea
         | 
| 21 | 
            +
                  attributes:
         | 
| 22 | 
            +
                            label: Logs
         | 
| 23 | 
            +
                            description: "If your question relates to an issue you're experiencing, please go to `Server` -> `Logs` -> potentially set `View Type` to `Debug` as well, then copypaste all the text into here."
         | 
| 24 | 
            +
                            render: powershell
         | 
| 25 | 
            +
                  validations:
         | 
| 26 | 
            +
                            required: false
         | 
| 27 | 
            +
                - type: textarea
         | 
| 28 | 
            +
                  attributes:
         | 
| 29 | 
            +
                            label: Other
         | 
| 30 | 
            +
                            description: "Any other additional information you think might be helpful."
         | 
| 31 | 
            +
                  validations:
         | 
| 32 | 
            +
                            required: false
         | 
    	
        .github/workflows/pullrequest-ci-run.yml
    ADDED
    
    | @@ -0,0 +1,53 @@ | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | 
|  | |
| 1 | 
            +
            # This is the GitHub Workflow that drives full-GPU-enabled tests of pull requests to ComfyUI, when the 'Run-CI-Test' label is added
         | 
| 2 | 
            +
            # Results are reported as checkmarks on the commits, as well as onto https://ci.comfy.org/
         | 
| 3 | 
            +
            name: Pull Request CI Workflow Runs
         | 
| 4 | 
            +
            on:
         | 
| 5 | 
            +
                pull_request_target:
         | 
| 6 | 
            +
                    types: [labeled]
         | 
| 7 | 
            +
             | 
| 8 | 
            +
            jobs:
         | 
| 9 | 
            +
              pr-test-stable:
         | 
| 10 | 
            +
                if: ${{ github.event.label.name == 'Run-CI-Test' }}
         | 
| 11 | 
            +
                strategy:
         | 
| 12 | 
            +
                  fail-fast: false
         | 
| 13 | 
            +
                  matrix:
         | 
| 14 | 
            +
                    os: [macos, linux, windows]
         | 
| 15 | 
            +
                    python_version: ["3.9", "3.10", "3.11", "3.12"]
         | 
| 16 | 
            +
                    cuda_version: ["12.1"]
         | 
| 17 | 
            +
                    torch_version: ["stable"]
         | 
| 18 | 
            +
                    include:
         | 
| 19 | 
            +
                      - os: macos
         | 
| 20 | 
            +
                        runner_label: [self-hosted, macOS]
         | 
| 21 | 
            +
                        flags: "--use-pytorch-cross-attention"
         | 
| 22 | 
            +
                      - os: linux
         | 
| 23 | 
            +
                        runner_label: [self-hosted, Linux]
         | 
| 24 | 
            +
                        flags: ""
         | 
| 25 | 
            +
                      - os: windows
         | 
| 26 | 
            +
                        runner_label: [self-hosted, Windows]
         | 
| 27 | 
            +
                        flags: ""
         | 
| 28 | 
            +
                runs-on: ${{ matrix.runner_label }}
         | 
| 29 | 
            +
                steps:
         | 
| 30 | 
            +
                  - name: Test Workflows
         | 
| 31 | 
            +
                    uses: comfy-org/comfy-action@main
         | 
| 32 | 
            +
                    with:
         | 
| 33 | 
            +
                      os: ${{ matrix.os }}
         | 
| 34 | 
            +
                      python_version: ${{ matrix.python_version }}
         | 
| 35 | 
            +
                      torch_version: ${{ matrix.torch_version }}
         | 
| 36 | 
            +
                      google_credentials: ${{ secrets.GCS_SERVICE_ACCOUNT_JSON }}
         | 
| 37 | 
            +
                      comfyui_flags: ${{ matrix.flags }}
         | 
| 38 | 
            +
                      use_prior_commit: 'true'
         | 
| 39 | 
            +
              comment:
         | 
| 40 | 
            +
                if: ${{ github.event.label.name == 'Run-CI-Test' }}
         | 
| 41 | 
            +
                runs-on: ubuntu-latest
         | 
| 42 | 
            +
                permissions:
         | 
| 43 | 
            +
                  pull-requests: write
         | 
| 44 | 
            +
                steps:
         | 
| 45 | 
            +
                  - uses: actions/github-script@v6
         | 
| 46 | 
            +
                    with:
         | 
| 47 | 
            +
                      script: |
         | 
| 48 | 
            +
                        github.rest.issues.createComment({
         | 
| 49 | 
            +
                          issue_number: context.issue.number,
         | 
| 50 | 
            +
                          owner: context.repo.owner,
         | 
| 51 | 
            +
                          repo: context.repo.repo,
         | 
| 52 | 
            +
                          body: '(Automated Bot Message) CI Tests are running, you can view the results at https://ci.comfy.org/?branch=${{ github.event.pull_request.number }}%2Fmerge'
         | 
| 53 | 
            +
                        })
         | 
    	
        .github/workflows/ruff.yml
    ADDED
    
    | @@ -0,0 +1,23 @@ | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | 
|  | |
| 1 | 
            +
            name: Python Linting
         | 
| 2 | 
            +
             | 
| 3 | 
            +
            on: [push, pull_request]
         | 
| 4 | 
            +
             | 
| 5 | 
            +
            jobs:
         | 
| 6 | 
            +
              ruff:
         | 
| 7 | 
            +
                name: Run Ruff
         | 
| 8 | 
            +
                runs-on: ubuntu-latest
         | 
| 9 | 
            +
             | 
| 10 | 
            +
                steps:
         | 
| 11 | 
            +
                - name: Checkout repository
         | 
| 12 | 
            +
                  uses: actions/checkout@v4
         | 
| 13 | 
            +
             | 
| 14 | 
            +
                - name: Set up Python
         | 
| 15 | 
            +
                  uses: actions/setup-python@v2
         | 
| 16 | 
            +
                  with:
         | 
| 17 | 
            +
                    python-version: 3.x
         | 
| 18 | 
            +
             | 
| 19 | 
            +
                - name: Install Ruff
         | 
| 20 | 
            +
                  run: pip install ruff
         | 
| 21 | 
            +
             | 
| 22 | 
            +
                - name: Run Ruff
         | 
| 23 | 
            +
                  run: ruff check .
         | 
    	
        .github/workflows/stable-release.yml
    ADDED
    
    | @@ -0,0 +1,104 @@ | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | 
|  | |
| 1 | 
            +
             | 
| 2 | 
            +
            name: "Release Stable Version"
         | 
| 3 | 
            +
             | 
| 4 | 
            +
            on:
         | 
| 5 | 
            +
              workflow_dispatch:
         | 
| 6 | 
            +
                inputs:
         | 
| 7 | 
            +
                  git_tag:
         | 
| 8 | 
            +
                    description: 'Git tag'
         | 
| 9 | 
            +
                    required: true
         | 
| 10 | 
            +
                    type: string
         | 
| 11 | 
            +
                  cu:
         | 
| 12 | 
            +
                    description: 'CUDA version'
         | 
| 13 | 
            +
                    required: true
         | 
| 14 | 
            +
                    type: string
         | 
| 15 | 
            +
                    default: "126"
         | 
| 16 | 
            +
                  python_minor:
         | 
| 17 | 
            +
                    description: 'Python minor version'
         | 
| 18 | 
            +
                    required: true
         | 
| 19 | 
            +
                    type: string
         | 
| 20 | 
            +
                    default: "12"
         | 
| 21 | 
            +
                  python_patch:
         | 
| 22 | 
            +
                    description: 'Python patch version'
         | 
| 23 | 
            +
                    required: true
         | 
| 24 | 
            +
                    type: string
         | 
| 25 | 
            +
                    default: "9"
         | 
| 26 | 
            +
             | 
| 27 | 
            +
             | 
| 28 | 
            +
            jobs:
         | 
| 29 | 
            +
              package_comfy_windows:
         | 
| 30 | 
            +
                permissions:
         | 
| 31 | 
            +
                  contents: "write"
         | 
| 32 | 
            +
                  packages: "write"
         | 
| 33 | 
            +
                  pull-requests: "read"
         | 
| 34 | 
            +
                runs-on: windows-latest
         | 
| 35 | 
            +
                steps:
         | 
| 36 | 
            +
                  - uses: actions/checkout@v4
         | 
| 37 | 
            +
                    with:
         | 
| 38 | 
            +
                      ref: ${{ inputs.git_tag }}
         | 
| 39 | 
            +
                      fetch-depth: 0
         | 
| 40 | 
            +
                      persist-credentials: false
         | 
| 41 | 
            +
                  - uses: actions/cache/restore@v4
         | 
| 42 | 
            +
                    id: cache
         | 
| 43 | 
            +
                    with:
         | 
| 44 | 
            +
                      path: |
         | 
| 45 | 
            +
                        cu${{ inputs.cu }}_python_deps.tar
         | 
| 46 | 
            +
                        update_comfyui_and_python_dependencies.bat
         | 
| 47 | 
            +
                      key: ${{ runner.os }}-build-cu${{ inputs.cu }}-${{ inputs.python_minor }}
         | 
| 48 | 
            +
                  - shell: bash
         | 
| 49 | 
            +
                    run: |
         | 
| 50 | 
            +
                      mv cu${{ inputs.cu }}_python_deps.tar ../
         | 
| 51 | 
            +
                      mv update_comfyui_and_python_dependencies.bat ../
         | 
| 52 | 
            +
                      cd ..
         | 
| 53 | 
            +
                      tar xf cu${{ inputs.cu }}_python_deps.tar
         | 
| 54 | 
            +
                      pwd
         | 
| 55 | 
            +
                      ls
         | 
| 56 | 
            +
             | 
| 57 | 
            +
                  - shell: bash
         | 
| 58 | 
            +
                    run: |
         | 
| 59 | 
            +
                      cd ..
         | 
| 60 | 
            +
                      cp -r ComfyUI ComfyUI_copy
         | 
| 61 | 
            +
                      curl https://www.python.org/ftp/python/3.${{ inputs.python_minor }}.${{ inputs.python_patch }}/python-3.${{ inputs.python_minor }}.${{ inputs.python_patch }}-embed-amd64.zip -o python_embeded.zip
         | 
| 62 | 
            +
                      unzip python_embeded.zip -d python_embeded
         | 
| 63 | 
            +
                      cd python_embeded
         | 
| 64 | 
            +
                      echo ${{ env.MINOR_VERSION }}
         | 
| 65 | 
            +
                      echo 'import site' >> ./python3${{ inputs.python_minor }}._pth
         | 
| 66 | 
            +
                      curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py
         | 
| 67 | 
            +
                      ./python.exe get-pip.py
         | 
| 68 | 
            +
                      ./python.exe -s -m pip install ../cu${{ inputs.cu }}_python_deps/*
         | 
| 69 | 
            +
                        sed -i '1i../ComfyUI' ./python3${{ inputs.python_minor }}._pth
         | 
| 70 | 
            +
                        cd ..
         | 
| 71 | 
            +
             | 
| 72 | 
            +
                      git clone --depth 1 https://github.com/comfyanonymous/taesd
         | 
| 73 | 
            +
                      cp taesd/*.pth ./ComfyUI_copy/models/vae_approx/
         | 
| 74 | 
            +
             | 
| 75 | 
            +
                      mkdir ComfyUI_windows_portable
         | 
| 76 | 
            +
                      mv python_embeded ComfyUI_windows_portable
         | 
| 77 | 
            +
                      mv ComfyUI_copy ComfyUI_windows_portable/ComfyUI
         | 
| 78 | 
            +
             | 
| 79 | 
            +
                      cd ComfyUI_windows_portable
         | 
| 80 | 
            +
             | 
| 81 | 
            +
                      mkdir update
         | 
| 82 | 
            +
                      cp -r ComfyUI/.ci/update_windows/* ./update/
         | 
| 83 | 
            +
                      cp -r ComfyUI/.ci/windows_base_files/* ./
         | 
| 84 | 
            +
                      cp ../update_comfyui_and_python_dependencies.bat ./update/
         | 
| 85 | 
            +
             | 
| 86 | 
            +
                      cd ..
         | 
| 87 | 
            +
             | 
| 88 | 
            +
                      "C:\Program Files\7-Zip\7z.exe" a -t7z -m0=lzma2 -mx=8 -mfb=64 -md=32m -ms=on -mf=BCJ2 ComfyUI_windows_portable.7z ComfyUI_windows_portable
         | 
| 89 | 
            +
                      mv ComfyUI_windows_portable.7z ComfyUI/ComfyUI_windows_portable_nvidia.7z
         | 
| 90 | 
            +
             | 
| 91 | 
            +
                      cd ComfyUI_windows_portable
         | 
| 92 | 
            +
                      python_embeded/python.exe -s ComfyUI/main.py --quick-test-for-ci --cpu
         | 
| 93 | 
            +
             | 
| 94 | 
            +
                      ls
         | 
| 95 | 
            +
             | 
| 96 | 
            +
                  - name: Upload binaries to release
         | 
| 97 | 
            +
                    uses: svenstaro/upload-release-action@v2
         | 
| 98 | 
            +
                    with:
         | 
| 99 | 
            +
                      repo_token: ${{ secrets.GITHUB_TOKEN }}
         | 
| 100 | 
            +
                      file: ComfyUI_windows_portable_nvidia.7z
         | 
| 101 | 
            +
                      tag: ${{ inputs.git_tag }}
         | 
| 102 | 
            +
                      overwrite: true
         | 
| 103 | 
            +
                      prerelease: true
         | 
| 104 | 
            +
                      make_latest: false
         | 
    	
        .github/workflows/stale-issues.yml
    ADDED
    
    | @@ -0,0 +1,21 @@ | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | 
|  | |
| 1 | 
            +
            name: 'Close stale issues'
         | 
| 2 | 
            +
            on:
         | 
| 3 | 
            +
              schedule:
         | 
| 4 | 
            +
                # Run daily at 430 am PT
         | 
| 5 | 
            +
                - cron: '30 11 * * *'
         | 
| 6 | 
            +
            permissions:
         | 
| 7 | 
            +
              issues: write
         | 
| 8 | 
            +
             | 
| 9 | 
            +
            jobs:
         | 
| 10 | 
            +
              stale:
         | 
| 11 | 
            +
                runs-on: ubuntu-latest
         | 
| 12 | 
            +
                steps:
         | 
| 13 | 
            +
                  - uses: actions/stale@v9
         | 
| 14 | 
            +
                    with:
         | 
| 15 | 
            +
                      stale-issue-message: "This issue is being marked stale because it has not had any activity for 30 days. Reply below within 7 days if your issue still isn't solved, and it will be left open. Otherwise, the issue will be closed automatically."
         | 
| 16 | 
            +
                      days-before-stale: 30
         | 
| 17 | 
            +
                      days-before-close: 7
         | 
| 18 | 
            +
                      stale-issue-label: 'Stale'
         | 
| 19 | 
            +
                      only-labels: 'User Support'
         | 
| 20 | 
            +
                      exempt-all-assignees: true
         | 
| 21 | 
            +
                      exempt-all-milestones: true
         | 
    	
        .github/workflows/test-build.yml
    ADDED
    
    | @@ -0,0 +1,31 @@ | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | 
|  | |
| 1 | 
            +
            name: Build package
         | 
| 2 | 
            +
             | 
| 3 | 
            +
            #
         | 
| 4 | 
            +
            # This workflow is a test of the python package build.
         | 
| 5 | 
            +
            # Install Python dependencies across different Python versions.
         | 
| 6 | 
            +
            #
         | 
| 7 | 
            +
             | 
| 8 | 
            +
            on:
         | 
| 9 | 
            +
              push:
         | 
| 10 | 
            +
                paths:
         | 
| 11 | 
            +
                  - "requirements.txt"
         | 
| 12 | 
            +
                  - ".github/workflows/test-build.yml"
         | 
| 13 | 
            +
             | 
| 14 | 
            +
            jobs:
         | 
| 15 | 
            +
              build:
         | 
| 16 | 
            +
                name: Build Test
         | 
| 17 | 
            +
                runs-on: ubuntu-latest
         | 
| 18 | 
            +
                strategy:
         | 
| 19 | 
            +
                  fail-fast: false
         | 
| 20 | 
            +
                  matrix:
         | 
| 21 | 
            +
                    python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
         | 
| 22 | 
            +
                steps:
         | 
| 23 | 
            +
                  - uses: actions/checkout@v4
         | 
| 24 | 
            +
                  - name: Set up Python ${{ matrix.python-version }}
         | 
| 25 | 
            +
                    uses: actions/setup-python@v4
         | 
| 26 | 
            +
                    with:
         | 
| 27 | 
            +
                      python-version: ${{ matrix.python-version }}
         | 
| 28 | 
            +
                  - name: Install dependencies
         | 
| 29 | 
            +
                    run: |
         | 
| 30 | 
            +
                      python -m pip install --upgrade pip
         | 
| 31 | 
            +
                      pip install -r requirements.txt
         | 
    	
        .github/workflows/test-ci.yml
    ADDED
    
    | @@ -0,0 +1,96 @@ | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | 
|  | |
| 1 | 
            +
            # This is the GitHub Workflow that drives automatic full-GPU-enabled tests of all new commits to the master branch of ComfyUI
         | 
| 2 | 
            +
            # Results are reported as checkmarks on the commits, as well as onto https://ci.comfy.org/
         | 
| 3 | 
            +
            name: Full Comfy CI Workflow Runs
         | 
| 4 | 
            +
            on:
         | 
| 5 | 
            +
              push:
         | 
| 6 | 
            +
                branches:
         | 
| 7 | 
            +
                  - master
         | 
| 8 | 
            +
                paths-ignore:
         | 
| 9 | 
            +
                  - 'app/**'
         | 
| 10 | 
            +
                  - 'input/**'
         | 
| 11 | 
            +
                  - 'output/**'
         | 
| 12 | 
            +
                  - 'notebooks/**'
         | 
| 13 | 
            +
                  - 'script_examples/**'
         | 
| 14 | 
            +
                  - '.github/**'
         | 
| 15 | 
            +
                  - 'web/**'
         | 
| 16 | 
            +
              workflow_dispatch:
         | 
| 17 | 
            +
             | 
| 18 | 
            +
            jobs:
         | 
| 19 | 
            +
              test-stable:
         | 
| 20 | 
            +
                strategy:
         | 
| 21 | 
            +
                  fail-fast: false
         | 
| 22 | 
            +
                  matrix:
         | 
| 23 | 
            +
                    # os: [macos, linux, windows]
         | 
| 24 | 
            +
                    os: [macos, linux]
         | 
| 25 | 
            +
                    python_version: ["3.9", "3.10", "3.11", "3.12"]
         | 
| 26 | 
            +
                    cuda_version: ["12.1"]
         | 
| 27 | 
            +
                    torch_version: ["stable"]
         | 
| 28 | 
            +
                    include:
         | 
| 29 | 
            +
                      - os: macos
         | 
| 30 | 
            +
                        runner_label: [self-hosted, macOS]
         | 
| 31 | 
            +
                        flags: "--use-pytorch-cross-attention"
         | 
| 32 | 
            +
                      - os: linux
         | 
| 33 | 
            +
                        runner_label: [self-hosted, Linux]
         | 
| 34 | 
            +
                        flags: ""
         | 
| 35 | 
            +
                      # - os: windows
         | 
| 36 | 
            +
                      #   runner_label: [self-hosted, Windows]
         | 
| 37 | 
            +
                      #   flags: ""
         | 
| 38 | 
            +
                runs-on: ${{ matrix.runner_label }}
         | 
| 39 | 
            +
                steps:
         | 
| 40 | 
            +
                  - name: Test Workflows
         | 
| 41 | 
            +
                    uses: comfy-org/comfy-action@main
         | 
| 42 | 
            +
                    with:
         | 
| 43 | 
            +
                      os: ${{ matrix.os }}
         | 
| 44 | 
            +
                      python_version: ${{ matrix.python_version }}
         | 
| 45 | 
            +
                      torch_version: ${{ matrix.torch_version }}
         | 
| 46 | 
            +
                      google_credentials: ${{ secrets.GCS_SERVICE_ACCOUNT_JSON }}
         | 
| 47 | 
            +
                      comfyui_flags: ${{ matrix.flags }}
         | 
| 48 | 
            +
             | 
| 49 | 
            +
              # test-win-nightly:
         | 
| 50 | 
            +
              #   strategy:
         | 
| 51 | 
            +
              #     fail-fast: true
         | 
| 52 | 
            +
              #     matrix:
         | 
| 53 | 
            +
              #       os: [windows]
         | 
| 54 | 
            +
              #       python_version: ["3.9", "3.10", "3.11", "3.12"]
         | 
| 55 | 
            +
              #       cuda_version: ["12.1"]
         | 
| 56 | 
            +
              #       torch_version: ["nightly"]
         | 
| 57 | 
            +
              #       include:
         | 
| 58 | 
            +
              #         - os: windows
         | 
| 59 | 
            +
              #           runner_label: [self-hosted, Windows]
         | 
| 60 | 
            +
              #           flags: ""
         | 
| 61 | 
            +
              #   runs-on: ${{ matrix.runner_label }}
         | 
| 62 | 
            +
              #   steps:
         | 
| 63 | 
            +
              #     - name: Test Workflows
         | 
| 64 | 
            +
              #       uses: comfy-org/comfy-action@main
         | 
| 65 | 
            +
              #       with:
         | 
| 66 | 
            +
              #         os: ${{ matrix.os }}
         | 
| 67 | 
            +
              #         python_version: ${{ matrix.python_version }}
         | 
| 68 | 
            +
              #         torch_version: ${{ matrix.torch_version }}
         | 
| 69 | 
            +
              #         google_credentials: ${{ secrets.GCS_SERVICE_ACCOUNT_JSON }}
         | 
| 70 | 
            +
              #         comfyui_flags: ${{ matrix.flags }}
         | 
| 71 | 
            +
             | 
| 72 | 
            +
              test-unix-nightly:
         | 
| 73 | 
            +
                strategy:
         | 
| 74 | 
            +
                  fail-fast: false
         | 
| 75 | 
            +
                  matrix:
         | 
| 76 | 
            +
                    os: [macos, linux]
         | 
| 77 | 
            +
                    python_version: ["3.11"]
         | 
| 78 | 
            +
                    cuda_version: ["12.1"]
         | 
| 79 | 
            +
                    torch_version: ["nightly"]
         | 
| 80 | 
            +
                    include:
         | 
| 81 | 
            +
                      - os: macos
         | 
| 82 | 
            +
                        runner_label: [self-hosted, macOS]
         | 
| 83 | 
            +
                        flags: "--use-pytorch-cross-attention"
         | 
| 84 | 
            +
                      - os: linux
         | 
| 85 | 
            +
                        runner_label: [self-hosted, Linux]
         | 
| 86 | 
            +
                        flags: ""
         | 
| 87 | 
            +
                runs-on: ${{ matrix.runner_label }}
         | 
| 88 | 
            +
                steps:
         | 
| 89 | 
            +
                  - name: Test Workflows
         | 
| 90 | 
            +
                    uses: comfy-org/comfy-action@main
         | 
| 91 | 
            +
                    with:
         | 
| 92 | 
            +
                      os: ${{ matrix.os }}
         | 
| 93 | 
            +
                      python_version: ${{ matrix.python_version }}
         | 
| 94 | 
            +
                      torch_version: ${{ matrix.torch_version }}
         | 
| 95 | 
            +
                      google_credentials: ${{ secrets.GCS_SERVICE_ACCOUNT_JSON }}
         | 
| 96 | 
            +
                      comfyui_flags: ${{ matrix.flags }}
         | 
    	
        .github/workflows/test-launch.yml
    ADDED
    
    | @@ -0,0 +1,45 @@ | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | 
|  | |
| 1 | 
            +
            name: Test server launches without errors
         | 
| 2 | 
            +
             | 
| 3 | 
            +
            on:
         | 
| 4 | 
            +
              push:
         | 
| 5 | 
            +
                branches: [ main, master ]
         | 
| 6 | 
            +
              pull_request:
         | 
| 7 | 
            +
                branches: [ main, master ]
         | 
| 8 | 
            +
             | 
| 9 | 
            +
            jobs:
         | 
| 10 | 
            +
              test:
         | 
| 11 | 
            +
                runs-on: ubuntu-latest
         | 
| 12 | 
            +
                steps:
         | 
| 13 | 
            +
                - name: Checkout ComfyUI
         | 
| 14 | 
            +
                  uses: actions/checkout@v4
         | 
| 15 | 
            +
                  with:
         | 
| 16 | 
            +
                    repository: "comfyanonymous/ComfyUI"
         | 
| 17 | 
            +
                    path: "ComfyUI"
         | 
| 18 | 
            +
                - uses: actions/setup-python@v4
         | 
| 19 | 
            +
                  with:
         | 
| 20 | 
            +
                    python-version: '3.9'
         | 
| 21 | 
            +
                - name: Install requirements
         | 
| 22 | 
            +
                  run: |
         | 
| 23 | 
            +
                    python -m pip install --upgrade pip
         | 
| 24 | 
            +
                    pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cpu
         | 
| 25 | 
            +
                    pip install -r requirements.txt
         | 
| 26 | 
            +
                    pip install wait-for-it
         | 
| 27 | 
            +
                  working-directory: ComfyUI
         | 
| 28 | 
            +
                - name: Start ComfyUI server
         | 
| 29 | 
            +
                  run: |
         | 
| 30 | 
            +
                    python main.py --cpu 2>&1 | tee console_output.log &
         | 
| 31 | 
            +
                    wait-for-it --service 127.0.0.1:8188 -t 30
         | 
| 32 | 
            +
                  working-directory: ComfyUI
         | 
| 33 | 
            +
                - name: Check for unhandled exceptions in server log
         | 
| 34 | 
            +
                  run: |
         | 
| 35 | 
            +
                    if grep -qE "Exception|Error" console_output.log; then
         | 
| 36 | 
            +
                      echo "Unhandled exception/error found in server log."
         | 
| 37 | 
            +
                      exit 1
         | 
| 38 | 
            +
                    fi
         | 
| 39 | 
            +
                  working-directory: ComfyUI
         | 
| 40 | 
            +
                - uses: actions/upload-artifact@v4
         | 
| 41 | 
            +
                  if: always()
         | 
| 42 | 
            +
                  with:
         | 
| 43 | 
            +
                    name: console-output
         | 
| 44 | 
            +
                    path: ComfyUI/console_output.log
         | 
| 45 | 
            +
                    retention-days: 30
         | 
    	
        .github/workflows/test-unit.yml
    ADDED
    
    | @@ -0,0 +1,30 @@ | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | 
|  | |
| 1 | 
            +
            name: Unit Tests
         | 
| 2 | 
            +
             | 
| 3 | 
            +
            on:
         | 
| 4 | 
            +
              push:
         | 
| 5 | 
            +
                branches: [ main, master ]
         | 
| 6 | 
            +
              pull_request:
         | 
| 7 | 
            +
                branches: [ main, master ]
         | 
| 8 | 
            +
             | 
| 9 | 
            +
            jobs:
         | 
| 10 | 
            +
              test:
         | 
| 11 | 
            +
                strategy:
         | 
| 12 | 
            +
                  matrix:
         | 
| 13 | 
            +
                    os: [ubuntu-latest, windows-latest, macos-latest]
         | 
| 14 | 
            +
                runs-on: ${{ matrix.os }}
         | 
| 15 | 
            +
                continue-on-error: true
         | 
| 16 | 
            +
                steps:
         | 
| 17 | 
            +
                - uses: actions/checkout@v4
         | 
| 18 | 
            +
                - name: Set up Python      
         | 
| 19 | 
            +
                  uses: actions/setup-python@v4
         | 
| 20 | 
            +
                  with:
         | 
| 21 | 
            +
                    python-version: '3.12'
         | 
| 22 | 
            +
                - name: Install requirements
         | 
| 23 | 
            +
                  run: |
         | 
| 24 | 
            +
                    python -m pip install --upgrade pip
         | 
| 25 | 
            +
                    pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cpu
         | 
| 26 | 
            +
                    pip install -r requirements.txt
         | 
| 27 | 
            +
                - name: Run Unit Tests
         | 
| 28 | 
            +
                  run: |
         | 
| 29 | 
            +
                    pip install -r tests-unit/requirements.txt
         | 
| 30 | 
            +
                    python -m pytest tests-unit
         | 
    	
        .github/workflows/update-version.yml
    ADDED
    
    | @@ -0,0 +1,58 @@ | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | 
|  | |
| 1 | 
            +
            name: Update Version File
         | 
| 2 | 
            +
             | 
| 3 | 
            +
            on:
         | 
| 4 | 
            +
              pull_request:
         | 
| 5 | 
            +
                paths:
         | 
| 6 | 
            +
                  - "pyproject.toml"
         | 
| 7 | 
            +
                branches:
         | 
| 8 | 
            +
                  - master
         | 
| 9 | 
            +
             | 
| 10 | 
            +
            jobs:
         | 
| 11 | 
            +
              update-version:
         | 
| 12 | 
            +
                runs-on: ubuntu-latest
         | 
| 13 | 
            +
                # Don't run on fork PRs
         | 
| 14 | 
            +
                if: github.event.pull_request.head.repo.full_name == github.repository
         | 
| 15 | 
            +
                permissions:
         | 
| 16 | 
            +
                  pull-requests: write
         | 
| 17 | 
            +
                  contents: write
         | 
| 18 | 
            +
             | 
| 19 | 
            +
                steps:
         | 
| 20 | 
            +
                  - name: Checkout repository
         | 
| 21 | 
            +
                    uses: actions/checkout@v4
         | 
| 22 | 
            +
             | 
| 23 | 
            +
                  - name: Set up Python
         | 
| 24 | 
            +
                    uses: actions/setup-python@v4
         | 
| 25 | 
            +
                    with:
         | 
| 26 | 
            +
                      python-version: "3.11"
         | 
| 27 | 
            +
             | 
| 28 | 
            +
                  - name: Install dependencies
         | 
| 29 | 
            +
                    run: |
         | 
| 30 | 
            +
                      python -m pip install --upgrade pip
         | 
| 31 | 
            +
             | 
| 32 | 
            +
                  - name: Update comfyui_version.py
         | 
| 33 | 
            +
                    run: |
         | 
| 34 | 
            +
                      # Read version from pyproject.toml and update comfyui_version.py
         | 
| 35 | 
            +
                      python -c '
         | 
| 36 | 
            +
                      import tomllib
         | 
| 37 | 
            +
             | 
| 38 | 
            +
                      # Read version from pyproject.toml
         | 
| 39 | 
            +
                      with open("pyproject.toml", "rb") as f:
         | 
| 40 | 
            +
                          config = tomllib.load(f)
         | 
| 41 | 
            +
                          version = config["project"]["version"]
         | 
| 42 | 
            +
             | 
| 43 | 
            +
                      # Write version to comfyui_version.py
         | 
| 44 | 
            +
                      with open("comfyui_version.py", "w") as f:
         | 
| 45 | 
            +
                          f.write("# This file is automatically generated by the build process when version is\n")
         | 
| 46 | 
            +
                          f.write("# updated in pyproject.toml.\n")
         | 
| 47 | 
            +
                          f.write(f"__version__ = \"{version}\"\n")
         | 
| 48 | 
            +
                      '
         | 
| 49 | 
            +
             | 
| 50 | 
            +
                  - name: Commit changes
         | 
| 51 | 
            +
                    run: |
         | 
| 52 | 
            +
                      git config --local user.name "github-actions"
         | 
| 53 | 
            +
                      git config --local user.email "github-actions@github.com"
         | 
| 54 | 
            +
                      git fetch origin ${{ github.head_ref }}
         | 
| 55 | 
            +
                      git checkout -B ${{ github.head_ref }} origin/${{ github.head_ref }}
         | 
| 56 | 
            +
                      git add comfyui_version.py
         | 
| 57 | 
            +
                      git diff --quiet && git diff --staged --quiet || git commit -m "chore: Update comfyui_version.py to match pyproject.toml"
         | 
| 58 | 
            +
                      git push origin HEAD:${{ github.head_ref }}
         | 
    	
        .github/workflows/windows_release_dependencies.yml
    ADDED
    
    | @@ -0,0 +1,71 @@ | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | 
|  | |
| 1 | 
            +
            name: "Windows Release dependencies"
         | 
| 2 | 
            +
             | 
| 3 | 
            +
            on:
         | 
| 4 | 
            +
              workflow_dispatch:
         | 
| 5 | 
            +
                inputs:
         | 
| 6 | 
            +
                  xformers:
         | 
| 7 | 
            +
                    description: 'xformers version'
         | 
| 8 | 
            +
                    required: false
         | 
| 9 | 
            +
                    type: string
         | 
| 10 | 
            +
                    default: ""
         | 
| 11 | 
            +
                  extra_dependencies:
         | 
| 12 | 
            +
                    description: 'extra dependencies'
         | 
| 13 | 
            +
                    required: false
         | 
| 14 | 
            +
                    type: string
         | 
| 15 | 
            +
                    default: ""
         | 
| 16 | 
            +
                  cu:
         | 
| 17 | 
            +
                    description: 'cuda version'
         | 
| 18 | 
            +
                    required: true
         | 
| 19 | 
            +
                    type: string
         | 
| 20 | 
            +
                    default: "126"
         | 
| 21 | 
            +
             | 
| 22 | 
            +
                  python_minor:
         | 
| 23 | 
            +
                    description: 'python minor version'
         | 
| 24 | 
            +
                    required: true
         | 
| 25 | 
            +
                    type: string
         | 
| 26 | 
            +
                    default: "12"
         | 
| 27 | 
            +
             | 
| 28 | 
            +
                  python_patch:
         | 
| 29 | 
            +
                    description: 'python patch version'
         | 
| 30 | 
            +
                    required: true
         | 
| 31 | 
            +
                    type: string
         | 
| 32 | 
            +
                    default: "9"
         | 
| 33 | 
            +
            #  push:
         | 
| 34 | 
            +
            #    branches:
         | 
| 35 | 
            +
            #      - master
         | 
| 36 | 
            +
             | 
| 37 | 
            +
            jobs:
         | 
| 38 | 
            +
              build_dependencies:
         | 
| 39 | 
            +
                runs-on: windows-latest
         | 
| 40 | 
            +
                steps:
         | 
| 41 | 
            +
                    - uses: actions/checkout@v4
         | 
| 42 | 
            +
                    - uses: actions/setup-python@v5
         | 
| 43 | 
            +
                      with:
         | 
| 44 | 
            +
                        python-version: 3.${{ inputs.python_minor }}.${{ inputs.python_patch }}
         | 
| 45 | 
            +
             | 
| 46 | 
            +
                    - shell: bash
         | 
| 47 | 
            +
                      run: |
         | 
| 48 | 
            +
                        echo "@echo off
         | 
| 49 | 
            +
                        call update_comfyui.bat nopause
         | 
| 50 | 
            +
                        echo -
         | 
| 51 | 
            +
                        echo This will try to update pytorch and all python dependencies.
         | 
| 52 | 
            +
                        echo -
         | 
| 53 | 
            +
                        echo If you just want to update normally, close this and run update_comfyui.bat instead.
         | 
| 54 | 
            +
                        echo -
         | 
| 55 | 
            +
                        pause
         | 
| 56 | 
            +
                        ..\python_embeded\python.exe -s -m pip install --upgrade torch torchvision torchaudio ${{ inputs.xformers }} --extra-index-url https://download.pytorch.org/whl/cu${{ inputs.cu }} -r ../ComfyUI/requirements.txt pygit2
         | 
| 57 | 
            +
                        pause" > update_comfyui_and_python_dependencies.bat
         | 
| 58 | 
            +
             | 
| 59 | 
            +
                        python -m pip wheel --no-cache-dir torch torchvision torchaudio ${{ inputs.xformers }} ${{ inputs.extra_dependencies }} --extra-index-url https://download.pytorch.org/whl/cu${{ inputs.cu }} -r requirements.txt pygit2 -w ./temp_wheel_dir
         | 
| 60 | 
            +
                        python -m pip install --no-cache-dir ./temp_wheel_dir/*
         | 
| 61 | 
            +
                        echo installed basic
         | 
| 62 | 
            +
                        ls -lah temp_wheel_dir
         | 
| 63 | 
            +
                        mv temp_wheel_dir cu${{ inputs.cu }}_python_deps
         | 
| 64 | 
            +
                        tar cf cu${{ inputs.cu }}_python_deps.tar cu${{ inputs.cu }}_python_deps
         | 
| 65 | 
            +
             | 
| 66 | 
            +
                    - uses: actions/cache/save@v4
         | 
| 67 | 
            +
                      with:
         | 
| 68 | 
            +
                        path: |
         | 
| 69 | 
            +
                          cu${{ inputs.cu }}_python_deps.tar
         | 
| 70 | 
            +
                          update_comfyui_and_python_dependencies.bat
         | 
| 71 | 
            +
                        key: ${{ runner.os }}-build-cu${{ inputs.cu }}-${{ inputs.python_minor }}
         | 
    	
        .github/workflows/windows_release_nightly_pytorch.yml
    ADDED
    
    | @@ -0,0 +1,91 @@ | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | 
|  | |
| 1 | 
            +
            name: "Windows Release Nightly pytorch"
         | 
| 2 | 
            +
             | 
| 3 | 
            +
            on:
         | 
| 4 | 
            +
              workflow_dispatch:
         | 
| 5 | 
            +
                inputs:
         | 
| 6 | 
            +
                  cu:
         | 
| 7 | 
            +
                    description: 'cuda version'
         | 
| 8 | 
            +
                    required: true
         | 
| 9 | 
            +
                    type: string
         | 
| 10 | 
            +
                    default: "128"
         | 
| 11 | 
            +
             | 
| 12 | 
            +
                  python_minor:
         | 
| 13 | 
            +
                    description: 'python minor version'
         | 
| 14 | 
            +
                    required: true
         | 
| 15 | 
            +
                    type: string
         | 
| 16 | 
            +
                    default: "13"
         | 
| 17 | 
            +
             | 
| 18 | 
            +
                  python_patch:
         | 
| 19 | 
            +
                    description: 'python patch version'
         | 
| 20 | 
            +
                    required: true
         | 
| 21 | 
            +
                    type: string
         | 
| 22 | 
            +
                    default: "2"
         | 
| 23 | 
            +
            #  push:
         | 
| 24 | 
            +
            #    branches:
         | 
| 25 | 
            +
            #      - master
         | 
| 26 | 
            +
             | 
| 27 | 
            +
            jobs:
         | 
| 28 | 
            +
              build:
         | 
| 29 | 
            +
                permissions:
         | 
| 30 | 
            +
                    contents: "write"
         | 
| 31 | 
            +
                    packages: "write"
         | 
| 32 | 
            +
                    pull-requests: "read"
         | 
| 33 | 
            +
                runs-on: windows-latest
         | 
| 34 | 
            +
                steps:
         | 
| 35 | 
            +
                    - uses: actions/checkout@v4
         | 
| 36 | 
            +
                      with:
         | 
| 37 | 
            +
                        fetch-depth: 30
         | 
| 38 | 
            +
                        persist-credentials: false
         | 
| 39 | 
            +
                    - uses: actions/setup-python@v5
         | 
| 40 | 
            +
                      with:
         | 
| 41 | 
            +
                        python-version: 3.${{ inputs.python_minor }}.${{ inputs.python_patch }}
         | 
| 42 | 
            +
                    - shell: bash
         | 
| 43 | 
            +
                      run: |
         | 
| 44 | 
            +
                        cd ..
         | 
| 45 | 
            +
                        cp -r ComfyUI ComfyUI_copy
         | 
| 46 | 
            +
                        curl https://www.python.org/ftp/python/3.${{ inputs.python_minor }}.${{ inputs.python_patch }}/python-3.${{ inputs.python_minor }}.${{ inputs.python_patch }}-embed-amd64.zip -o python_embeded.zip
         | 
| 47 | 
            +
                        unzip python_embeded.zip -d python_embeded
         | 
| 48 | 
            +
                        cd python_embeded
         | 
| 49 | 
            +
                        echo 'import site' >> ./python3${{ inputs.python_minor }}._pth
         | 
| 50 | 
            +
                        curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py
         | 
| 51 | 
            +
                        ./python.exe get-pip.py
         | 
| 52 | 
            +
                        python -m pip wheel torch torchvision torchaudio --pre --extra-index-url https://download.pytorch.org/whl/nightly/cu${{ inputs.cu }} -r ../ComfyUI/requirements.txt pygit2 -w ../temp_wheel_dir
         | 
| 53 | 
            +
                        ls ../temp_wheel_dir
         | 
| 54 | 
            +
                        ./python.exe -s -m pip install --pre ../temp_wheel_dir/*
         | 
| 55 | 
            +
                        sed -i '1i../ComfyUI' ./python3${{ inputs.python_minor }}._pth
         | 
| 56 | 
            +
                        cd ..
         | 
| 57 | 
            +
             | 
| 58 | 
            +
                        git clone --depth 1 https://github.com/comfyanonymous/taesd
         | 
| 59 | 
            +
                        cp taesd/*.pth ./ComfyUI_copy/models/vae_approx/
         | 
| 60 | 
            +
             | 
| 61 | 
            +
                        mkdir ComfyUI_windows_portable_nightly_pytorch
         | 
| 62 | 
            +
                        mv python_embeded ComfyUI_windows_portable_nightly_pytorch
         | 
| 63 | 
            +
                        mv ComfyUI_copy ComfyUI_windows_portable_nightly_pytorch/ComfyUI
         | 
| 64 | 
            +
             | 
| 65 | 
            +
                        cd ComfyUI_windows_portable_nightly_pytorch
         | 
| 66 | 
            +
             | 
| 67 | 
            +
                        mkdir update
         | 
| 68 | 
            +
                        cp -r ComfyUI/.ci/update_windows/* ./update/
         | 
| 69 | 
            +
                        cp -r ComfyUI/.ci/windows_base_files/* ./
         | 
| 70 | 
            +
                        cp -r ComfyUI/.ci/windows_nightly_base_files/* ./
         | 
| 71 | 
            +
             | 
| 72 | 
            +
                        echo "call update_comfyui.bat nopause
         | 
| 73 | 
            +
                        ..\python_embeded\python.exe -s -m pip install --upgrade --pre torch torchvision torchaudio --extra-index-url https://download.pytorch.org/whl/nightly/cu${{ inputs.cu }} -r ../ComfyUI/requirements.txt pygit2
         | 
| 74 | 
            +
                        pause" > ./update/update_comfyui_and_python_dependencies.bat
         | 
| 75 | 
            +
                        cd ..
         | 
| 76 | 
            +
             | 
| 77 | 
            +
                        "C:\Program Files\7-Zip\7z.exe" a -t7z -m0=lzma2 -mx=9 -mfb=128 -md=512m -ms=on -mf=BCJ2 ComfyUI_windows_portable_nightly_pytorch.7z ComfyUI_windows_portable_nightly_pytorch
         | 
| 78 | 
            +
                        mv ComfyUI_windows_portable_nightly_pytorch.7z ComfyUI/ComfyUI_windows_portable_nvidia_or_cpu_nightly_pytorch.7z
         | 
| 79 | 
            +
             | 
| 80 | 
            +
                        cd ComfyUI_windows_portable_nightly_pytorch
         | 
| 81 | 
            +
                        python_embeded/python.exe -s ComfyUI/main.py --quick-test-for-ci --cpu
         | 
| 82 | 
            +
             | 
| 83 | 
            +
                        ls
         | 
| 84 | 
            +
             | 
| 85 | 
            +
                    - name: Upload binaries to release
         | 
| 86 | 
            +
                      uses: svenstaro/upload-release-action@v2
         | 
| 87 | 
            +
                      with:
         | 
| 88 | 
            +
                            repo_token: ${{ secrets.GITHUB_TOKEN }}
         | 
| 89 | 
            +
                            file: ComfyUI_windows_portable_nvidia_or_cpu_nightly_pytorch.7z
         | 
| 90 | 
            +
                            tag: "latest"
         | 
| 91 | 
            +
                            overwrite: true
         | 
    	
        .github/workflows/windows_release_package.yml
    ADDED
    
    | @@ -0,0 +1,100 @@ | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | 
|  | |
| 1 | 
            +
            name: "Windows Release packaging"
         | 
| 2 | 
            +
             | 
| 3 | 
            +
            on:
         | 
| 4 | 
            +
              workflow_dispatch:
         | 
| 5 | 
            +
                inputs:
         | 
| 6 | 
            +
                  cu:
         | 
| 7 | 
            +
                    description: 'cuda version'
         | 
| 8 | 
            +
                    required: true
         | 
| 9 | 
            +
                    type: string
         | 
| 10 | 
            +
                    default: "126"
         | 
| 11 | 
            +
             | 
| 12 | 
            +
                  python_minor:
         | 
| 13 | 
            +
                    description: 'python minor version'
         | 
| 14 | 
            +
                    required: true
         | 
| 15 | 
            +
                    type: string
         | 
| 16 | 
            +
                    default: "12"
         | 
| 17 | 
            +
             | 
| 18 | 
            +
                  python_patch:
         | 
| 19 | 
            +
                    description: 'python patch version'
         | 
| 20 | 
            +
                    required: true
         | 
| 21 | 
            +
                    type: string
         | 
| 22 | 
            +
                    default: "9"
         | 
| 23 | 
            +
            #  push:
         | 
| 24 | 
            +
            #    branches:
         | 
| 25 | 
            +
            #      - master
         | 
| 26 | 
            +
             | 
| 27 | 
            +
            jobs:
         | 
| 28 | 
            +
              package_comfyui:
         | 
| 29 | 
            +
                permissions:
         | 
| 30 | 
            +
                    contents: "write"
         | 
| 31 | 
            +
                    packages: "write"
         | 
| 32 | 
            +
                    pull-requests: "read"
         | 
| 33 | 
            +
                runs-on: windows-latest
         | 
| 34 | 
            +
                steps:
         | 
| 35 | 
            +
                    - uses: actions/cache/restore@v4
         | 
| 36 | 
            +
                      id: cache
         | 
| 37 | 
            +
                      with:
         | 
| 38 | 
            +
                        path: |
         | 
| 39 | 
            +
                          cu${{ inputs.cu }}_python_deps.tar
         | 
| 40 | 
            +
                          update_comfyui_and_python_dependencies.bat
         | 
| 41 | 
            +
                        key: ${{ runner.os }}-build-cu${{ inputs.cu }}-${{ inputs.python_minor }}
         | 
| 42 | 
            +
                    - shell: bash
         | 
| 43 | 
            +
                      run: |
         | 
| 44 | 
            +
                        mv cu${{ inputs.cu }}_python_deps.tar ../
         | 
| 45 | 
            +
                        mv update_comfyui_and_python_dependencies.bat ../
         | 
| 46 | 
            +
                        cd ..
         | 
| 47 | 
            +
                        tar xf cu${{ inputs.cu }}_python_deps.tar
         | 
| 48 | 
            +
                        pwd
         | 
| 49 | 
            +
                        ls
         | 
| 50 | 
            +
             | 
| 51 | 
            +
                    - uses: actions/checkout@v4
         | 
| 52 | 
            +
                      with:
         | 
| 53 | 
            +
                        fetch-depth: 0
         | 
| 54 | 
            +
                        persist-credentials: false
         | 
| 55 | 
            +
                    - shell: bash
         | 
| 56 | 
            +
                      run: |
         | 
| 57 | 
            +
                        cd ..
         | 
| 58 | 
            +
                        cp -r ComfyUI ComfyUI_copy
         | 
| 59 | 
            +
                        curl https://www.python.org/ftp/python/3.${{ inputs.python_minor }}.${{ inputs.python_patch }}/python-3.${{ inputs.python_minor }}.${{ inputs.python_patch }}-embed-amd64.zip -o python_embeded.zip
         | 
| 60 | 
            +
                        unzip python_embeded.zip -d python_embeded
         | 
| 61 | 
            +
                        cd python_embeded
         | 
| 62 | 
            +
                        echo 'import site' >> ./python3${{ inputs.python_minor }}._pth
         | 
| 63 | 
            +
                        curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py
         | 
| 64 | 
            +
                        ./python.exe get-pip.py
         | 
| 65 | 
            +
                        ./python.exe -s -m pip install ../cu${{ inputs.cu }}_python_deps/*
         | 
| 66 | 
            +
                        sed -i '1i../ComfyUI' ./python3${{ inputs.python_minor }}._pth
         | 
| 67 | 
            +
                        cd ..
         | 
| 68 | 
            +
             | 
| 69 | 
            +
                        git clone --depth 1 https://github.com/comfyanonymous/taesd
         | 
| 70 | 
            +
                        cp taesd/*.pth ./ComfyUI_copy/models/vae_approx/
         | 
| 71 | 
            +
             | 
| 72 | 
            +
                        mkdir ComfyUI_windows_portable
         | 
| 73 | 
            +
                        mv python_embeded ComfyUI_windows_portable
         | 
| 74 | 
            +
                        mv ComfyUI_copy ComfyUI_windows_portable/ComfyUI
         | 
| 75 | 
            +
             | 
| 76 | 
            +
                        cd ComfyUI_windows_portable
         | 
| 77 | 
            +
             | 
| 78 | 
            +
                        mkdir update
         | 
| 79 | 
            +
                        cp -r ComfyUI/.ci/update_windows/* ./update/
         | 
| 80 | 
            +
                        cp -r ComfyUI/.ci/windows_base_files/* ./
         | 
| 81 | 
            +
                        cp ../update_comfyui_and_python_dependencies.bat ./update/
         | 
| 82 | 
            +
             | 
| 83 | 
            +
                        cd ..
         | 
| 84 | 
            +
             | 
| 85 | 
            +
                        "C:\Program Files\7-Zip\7z.exe" a -t7z -m0=lzma2 -mx=8 -mfb=64 -md=32m -ms=on -mf=BCJ2 ComfyUI_windows_portable.7z ComfyUI_windows_portable
         | 
| 86 | 
            +
                        mv ComfyUI_windows_portable.7z ComfyUI/new_ComfyUI_windows_portable_nvidia_cu${{ inputs.cu }}_or_cpu.7z
         | 
| 87 | 
            +
             | 
| 88 | 
            +
                        cd ComfyUI_windows_portable
         | 
| 89 | 
            +
                        python_embeded/python.exe -s ComfyUI/main.py --quick-test-for-ci --cpu
         | 
| 90 | 
            +
             | 
| 91 | 
            +
                        ls
         | 
| 92 | 
            +
             | 
| 93 | 
            +
                    - name: Upload binaries to release
         | 
| 94 | 
            +
                      uses: svenstaro/upload-release-action@v2
         | 
| 95 | 
            +
                      with:
         | 
| 96 | 
            +
                            repo_token: ${{ secrets.GITHUB_TOKEN }}
         | 
| 97 | 
            +
                            file: new_ComfyUI_windows_portable_nvidia_cu${{ inputs.cu }}_or_cpu.7z
         | 
| 98 | 
            +
                            tag: "latest"
         | 
| 99 | 
            +
                            overwrite: true
         | 
| 100 | 
            +
             | 
 
			
