github-actions[bot] commited on
Commit
1857618
·
1 Parent(s): f45a0cf

Deploy hyper3labs/HyperView from Hyper3Labs/hyperview-spaces@fd34509

Browse files
Files changed (2) hide show
  1. Dockerfile +5 -4
  2. demo.py +7 -1
Dockerfile CHANGED
@@ -21,10 +21,11 @@ WORKDIR $HOME/app
21
 
22
  RUN pip install --upgrade pip
23
 
24
- # Install latest releases from PyPI.
25
  # For reproducible builds, pin versions here:
26
- # RUN pip install --upgrade hyperview==0.1.1 hyper-models==0.1.0
27
- RUN pip install --upgrade hyperview hyper-models
 
28
 
29
  COPY --chown=user demo.py ./demo.py
30
 
@@ -41,7 +42,7 @@ ENV HOST=0.0.0.0 \
41
 
42
  EXPOSE 7860
43
 
44
- HEALTHCHECK --interval=30s --timeout=10s --start-period=60s --retries=3 \
45
  CMD curl -f http://localhost:7860/__hyperview__/health || exit 1
46
 
47
  CMD ["python", "demo.py"]
 
21
 
22
  RUN pip install --upgrade pip
23
 
24
+ # Install latest releases from PyPI (split for better build caching & logging).
25
  # For reproducible builds, pin versions here:
26
+ # RUN pip install hyperview==0.1.1 hyper-models==0.1.0
27
+ RUN pip install hyperview && python -c "import hyperview; print('hyperview', hyperview.__version__)"
28
+ RUN pip install hyper-models && python -c "import hyper_models; print('hyper_models', hyper_models.__version__)"
29
 
30
  COPY --chown=user demo.py ./demo.py
31
 
 
42
 
43
  EXPOSE 7860
44
 
45
+ HEALTHCHECK --interval=30s --timeout=10s --start-period=120s --retries=3 \
46
  CMD curl -f http://localhost:7860/__hyperview__/health || exit 1
47
 
48
  CMD ["python", "demo.py"]
demo.py CHANGED
@@ -121,7 +121,13 @@ def main() -> None:
121
 
122
  if len(dataset) == 0 or not dataset.list_layouts():
123
  print("Preparing demo dataset...")
124
- _ensure_demo_ready(dataset)
 
 
 
 
 
 
125
  else:
126
  print(
127
  f"Loaded cached dataset '{DATASET_NAME}' with "
 
121
 
122
  if len(dataset) == 0 or not dataset.list_layouts():
123
  print("Preparing demo dataset...")
124
+ try:
125
+ _ensure_demo_ready(dataset)
126
+ except Exception as exc:
127
+ import traceback
128
+ traceback.print_exc()
129
+ print(f"\nFATAL: demo setup failed: {type(exc).__name__}: {exc}", file=sys.stderr)
130
+ sys.exit(1)
131
  else:
132
  print(
133
  f"Loaded cached dataset '{DATASET_NAME}' with "