Skip to content

feat(hub): drop offline-mode (HF_HUB_OFFLINE) support - #75

Open
Mokuroh54 wants to merge 2 commits into
mainfrom
feat/drop-hf-offline
Open

feat(hub): drop offline-mode (HF_HUB_OFFLINE) support#75
Mokuroh54 wants to merge 2 commits into
mainfrom
feat/drop-hf-offline

Conversation

@Mokuroh54

Copy link
Copy Markdown

Running without the Hub is no longer a supported posture. This is a port of the orphaned remove-hf-offline work (original commit b4d752a, written on a pre-rollback lineage) onto current main.

What's removed

  • The --offline launcher flag — makermodslab-station is now just --lan; the systemd service file describes the LAN posture (and no longer points at a nonexistent INSTALL.md — pre-existing dangling reference, removed).
  • hf_hub_offline() and all nine refuse-when-offline guards (datasets ×5, models ×2, jobs, server training preflight), plus the offline field on /jobs/runners/hardware (all three return paths).
  • Frontend: the offline hard-blocks on Start, both CloudNotice offline branches/props, ManageCachesDialog's offline banner + its now-pointless hardware fetch, and the "400 offline" doc comments.

What's deliberately kept

  • Every transport-error degrade: hub status "unknown", cached-listing resilience, "offline / rate-limited" prose — those describe network failures, not the removed switch. A grep sweep confirms the only surviving "offline" mentions are this category, local-capability prose, and W&B's unrelated wandb_mode selector.
  • 4 non-offline dataset-availability tests from the deleted test_training_preflight.py were relocated into test_datasets.py, not dropped.

Port adaptations (main drifted from the original lineage)

  • The old lineage's useTrainingEnvironment/useTrainingConfig hooks don't exist on main; that plumbing is inline in TrainingConfigurator.tsx and was ported there (22-line diff vs the original's 35 — the difference is lineage-only code).
  • jobs.py import block adapted to main's shape.

Checks

Backend: ruff clean; scoped pytest 383 passed with zero new failures (7 pre-existing test_models.py isolation failures exist on main tip independently of this PR — real-cache leakage, tracked separately). Frontend: tsc -b and lint identical to main baseline. Full pre-commit run --all-files: green. package-lock.json and frontend/dist/ untouched.

🤖 Generated with Claude Code

Running without the Hub is no longer a supported posture. Port of
b4d752a from the pre-rollback lineage onto main:

- Remove the --offline launcher flag; makermodslab-station is now just
  --lan. The station service file describes the LAN posture and no
  longer references an offline posture (or the nonexistent INSTALL.md).
- Remove hf_hub_offline() and all nine refuse-when-offline guards
  (datasets, models, jobs, server training preflight), plus the offline
  field on /jobs/runners/hardware.
- Frontend: remove the offline hard-blocks on Start, the CloudNotice
  offline branches, ManageCachesDialog's offline banner (and its
  now-pointless hardware fetch), and the '400 offline' doc comments.

Deliberately kept: every transport-error degrade — hub status
'unknown', cached-listing resilience, 'offline / rate-limited' prose —
those are about network failures, not the removed switch. Also kept:
W&B's wandb_mode 'offline' option, which is unrelated.

Port notes: the old lineage's useTrainingEnvironment/useTrainingConfig
hooks don't exist on main (that plumbing is inline in
TrainingConfigurator.tsx, ported there); jobs.py import adapted to
main's shape; four non-offline dataset-availability tests relocated
into test_datasets.py rather than deleted with test_training_preflight.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@Mokuroh54 Mokuroh54 added chore Maintenance, removals, deps — no user-facing feature area: backend FastAPI server and Python modules area: frontend React/Vite UI under frontend/src area: hub Hugging Face Hub upload/status/sync area: training train.py, jobs, runners, Skill Studio training flows labels Aug 9, 2026
@Mokuroh54
Mokuroh54 marked this pull request as ready for review August 9, 2026 16:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: backend FastAPI server and Python modules area: frontend React/Vite UI under frontend/src area: hub Hugging Face Hub upload/status/sync area: training train.py, jobs, runners, Skill Studio training flows chore Maintenance, removals, deps — no user-facing feature

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant