fix: SG-35913: Fix importing files with long path names on Windows#1255
Merged
bernie-laberge merged 1 commit intoMay 11, 2026
Conversation
…cademySoftwareFoundation#1215) Replace `fileExistsWithLongPathSupport ` with a manifest file enabling `longPathAware`. RV was failing to load media files with long path names even with the fix from `fileExistsWithLongPathSupport()`. In this function, a prefix was added in front of the file path known by RV to make it a long path. However, the path contained forward slashes, but the extended path prefix is expecting backslashes. This was causing RV to not recognize long path names. A simple fix would have been to replace the forward slashes with backslashes. However, based on the [Windows documentation](https://learn.microsoft.com/en-us/windows/win32/fileio/maximum-file-path-limitation?tabs=registry), using a manifest file to make the app long path aware in conjonction with enabling the long path registry on the machine looks like the preferred approach. That way, multiple functions from the Windows API will no longer be restricted by the MAX_PATH length. Note that there is a Qt reported bug specifically for drag and drop of single files with a long path names. This fixes only drag and dropping of folders, import importing files from `File > Open`, and launching RV through the terminal with a file with a long path name. Testing drag and dropping of folders, importing files from `File > Open`, and launching RV through the terminal with a file with a long path name. **BEFORE** https://github.com/user-attachments/assets/80246ff9-b3a8-45b3-b7e3-e8e78f6e8e87 **AFTER** https://github.com/user-attachments/assets/4cda2fec-f44a-4d3f-8bf5-aa28d9a7dc37 Signed-off-by: Éloïse Brosseau <eloise.brosseau@autodesk.com> Signed-off-by: Bernard Laberge <bernard.laberge@autodesk.com>
eloisebrosseau
approved these changes
May 6, 2026
cedrik-fuoco-adsk
approved these changes
May 6, 2026
f45c424
into
AcademySoftwareFoundation:RB-3.1.X-VFX2024
21 of 23 checks passed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This is a cherry-pick: c8e0eb2
fix: SG-35913: Fix importing files with long path names on Windows
Summarize your change.
Replace
fileExistsWithLongPathSupportwith a manifest file enablinglongPathAware.Describe the reason for the change.
RV was failing to load media files with long path names even with the fix from
fileExistsWithLongPathSupport(). In this function, a prefix was added in front of the file path known by RV to make it a long path. However, the path contained forward slashes, but the extended path prefix is expecting backslashes. This was causing RV to not recognize long path names. A simple fix would have been to replace the forward slashes with backslashes. However, based on the Windows documentation, using a manifest file to make the app long path aware in conjonction with enabling the long path registry on the machine looks like the preferred approach. That way, multiple functions from the Windows API will no longer be restricted by the MAX_PATH length.Note that there is a Qt reported bug specifically for drag and drop of single files with a long path names. This fixes only drag and dropping of folders, import importing files from
File > Open, and launching RV through the terminal with a file with a long path name.Describe what you have tested and on which operating system
Testing drag and dropping of folders, importing files from
File > Open, and launching RV through the terminal with a file with a long path name.If possible, provide screenshots.
BEFORE
https://github.com/user-attachments/assets/80246ff9-b3a8-45b3-b7e3-e8e78f6e8e87
AFTER
https://github.com/user-attachments/assets/4cda2fec-f44a-4d3f-8bf5-aa28d9a7dc37