RV Scripting - Setting preferences doesnt apply in current RV Session

I’m making a very simple package that is setting RV Preferences for my users (Like Project preferences).

The issue I’m having at the moment is those preferences are being applied only when RV is closed. So only the next session will have the new preferences.

For example, I want to set the default fps to 30. My package is running something like rv.commands.writeSettings("General", "fps", 30)

When opening RV for the first time, the default FPS is set to 30 from the Preference Window. My ~/.config/TweakSoftware/RV.conf file does show fps=30 under [General]. But when I load an image sequence, its being loaded as 24 fps.

If I close RV, re-open RV and load the same image sequence, only then my image sequence is loaded as 30 fps as expected. Am I missing something? My goal is to set RV preferences, and making these changes live.

Here a very simple version of my package

from rv import commands, rvtypes

class PrefStudio(rvtypes.MinorMode):
    FPS = 30

    def __init__(self):

        super(rvtypes.MinorMode, self).__init__()

        self.init("PrefStudio", None, None)

        commands.writeSettings("General", "fps", self.FPS)

def createMode():
    return PrefStudio()

Hi on newer builds of OpenRV there is a new commands.loadSettingsIntoOptions()

this came with this PR on OpenRV github repo

with this you can set the setting and then call this command.

Unfortunately I don’t think there is another way in older RV versions except restarting.

Cheers, Mirco

We are still using RV 2023 because since 2024, there is a regression when loading Medias from un-authenticated RV sessions that isn’t fixed yet. RV 2025.0.0 Release is available! - #2 by sbissonnette

As someone not familiar with OpenRV and used only RV, what would be the best move forward?
What are the key difference between RV and OpenRV? I believe OpenRV needs to be built, but what about SG integrations plugins that comes with RV? And NonFree Codecs?

afaik changes from OpenRV will also be reflected with new RV builds that you get from Autodesk.

So chances are that (if it’s not already available in 2025.0.0) with the fix of the issue you described could also come this new command.
And if you are using shotgrid and have enough RV licenses I would probably recommend to stick to that.

About OpenRV, yes you need to build it yourself (although you can also find prebuild binaries from other users for some platforms, some with codecs enabled).
You can use the same shotgrid plugins in OpenRV, you would just need to add them from the regular RV version to OpenRV plugin path.

So I won’t be able to benefit from this new command since my other issue has not been fixed yet.

Its great news that this new command is available, but until then I will need to find a workaround on RV 2023.

I think my workaround would be to set the FPS through an Event instead of playing with the RV Preference… Might use source-group-complete or something similar

Yes I would suggest doing source-group-complete event and then setting the fps per source.

Another option is starting rv with the -fps flag then you could start it for different projects with different -fps flags

e.g. rv -fps 30

that sets the default fps immediately, but you need to do it on application call

Thank you for all the quick answers!

Well doing commands.setFPS() does nothing during the source-group-complete event…

I can confirm the event go through, just that the command itself doesnt set the FPS during the Event.
Doing the same command from the Python Console does change the FPS

It looks like source-group-complete event is too soon to set the FPS.

Using the new-node event seems to set the fps properly. Now I just need to figure out which event would be the more optimized to set the FPS properly