The most powerful and modular diffusion model GUI, api and backend with a graph/nodes interface. The fastest local inference engine in the world.
Turn the assets system on for the Windows standalone build (#16928)
Simon Pinfold14c553159994
diff --git a/comfy/cli_args.py b/comfy/cli_args.pyindex ec8efa0ec..8b0a42c7f 100644--- a/comfy/cli_args.py+++ b/comfy/cli_args.py@@ -209,7 +209,7 @@ parser.add_argument("--disable-mmap", action="store_true", help="Don't use mmapparser.add_argument("--dont-print-server", action="store_true", help="Don't print server output.")parser.add_argument("--quick-test-for-ci", action="store_true", help="Quick test for CI.")-parser.add_argument("--windows-standalone-build", action="store_true", help="Windows standalone build: Enable convenient things that most people using the standalone windows build will probably enjoy (like auto opening the page on startup).")+parser.add_argument("--windows-standalone-build", action="store_true", help="Windows standalone build: Enable convenient things that most people using the standalone windows build will probably enjoy (like auto opening the page on startup and turning on the assets system; --disable-assets turns it off).")parser.add_argument("--disable-metadata", action="store_true", help="Disable saving prompt metadata in files.")parser.add_argument("--disable-all-custom-nodes", action="store_true", help="Disable loading all custom nodes.")@@ -277,7 +277,7 @@ database_default_path = os.path.abspath(parser.add_argument("--database-url", type=str, default=None, help="Specify the database URL, e.g. for an in-memory database you can use 'sqlite:///:memory:'. Defaults to 'comfyui.db' in the effective user directory.")parser.add_argument("--enable-assets", action="store_true", help="Enable the assets system (API routes, database synchronization, and background scanning). Off by default.")parser.add_argument("--disable-assets", action="store_true", help="Disable the assets system, even when --enable-assets is also given.")-parser.add_argument("--enable-asset-hashing", action="store_true", help="Compute blake3 content hashes when scanning assets. Files uploaded through the API are hashed either way. Hashing enables future asset-portability features (deduplication, cross-machine model resolution) but adds startup cost and per-output cost on large models directories. Off by default; enable to opt in. Requires --enable-assets.")+parser.add_argument("--enable-asset-hashing", action="store_true", help="Compute blake3 content hashes when scanning assets. Files uploaded through the API are hashed either way. Hashing enables future asset-portability features (deduplication, cross-machine model resolution) but adds startup cost and per-output cost on large models directories. Off by default; enable to opt in. Requires the assets system (--enable-assets or --windows-standalone-build).")parser.add_argument("--feature-flag", type=str, action='append', default=[], metavar="KEY[=VALUE]", help="Set a server feature flag. Use KEY=VALUE to set an explicit value, or bare KEY to set it to true. Can be specified multiple times. Boolean values (true/false) and numbers are auto-converted. Examples: --feature-flag show_signin_button=true or --feature-flag show_signin_button")parser.add_argument("--list-feature-flags", action="store_true", help="Print the registry of known CLI-settable feature flags as JSON and exit.")@@ -294,6 +294,7 @@ if args.high_ram:if args.windows_standalone_build:args.auto_launch = True+ args.enable_assets = Trueif args.disable_api_nodes:args.offline = Truediff --git a/tests-unit/assets_test/services/test_noassets_parity.py b/tests-unit/assets_test/services/test_noassets_parity.pyindex 6d373143d..36d59413a 100644--- a/tests-unit/assets_test/services/test_noassets_parity.py+++ b/tests-unit/assets_test/services/test_noassets_parity.py@@ -190,6 +190,9 @@ def test_noassets_is_disabled() -> None:(["--enable-assets"], AssetsEnabled),(["--disable-assets"], NoAssets),(["--enable-assets", "--disable-assets"], NoAssets),+ (["--windows-standalone-build"], AssetsEnabled),+ (["--windows-standalone-build", "--disable-assets"], NoAssets),+ (["--windows-standalone-build", "--enable-assets"], AssetsEnabled),],)def test_assets_are_off_unless_enabled(