Hyphenated command doesn't prompt options (_-SaveSmall)


I’m having a problem with the “_-SaveSmall” command.
As I understand, it should prompt options, notably “Version”. In my case, it does not.

The goal here is to specify a Rhino file version to the “_-SaveSmall” command, in order to preserve the version in which the file was saved.
It is to be included in a Python batch script as:

import rhinoscriptsyntax as rs
file_rh_version = rs.ReadFileVersion()
savesmall = "_-SaveSmall _Version={} _Enter".format(file_rh_version)

@piac This method looks bugish, allways returns -1
It works with RhinoScript(rvb)

Interesting point, I also get the same result if I use RhinoCommon classes directly:

>>> import Rhino
>>> Rhino.RhinoDoc.ReadFileVersion(Rhino.RhinoDoc.OpenDocuments()[0])

You can use the -SaveAs command instead, and ReadArchiveVersion:

import Rhino
import rhinoscriptsyntax as rs
file_path = rs.DocumentPath()
file_name = rs.DocumentName()
file_rh_version = Rhino.FileIO.File3dm.ReadArchiveVersion(file_path + file_name)
file_rh_major_version = int(str(file_rh_version)[0])
savesmall = "_-SaveAs _SaveSmall=Yes _Version={} _Enter".format(file_rh_major_version)

And some bugtrack items: https://mcneel.myjetbrains.com/youtrack/issue/RH-66909, https://mcneel.myjetbrains.com/youtrack/issue/RH-66912

I’ve just tried what you suggested but to no avail (see screenshot).
The “_SaveSmall=Yes” argument is passed as the file path.

That’s strange, it’s a localization issue maybe? Can your try this command instead:

savesmall = "_-SaveAs _SaveSmall=_Yes _Version={} _Enter".format(file_rh_major_version)

It seems to be working as intended.
Thanks a lot!