When the stream test warns File path too long for Windows, at least one file in your zip has a path so long that, once it is unpacked on our streaming machines, it goes over Windows' limit of 260 characters. Your app may still stream in the test. This page explains why it matters, how to find those files, and how to fix the build.
Windows, as it is set up on most computers and on our streaming machines, cannot open a file whose full path is longer than 260 characters (259 plus an end mark). The full path is the folder we unpack your build into, followed by the path of the file inside your zip:
C:\0.apps\<your account>\<your app>\<version>\ + MyGame\Samples\PixelStreaming\WebServers\...\file.js
|------------- our folder (about 35-70 characters) -------| |---------- the path inside your zip ----------|
So the room left for your build's own paths is shorter than 260. The stream test measures every file
against the longest folder your build can land in (the test machine's folder is the longest). As a rule of thumb, a
path inside your zip may be about 220 characters, minus the length of your account name and of your app's
name. Example: account VanishingPoint3D (16) and app Podfigurator (12) leave
192 characters.
The warning names the longest file and how many more there are, for example:
Your build contains a file path too long for Windows: MyGame\Samples\PixelStreaming\WebServers\Extras\
mediasoup-sdp-bridge\node_modules\mediasoup\worker\deps\...\file.cc (275 characters on our machines,
more than Windows' limit of 259) (and 15 more such file(s)).
Today this is a warning: the test still runs, and a build that streams is published. It is shown in the upload window, in the test report pop-up and in the test result email.
| Where | What can happen | What your viewers notice |
|---|---|---|
| Copying the build to our shared drives | The copy cannot unpack the over-long files, so the build never reaches the drives every streaming machine reads from | Each machine has to download and unpack the whole build itself the first time: the first viewer on each machine waits 1 to 6 minutes instead of seconds |
| Unpacking on a streaming machine | Some unpacking tools cannot write paths this long and leave those files out, or stop | The app does not start, or starts with files missing |
| Your app while it runs | A Windows program may fail to open a file whose path is too long | Missing content or a crash, but only if the app really uses that file |
If the long files are ones the app never uses (like Unreal's sample web server), the app itself is fine. The slow first start and the failed copies still happen, so it is worth removing them.
Open PowerShell on your Windows computer and run one of the two commands below. Each lists the 30 longest paths over 150 characters, longest first, with their length. Replace the example path with your own.
This reads only the zip's list of files; nothing is unpacked. It counts exactly what we count.
Add-Type -AssemblyName System.IO.Compression.FileSystem; $z = [IO.Compression.ZipFile]::OpenRead("C:\Builds\MyGame.zip"); $z.Entries | Where-Object { $_.FullName.Length -gt 150 } | Sort-Object { $_.FullName.Length } -Descending | Select-Object -First 30 @{n='Chars';e={$_.FullName.Length}}, FullName | Format-Table -AutoSize -Wrap; $z.Dispose()
Go into the folder you are going to zip first (cd C:\Builds\Windows), then:
$b = (Get-Location).Path; Get-ChildItem -LiteralPath "\\?\$b" -Recurse -File | ForEach-Object { $_.FullName.Substring($b.Length + 5) } | Where-Object { $_.Length -gt 150 } | Sort-Object Length -Descending | Select-Object -First 30 | ForEach-Object { "$($_.Length) $_" }
The \\?\ part lets the command read paths over 260 characters even on a computer where Windows' long-path
support is off. Any path close to or above the room worked out above needs fixing.
| Where the long paths are | Why they are there | Fix |
|---|---|---|
Samples\PixelStreaming\WebServers\...\node_modules\... (or PixelStreaming2) | Unreal copies the Pixel Streaming plugin's sample web servers into the package. If someone ran their setup scripts on the engine, thousands of node_modules files with very deep paths come along | In the packaged build, keep only WebServers\get_ps_servers.bat and delete everything else in WebServers (not just node_modules - none of it is used, and its many small files slow down copying your build to our machines). Eagle 3D Streaming runs its own servers, so the app does not need them. To stop it coming back, delete them from the engine's plugin folder too (Engine\Plugins\Media\PixelStreaming\Resources\WebServers, or PixelStreaming2) |
Any other node_modules, .git or tool folder | Folders added to the project or packaged as extra files by mistake | Remove them from the build, and from Project Settings > Packaging > Additional Non-Asset Directories to Package if they are listed there |
| Long folder or file names in your own content | Deep folder trees with long names, loose files (movies, data files) outside the .pak | Shorten the folder names, or keep content inside the .pak (Use Pak File on in Project Settings > Packaging) |
| A long project name | The project name is the first folder of every path | A shorter project name for new builds |
| Extra folders around the build in the zip | The zip was made from a parent folder (Builds\Final\Windows\MyGame\...) | Zip the packaged build folder itself, so the zip starts with the game folder and the .exe |
| Just over the limit | Your account and app names count too | A shorter app name when you upload gives a few more characters, but shortening the build's own paths is the lasting fix |
Why keep one file: the upload window and our stream test recognise a Pixel Streaming build by the
Samples\PixelStreaming folder. If you delete the whole WebServers folder, or the whole
Samples folder, the upload window no longer sees the Pixel Streaming plugin and asks you to type
AGREE (see Pixel Streaming plugin not detected).
The app still streams - but keeping WebServers\get_ps_servers.bat (any one small file in that folder works)
avoids the question.
Write to (Email / Discord) with your app's name and version. We can tell you which files the test found.
Last updated