Skip to content

Make videos on the computer you already own. FreeVideo runs MiniMax H3 in as little as 8 GB of VRAM and 16 GB of RAM, and adapts its acceleration path to your hardware.

Online installs into a folder the system code page cannot spell run from a short entry

Bowen Xue40f487319db0
diff --git a/freevideo_engine/bootstrap.py b/freevideo_engine/bootstrap.py
index abd474c..2b50c94 100644
--- a/freevideo_engine/bootstrap.py
+++ b/freevideo_engine/bootstrap.py
@@ -1190,6 +1190,11 @@ class Installer:
if value.get('disk_mode') == 'extreme':
from .install_disk import environment
self.env = environment(self.root, self.env)
+ # A folder the system code page cannot spell cannot hold what compiles kernels:
+ # every step runs from the short folder, and files and receipts keep the real one.
+ from . import launch_view
+ if launch_view.current(self.env) is None:
+ self.env = launch_view.environment_view(self.env, launch_view.for_engine(self.root))
self.network = dict(value.get('network', {}), events_path=str(self.run_dir / 'network.jsonl'), quiet=True)
self.state = {'status': 'running', 'steps': [], 'plan': value}
if self.damaged_before:
diff --git a/freevideo_engine/launch_view.py b/freevideo_engine/launch_view.py
index dc49068..f9c020b 100644
--- a/freevideo_engine/launch_view.py
+++ b/freevideo_engine/launch_view.py
@@ -15,6 +15,7 @@ import re
from .long_paths import io_path, plain
VIEW_ENV = 'FREEVIDEO_RUNTIME_VIEW'
+ONLINE_ENGINE = 'freevideo-engine' # the folder an online installation is made in
class View(namedtuple('View', 'real root rules', defaults=(os.path,))):
@@ -64,9 +65,18 @@ def view_for(real_root) -> View:
def for_engine(engine_root) -> View:
- """The view of the offline runtime around this engine folder, if it needs one."""
+ """The view of the offline runtime around this engine folder, if it needs one.
+
+ An installation made online is its engine folder: it gets a view only where the
+ system code page cannot spell its folder, and one that cannot be made is not an error.
+ """
from . import runtime_alias
engine = Path(plain(engine_root))
+ if engine.name.casefold() == ONLINE_ENGINE:
+ try:
+ return view_for(engine) if runtime_alias.needs_view(engine, spelling_only=True) else View(engine, engine)
+ except OSError: # Includes a junction that cannot be made: the checks after it name what fails.
+ return View(engine, engine)
root = engine.parent
# The first two tests read nothing from disk wherever no junction is needed.
# The third asks by the extended path: where a junction is needed, the plain
diff --git a/freevideo_engine/runtime_alias.py b/freevideo_engine/runtime_alias.py
index 68b4142..37c4eb3 100644
--- a/freevideo_engine/runtime_alias.py
+++ b/freevideo_engine/runtime_alias.py
@@ -517,7 +517,8 @@ def _longest(root, suffixes=()):
return _manifest_longest(str(path), info.st_mtime_ns, info.st_size, suffixes)
-def needs_view(root, longest=None) -> bool:
+def needs_view(root, longest=None, spelling_only=False) -> bool:
+ """spelling_only: only a folder the system code page cannot spell, never one that is merely long."""
if not _backend.windows():
return False
root = _ordinary(resolved(checked_real_path(root)))
@@ -530,6 +531,8 @@ def needs_view(root, longest=None) -> bool:
# length; the short folder is plain letters.
if not _backend.ansi_path(root):
return True
+ if spelling_only:
+ return False
# An installation that runs from where it is keeps doing so; only one beyond its budget is
# given the short folder.
if longest is None and system_long_paths():