fastled 1.2.24__py3-none-any.whl → 1.2.26__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 CHANGED
@@ -15,7 +15,7 @@ from .types import BuildMode, CompileResult, CompileServerError
15
15
  # IMPORTANT! There's a bug in github which will REJECT any version update
16
16
  # that has any other change in the repo. Please bump the version as the
17
17
  # ONLY change in a commit, or else the pypi update and the release will fail.
18
- __version__ = "1.2.24"
18
+ __version__ = "1.2.26"
19
19
 
20
20
 
21
21
  class Api:
fastled/app.py CHANGED
@@ -7,7 +7,7 @@ import sys
7
7
  import time
8
8
  from pathlib import Path
9
9
 
10
- from fastled.client_server import run_client, run_client_server
10
+ from fastled.client_server import run_client_server
11
11
  from fastled.compile_server import CompileServer
12
12
  from fastled.parse_args import parse_args
13
13
 
@@ -55,34 +55,14 @@ def main() -> int:
55
55
  try:
56
56
  project_root = Path(".").absolute()
57
57
  print(f"Building Docker image at {project_root}")
58
- from fastled import Api, Docker
58
+ from fastled import Docker
59
59
 
60
60
  docker_image_name = Docker.build_from_fastled_repo(
61
61
  project_root=project_root
62
62
  )
63
63
  print(f"Built Docker image: {docker_image_name}")
64
- print("Running server")
65
- with Api.server(
66
- auto_updates=False, container_name=docker_image_name
67
- ) as server:
68
- sketch_dir = Path("examples/wasm")
69
- if args.just_compile:
70
- rtn = run_client(
71
- directory=sketch_dir,
72
- host=server,
73
- open_web_browser=False,
74
- keep_running=False,
75
- )
76
- if rtn != 0:
77
- print(f"Failed to compile: {rtn})")
78
- return rtn
79
- print(f"Server started at {server.url()}")
80
- with Api.live_client(
81
- sketch_directory=sketch_dir, host=server
82
- ) as client:
83
- print(f"Client started at {client.url()}")
84
- while True:
85
- time.sleep(0.1)
64
+ print("Exiting...")
65
+ return 0
86
66
  except KeyboardInterrupt:
87
67
  print("\nExiting from client...")
88
68
  return 1
fastled/docker_manager.py CHANGED
@@ -523,6 +523,7 @@ class DockerManager:
523
523
  container.remove(force=True)
524
524
  except docker.errors.NotFound:
525
525
  pass
526
+ start_time = time.time()
526
527
  try:
527
528
  docker_command: list[str] = [
528
529
  "docker",
@@ -546,7 +547,10 @@ class DockerManager:
546
547
  subprocess.run(docker_command, check=True)
547
548
  except subprocess.CalledProcessError as e:
548
549
  print(f"Error running Docker command: {e}")
549
- raise
550
+ diff = time.time() - start_time
551
+ if diff < 5:
552
+ raise
553
+ sys.exit(1) # Probably a user exit.
550
554
 
551
555
  def attach_and_run(self, container: Container | str) -> RunningContainer:
552
556
  """
fastled/parse_args.py CHANGED
@@ -131,6 +131,9 @@ def parse_args() -> argparse.Namespace:
131
131
  print(f"Use 'fastled {args.directory}' to compile the project.")
132
132
  sys.exit(0)
133
133
 
134
+ if args.build:
135
+ return args
136
+
134
137
  if not args.update:
135
138
  if args.no_auto_updates:
136
139
  args.auto_update = False
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.2
2
2
  Name: fastled
3
- Version: 1.2.24
3
+ Version: 1.2.26
4
4
  Summary: FastLED Wasm Compiler
5
5
  Home-page: https://github.com/zackees/fastled-wasm
6
6
  Maintainer: Zachary Vorhies
@@ -293,7 +293,6 @@ A: `delay()` will block `loop()` which blocks the main thread of the browser. Th
293
293
  Q: How can I get the compiled size of my FastLED sketch smaller?
294
294
  A: A big chunk of space is being used by unnecessary javascript `emscripten` bundling. The wasm_compiler_settings.py file in the FastLED repo can tweak this.
295
295
 
296
-
297
296
  # Revisions
298
297
 
299
298
  * 1.2.22 - Prefer to use `live-server` from npm. If npm exists on the system then do a background install of `live-server` for next run.
@@ -1,16 +1,16 @@
1
- fastled/__init__.py,sha256=TQtvt1LcnpuUB_0WGV0QQ9a4lFkwCxuLXGdz6FHPjPg,11084
2
- fastled/app.py,sha256=4LQHjN-GMAzhEaIKSFkT5S26Snb1Y9kgVnPK6kqXbrQ,3382
1
+ fastled/__init__.py,sha256=Oii9My4i8BhaJJ5_54OtzBeudi2v8KWMWMmLF4Id4v0,11084
2
+ fastled/app.py,sha256=mCa40qcIlnceiEnLe1m84wWiyqT7fZBw2sSbCpP5Lt8,2489
3
3
  fastled/cli.py,sha256=FjVr31ht0UPlAcmX-84NwfAGMQHTkrCe4o744jCAxiw,375
4
4
  fastled/client_server.py,sha256=eORWVyI1PvyowmhLWt3V9aI_AemPSBL9bAkjMBD2kAw,14282
5
5
  fastled/compile_server.py,sha256=g0y9vEZqpzAJEUwketV8lbwI8VZNSSLuOuwcF04k-dw,2775
6
6
  fastled/compile_server_impl.py,sha256=B_7zjdKHxX2JbNcx26hntwtk8-MyQTs6LMZlpOEuloM,8746
7
- fastled/docker_manager.py,sha256=lPeHPtar2ZPFMvcNKEskzHO1EMgPMl0uUt4M4bollT0,29659
7
+ fastled/docker_manager.py,sha256=HJDl533G5mCBCSqMZhtdP7mhurx3cLPQU3T-DTWC9xU,29814
8
8
  fastled/filewatcher.py,sha256=LwEQJkqADsArZyY499RLAer6JjJyDwaQBcAvT7xmp3c,6708
9
9
  fastled/keyboard.py,sha256=vyYxE98WCXjvMpcUJd0YXPVvt7TzvBmifLYI-K7jtKg,3524
10
10
  fastled/live_client.py,sha256=b9mVJ-8w_zoEDwKIlAEUC5Q1La5W5rR6ct-exOcgJec,2561
11
11
  fastled/open_browser.py,sha256=DDzOXNYVYLIDWVdmpJ-jLxZSAs5mw3VGHo2UIJ-T8SE,4339
12
12
  fastled/open_browser2.py,sha256=jUgN81bEYX-sr0zKTVJkwj9tXEVq7aZTxGUP_ShyCbs,3614
13
- fastled/parse_args.py,sha256=LD2PpSEhyq3ZqPWa_TJ90Fb-O-yldi7rnen2fWLOPjo,6868
13
+ fastled/parse_args.py,sha256=23EoqEf7MF7WEYIufcjCanttz-hiDE2E3z1X73p6rIQ,6908
14
14
  fastled/paths.py,sha256=VsPmgu0lNSCFOoEC0BsTYzDygXqy15AHUfN-tTuzDZA,99
15
15
  fastled/project_init.py,sha256=bBt4DwmW5hZkm9ICt9Qk-0Nr_0JQM7icCgH5Iv-bCQs,3984
16
16
  fastled/select_sketch_directory.py,sha256=TZdCjl1D7YMKjodMTvDRurPcpAmN3x0TcJxffER2NfM,1314
@@ -25,9 +25,9 @@ fastled/assets/example.txt,sha256=lTBovRjiz0_TgtAtbA1C5hNi2ffbqnNPqkKg6UiKCT8,54
25
25
  fastled/site/build.py,sha256=l4RajIk0bApiAifT1lyLjIZi9lpPtSba4cnwWP5UOKc,14064
26
26
  fastled/test/can_run_local_docker_tests.py,sha256=LEuUbHctRhNNFWcvnz2kEGmjDJeXO4c3kNpizm3yVJs,400
27
27
  fastled/test/examples.py,sha256=6xPwx_k9_XwYTpI1nk4SrYbsJKHJACd30GzD1epGqhY,1597
28
- fastled-1.2.24.dist-info/LICENSE,sha256=b6pOoifSXiUaz_lDS84vWlG3fr4yUKwB8fzkrH9R8bQ,1064
29
- fastled-1.2.24.dist-info/METADATA,sha256=vYkGv-ilEATbey9Ov7aZrXK7JSyLRbB5F51eGgkjg_o,21177
30
- fastled-1.2.24.dist-info/WHEEL,sha256=In9FTNxeP60KnTkGw7wk6mJPYd_dQSjEZmXdBdMCI-8,91
31
- fastled-1.2.24.dist-info/entry_points.txt,sha256=RCwmzCSOS4-C2i9EziANq7Z2Zb4KFnEMR1FQC0bBwAw,101
32
- fastled-1.2.24.dist-info/top_level.txt,sha256=Bbv5kpJpZhWNCvDF4K0VcvtBSDMa8B7PTOrZa9CezHY,8
33
- fastled-1.2.24.dist-info/RECORD,,
28
+ fastled-1.2.26.dist-info/LICENSE,sha256=b6pOoifSXiUaz_lDS84vWlG3fr4yUKwB8fzkrH9R8bQ,1064
29
+ fastled-1.2.26.dist-info/METADATA,sha256=aiwrYo7A8eyCXVxmVXpqT9kUP7rcFKJEISUWmOSg-xs,21176
30
+ fastled-1.2.26.dist-info/WHEEL,sha256=In9FTNxeP60KnTkGw7wk6mJPYd_dQSjEZmXdBdMCI-8,91
31
+ fastled-1.2.26.dist-info/entry_points.txt,sha256=RCwmzCSOS4-C2i9EziANq7Z2Zb4KFnEMR1FQC0bBwAw,101
32
+ fastled-1.2.26.dist-info/top_level.txt,sha256=Bbv5kpJpZhWNCvDF4K0VcvtBSDMa8B7PTOrZa9CezHY,8
33
+ fastled-1.2.26.dist-info/RECORD,,