From what I can tell, the version fields path_to_frames
and path_to_movie
require absolute paths, which mean they will work for either PC or Mac, but cannot resolve to both. Am I missing something? Is there a way to have RV or Create properly resolve the root path based on OS, the way the rest of shotgun works? I’d like to set a single path and be able to review versions from the path_to_frames
location from either PC or Mac.
Hey, I found the answer! The below link describes how to set up environment variables on each machine using RV (specifically the RV_OS_PATH section). This will allow RV to dynamically update the path depending on the OS.
I do wonder if this is the correct solution at this point. It works fine, but does require new review machines to need env variable updates. Any chance the path update can happen on the Shotgun side, based on the root paths (as toolkit paths do)? This would eliminate the need to update each computer.
Thanks.
Hi @stavernia!
I’m not sure for RV, but on Shotgun Create, there’s special logic that read theses fields and try to replace the beginning of the path if it matches one of your local file storage entries.
Thanks @geffrak! That’s good news. Though after a quick check, Create does not pick up the local files if the absolute path is not exact. For example, on PC, Create does not swap \Volumes\Q1\projects
for Q:\projects
, though the Local File Storage paths are set up in Site Preferences.
At this point it seems this conversation should switch to the Create category. I have a few other buggy behaviors regarding Create and local file playback as well. I’ll consolidate and post there.
Hi @stavernia. Just taking a guess here, but is you Mac path set up with backslashes like in your example or with forward-slashes (ie /Volumes/Q1/projects)? Like @geffrak was saying, the path translation should work in Create, but it does need to be an exact match. Since Mac uses forward slashes as path delimiters, that could potentially be the issue.
Hi @stavernia! If changing the forward/backward slashes does not fix it, would you mind sharing an example of path_to_frames as well as the 3 values (or fake examples) of the Local File Storage in your SG site preferences (Linux/Mac/Windows)?
Thanks
Eric
Hey @desruie,
Our Local File Storage paths:
I was getting some pretty inconsistent behavior. After some digging it seems to be a caching issue. It seems that if i first look at a version on a PC in Create, if the path is a PC path (the correct path as-is), then it caches this, and even if i change path_to_frames later, it stays correctly pathed. Even if I give a totally incorrect path_to_frames, Shotgun Create apparently doesn’t check that field after first caching it, even when it is closed and re-opened. I’m not sure how to reset that cache.
This made it quite difficult to test editing the path_to_frames field. However, I don’t believe it works with either of the following path_to_frames formats on a PC:
Indeed, path translation rules are obtained when Shotgun Create connects to the site and not fetched everytime it consumes a path, so changing it on the server side does not propagate to Shotgun Create. You need to disconnect/reconnect or exit/start the app.
My cache isn’t refreshed after closing and opening Shotgun Create. Even after restarting my machine, Create still plays the correct frame sequence with the following incorrect path_to_frames:
/X/Q1/projects/lh/shots/e13/e13-sq01/e13-sq01-0010/comp/work/output/exr/lh_e13-sq01-0010_comp_v01_z02/lh_e13-sq01-0010_comp_v01_z02_%04d.exrrrr
Path translation rules affect other types of internal data. Those data can get persisted and reloaded when you exit/restart Shotgun Create. Try hitting F5 from Shotgun Create’s main menu and then retry visiting the version.
So, to recap, when you change the translation rules on the SG site, you need to exit Create and restart it to flush them from the cache, but also hit F5 to flush any data derived from those rules (ie.: translated paths).
I hope this helps.
Thanks. F5 works for the refresh in Create, so I can now pick up path_to_frames changes.
However, I still can’t get Create to translate a Mac path to a PC path using forward or backwards slashes.
To summarize:
Our Local File Storage paths:
Using the following two path_to_frames as examples:
Neither of these paths are translated in Create. And yes, the files are there and named correctly. Both of these paths work correctly in RV.
Any ideas?
Your config/paths seem fine indeed. Does it work if, on your P, you try to add a new Version in create and browse to the same path? Does the EXRs properly load?
Also, when it failes to resolve, what are the symptoms? Any interesting information in the shell/logs you could share?
Hey Steven,
On the RV side that RV_OS_PATH article is the way to go:
Please don’t use the PATHSWAP variable, or if you do, don’t mix and match PATHSWAP and OS_PATH variables. Results get pretty unpredictable.
Unfortunately RV doesn’t utilize the Shotgun pathing preferences, though we have a feature request for that! I’ll add you as an interested party on it.
Thanks,
Alexa
Cool, thanks Alexa!
Alexa,
Where do I set these variables in RV? I’ve been poking around looking for it but I’m not finding it.
TIA…
These are environment variables that you set in your OS, the method varies between OSes.
Thanks for the nudge. The “OS Dependent Path Conversion” rvpkg had me thinking that I would set it in the Mac app container. Thanks!
So I set my environment variables and when I request them in terminal (env) they show up but when I check out RV’s Environment Variables they do not exist. I’m missing a step here somewhere.
Also has anyone tried the “OS Dependent Path Conversion” rvpkg? I enabled it and then updated the os_dependent_path_conversion_mode.py with the appropriate prefixes but it doesn’t work as well. I’m just completely failing here.
Updated link to RV_OS_PATH documentation:
https://help.autodesk.com/view/SGSUB/ENU/?guid=SG_RV_rv_manuals_rv_user_manual_rv_user_manual_chapter_a_html