fastled 1.2.33__py3-none-any.whl → 1.4.50__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- fastled/__init__.py +51 -192
- fastled/__main__.py +14 -0
- fastled/__version__.py +6 -0
- fastled/app.py +124 -27
- fastled/args.py +124 -0
- fastled/assets/localhost-key.pem +28 -0
- fastled/assets/localhost.pem +27 -0
- fastled/cli.py +10 -2
- fastled/cli_test.py +21 -0
- fastled/cli_test_interactive.py +21 -0
- fastled/client_server.py +334 -55
- fastled/compile_server.py +12 -1
- fastled/compile_server_impl.py +115 -42
- fastled/docker_manager.py +392 -69
- fastled/emoji_util.py +27 -0
- fastled/filewatcher.py +100 -8
- fastled/find_good_connection.py +105 -0
- fastled/header_dump.py +63 -0
- fastled/install/__init__.py +1 -0
- fastled/install/examples_manager.py +62 -0
- fastled/install/extension_manager.py +113 -0
- fastled/install/main.py +156 -0
- fastled/install/project_detection.py +167 -0
- fastled/install/test_install.py +373 -0
- fastled/install/vscode_config.py +344 -0
- fastled/interruptible_http.py +148 -0
- fastled/keyboard.py +1 -0
- fastled/keyz.py +84 -0
- fastled/live_client.py +26 -1
- fastled/open_browser.py +133 -89
- fastled/parse_args.py +219 -15
- fastled/playwright/chrome_extension_downloader.py +207 -0
- fastled/playwright/playwright_browser.py +773 -0
- fastled/playwright/resize_tracking.py +127 -0
- fastled/print_filter.py +52 -0
- fastled/project_init.py +20 -13
- fastled/select_sketch_directory.py +142 -17
- fastled/server_flask.py +487 -0
- fastled/server_start.py +21 -0
- fastled/settings.py +53 -4
- fastled/site/build.py +2 -10
- fastled/site/examples.py +10 -0
- fastled/sketch.py +129 -7
- fastled/string_diff.py +218 -9
- fastled/test/examples.py +7 -5
- fastled/types.py +22 -2
- fastled/util.py +78 -0
- fastled/version.py +41 -0
- fastled/web_compile.py +401 -218
- fastled/zip_files.py +76 -0
- {fastled-1.2.33.dist-info → fastled-1.4.50.dist-info}/METADATA +533 -382
- fastled-1.4.50.dist-info/RECORD +60 -0
- {fastled-1.2.33.dist-info → fastled-1.4.50.dist-info}/WHEEL +1 -1
- fastled/open_browser2.py +0 -111
- fastled-1.2.33.dist-info/RECORD +0 -33
- {fastled-1.2.33.dist-info → fastled-1.4.50.dist-info}/entry_points.txt +0 -0
- {fastled-1.2.33.dist-info → fastled-1.4.50.dist-info/licenses}/LICENSE +0 -0
- {fastled-1.2.33.dist-info → fastled-1.4.50.dist-info}/top_level.txt +0 -0
fastled/args.py
ADDED
|
@@ -0,0 +1,124 @@
|
|
|
1
|
+
import argparse
|
|
2
|
+
from dataclasses import dataclass
|
|
3
|
+
from pathlib import Path
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
@dataclass
|
|
7
|
+
class Args:
|
|
8
|
+
directory: Path | None
|
|
9
|
+
init: bool | str
|
|
10
|
+
just_compile: bool
|
|
11
|
+
web: str | None
|
|
12
|
+
interactive: bool
|
|
13
|
+
profile: bool
|
|
14
|
+
force_compile: bool
|
|
15
|
+
no_platformio: bool
|
|
16
|
+
app: bool # New flag to trigger Playwright browser with browser download if needed
|
|
17
|
+
auto_update: bool | None
|
|
18
|
+
update: bool
|
|
19
|
+
background_update: bool
|
|
20
|
+
localhost: bool
|
|
21
|
+
build: bool
|
|
22
|
+
server: bool
|
|
23
|
+
purge: bool
|
|
24
|
+
debug: bool
|
|
25
|
+
quick: bool
|
|
26
|
+
release: bool
|
|
27
|
+
ram_disk_size: str # suffixed liked "25mb" or "1gb"
|
|
28
|
+
clear = False # Force the last running container to be removed. Useful for benchmarking.
|
|
29
|
+
install: bool = False # Install FastLED development environment
|
|
30
|
+
dry_run: bool = False # Dry run mode for testing
|
|
31
|
+
no_interactive: bool = False # Non-interactive mode
|
|
32
|
+
emsdk_headers: str | None = None # Path to export EMSDK headers ZIP
|
|
33
|
+
|
|
34
|
+
@staticmethod
|
|
35
|
+
def from_namespace(args: argparse.Namespace) -> "Args":
|
|
36
|
+
assert isinstance(
|
|
37
|
+
args.directory, str | None
|
|
38
|
+
), f"expected str | None, got {type(args.directory)}"
|
|
39
|
+
assert isinstance(
|
|
40
|
+
args.init, bool | str | None
|
|
41
|
+
), f"expected bool, got {type(args.init)}"
|
|
42
|
+
assert isinstance(
|
|
43
|
+
args.just_compile, bool
|
|
44
|
+
), f"expected bool, got {type(args.just_compile)}"
|
|
45
|
+
assert isinstance(
|
|
46
|
+
args.web, str | None
|
|
47
|
+
), f"expected str | None, got {type(args.web)}"
|
|
48
|
+
assert isinstance(
|
|
49
|
+
args.interactive, bool
|
|
50
|
+
), f"expected bool, got {type(args.interactive)}"
|
|
51
|
+
assert isinstance(
|
|
52
|
+
args.profile, bool
|
|
53
|
+
), f"expected bool, got {type(args.profile)}"
|
|
54
|
+
assert isinstance(
|
|
55
|
+
args.force_compile, bool
|
|
56
|
+
), f"expected bool, got {type(args.force_compile)}"
|
|
57
|
+
assert isinstance(
|
|
58
|
+
args.no_platformio, bool
|
|
59
|
+
), f"expected bool, got {type(args.no_platformio)}"
|
|
60
|
+
assert isinstance(args.app, bool), f"expected bool, got {type(args.app)}"
|
|
61
|
+
assert isinstance(
|
|
62
|
+
args.no_auto_updates, bool | None
|
|
63
|
+
), f"expected bool | None, got {type(args.no_auto_updates)}"
|
|
64
|
+
assert isinstance(args.update, bool), f"expected bool, got {type(args.update)}"
|
|
65
|
+
assert isinstance(
|
|
66
|
+
args.background_update, bool
|
|
67
|
+
), f"expected bool, got {type(args.background_update)}"
|
|
68
|
+
assert isinstance(
|
|
69
|
+
args.localhost, bool
|
|
70
|
+
), f"expected bool, got {type(args.localhost)}"
|
|
71
|
+
assert isinstance(args.build, bool), f"expected bool, got {type(args.build)}"
|
|
72
|
+
assert isinstance(args.server, bool), f"expected bool, got {type(args.server)}"
|
|
73
|
+
assert isinstance(args.purge, bool), f"expected bool, got {type(args.purge)}"
|
|
74
|
+
assert isinstance(args.debug, bool), f"expected bool, got {type(args.debug)}"
|
|
75
|
+
assert isinstance(args.quick, bool), f"expected bool, got {type(args.quick)}"
|
|
76
|
+
assert isinstance(
|
|
77
|
+
args.release, bool
|
|
78
|
+
), f"expected bool, got {type(args.release)}"
|
|
79
|
+
assert isinstance(
|
|
80
|
+
args.install, bool
|
|
81
|
+
), f"expected bool, got {type(args.install)}"
|
|
82
|
+
assert isinstance(
|
|
83
|
+
args.dry_run, bool
|
|
84
|
+
), f"expected bool, got {type(args.dry_run)}"
|
|
85
|
+
assert isinstance(
|
|
86
|
+
args.no_interactive, bool
|
|
87
|
+
), f"expected bool, got {type(args.no_interactive)}"
|
|
88
|
+
assert isinstance(
|
|
89
|
+
args.emsdk_headers, str | None
|
|
90
|
+
), f"expected str | None, got {type(args.emsdk_headers)}"
|
|
91
|
+
|
|
92
|
+
init: bool | str = False
|
|
93
|
+
if args.init is None:
|
|
94
|
+
init = False
|
|
95
|
+
elif isinstance(args.init, bool):
|
|
96
|
+
init = args.init
|
|
97
|
+
elif isinstance(args.init, str):
|
|
98
|
+
init = args.init
|
|
99
|
+
return Args(
|
|
100
|
+
directory=Path(args.directory) if args.directory else None,
|
|
101
|
+
init=init,
|
|
102
|
+
just_compile=args.just_compile,
|
|
103
|
+
web=args.web,
|
|
104
|
+
interactive=args.interactive,
|
|
105
|
+
profile=args.profile,
|
|
106
|
+
force_compile=args.force_compile,
|
|
107
|
+
no_platformio=args.no_platformio,
|
|
108
|
+
app=args.app,
|
|
109
|
+
auto_update=not args.no_auto_updates,
|
|
110
|
+
update=args.update,
|
|
111
|
+
background_update=args.background_update,
|
|
112
|
+
localhost=args.localhost,
|
|
113
|
+
build=args.build,
|
|
114
|
+
server=args.server,
|
|
115
|
+
purge=args.purge,
|
|
116
|
+
debug=args.debug,
|
|
117
|
+
quick=args.quick,
|
|
118
|
+
release=args.release,
|
|
119
|
+
ram_disk_size=args.ram_disk_size,
|
|
120
|
+
install=args.install,
|
|
121
|
+
dry_run=args.dry_run,
|
|
122
|
+
emsdk_headers=args.emsdk_headers,
|
|
123
|
+
no_interactive=args.no_inter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b2NhbGhvc3QwDQYJKoZIhvcNAQELBQADggGB
|
|
18
|
+
AJVrF1yczZaxt+A2AhdeFbJQUR6NzGBTc20YeWF1YzLV5sV3QVumwZLP2M9ggRgd
|
|
19
|
+
xWV0xfwUHobFQk6RIPTADcLKctiurql0cgF4DPnpWVvto9RM00U3AkQcMj3xtKBV
|
|
20
|
+
wUqo83TcbqgL+euudFZ09gGTs9u9AENaZPcMh+rW8DDO92t+EwMI/IfopxVOJGUB
|
|
21
|
+
RSM3yTwV93BMYBuddt8mclzLzPK/1WONfsHU2xEascaHR1tYMOmJN9Vq4o0fzWxo
|
|
22
|
+
a2vI6K0aJqZV/ztdXq3akwLc6/e9hyptHWa0i/022xVCyNWIlnuEhT7ENMPxh6rX
|
|
23
|
+
ZCQCZVnhcSWAyFjggLJql3aSID5fPF8rmN7wWsB/I5pl9qwMR1/THMPrm5aWn1Xj
|
|
24
|
+
xW6PxkSGm73kd57DH7tqm5HTd8eYCbnsFofI9rC7xI6HCfwchKp+YHvIEu/LJ56E
|
|
25
|
+
FLnCZW/orYkHCzWntzxv1bddrw1BwaNR8Q+mu3imRP8fuyXb2UkFkINVVyOOWHuW
|
|
26
|
+
Kw==
|
|
27
|
+
-----END CERTIFICATE-----
|
fastled/cli.py
CHANGED
|
@@ -5,12 +5,20 @@ Main entry point.
|
|
|
5
5
|
import multiprocessing
|
|
6
6
|
import sys
|
|
7
7
|
|
|
8
|
-
|
|
8
|
+
|
|
9
|
+
def run_app() -> int:
|
|
10
|
+
"""Run the application."""
|
|
11
|
+
from fastled.app import main as app_main
|
|
12
|
+
|
|
13
|
+
return app_main()
|
|
9
14
|
|
|
10
15
|
|
|
11
16
|
def main() -> int:
|
|
12
17
|
"""Main entry point for the template_python_cmd package."""
|
|
13
|
-
|
|
18
|
+
# if "--debug" in sys.argv:
|
|
19
|
+
# # Debug mode
|
|
20
|
+
# os.environ["FLASK_SERVER_LOGGING"] = "1"
|
|
21
|
+
return run_app()
|
|
14
22
|
|
|
15
23
|
|
|
16
24
|
# Cli entry point for the pyinstaller generated exe
|
fastled/cli_test.py
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import sys
|
|
2
|
+
|
|
3
|
+
from fastled.app import main as app_main
|
|
4
|
+
|
|
5
|
+
if __name__ == "__main__":
|
|
6
|
+
# Note that the entry point for the exe is in cli.py
|
|
7
|
+
try:
|
|
8
|
+
import os
|
|
9
|
+
|
|
10
|
+
os.chdir("../fastled")
|
|
11
|
+
# sys.argv.append("--server")
|
|
12
|
+
# sys.argv.append("--local")
|
|
13
|
+
# sys.argv.append("--debug")
|
|
14
|
+
sys.argv.append("examples/Corkscrew")
|
|
15
|
+
sys.exit(app_main())
|
|
16
|
+
except KeyboardInterrupt:
|
|
17
|
+
print("\nExiting from main...")
|
|
18
|
+
sys.exit(1)
|
|
19
|
+
except Exception as e:
|
|
20
|
+
print(f"Error: {e}")
|
|
21
|
+
sys.exit(1)
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import sys
|
|
2
|
+
|
|
3
|
+
from fastled.app import main as app_main
|
|
4
|
+
|
|
5
|
+
if __name__ == "__main__":
|
|
6
|
+
# Note that the entry point for the exe is in cli.py
|
|
7
|
+
try:
|
|
8
|
+
import os
|
|
9
|
+
|
|
10
|
+
os.chdir("../fastled")
|
|
11
|
+
# sys.argv.append("--server")
|
|
12
|
+
# sys.argv.append("--local")
|
|
13
|
+
sys.argv.append("examples/FxWave2d")
|
|
14
|
+
sys.argv.append("-i")
|
|
15
|
+
sys.exit(app_main())
|
|
16
|
+
except KeyboardInterrupt:
|
|
17
|
+
print("\nExiting from main...")
|
|
18
|
+
sys.exit(1)
|
|
19
|
+
except Exception as e:
|
|
20
|
+
print(f"Error: {e}")
|
|
21
|
+
sys.exit(1)
|