an0malaus opened this issue on Aug 30, 2019 ยท 7 posts
an0malaus posted Fri, 30 August 2019 at 7:54 AM
I'm looking for a way to bypass a current Poser bug, whereby Poser overwrites the LibraryPrefs.xml file, thus erasing any changes a python script run from within Poser might have made. There seems to be an opinion that this may be a Mac only bug, and that Windows Poser will merge any changes it finds in the file with the list of known runtimes it holds in memory.
In any case, MacOS Poser is overwriting any modifications made which destroys the point of the script.
I am wondering if it might be feasible to have Poser launch a shell command, and have that run a python script external to Poser, which can monitor the status of Poser's process, and then restore changes to the LibraryPrefs.xml file once the Poser process terminates.
The only reason Poser needs to terminate, is that there is currently no mechanism by which a python script from within Poser can tell poser to reload its LibraryPrefs.xml. If there were (and a request has been made for such but is unlikely to be implemented any time soon), then a Poser restart would be redundant. The whole point of the script is to save the user from having to create a new Runtime hierarchy and manually add that to Poser's list of Library runtimes.
It's possible that there would be no need for the remote script to communicate directly with the internal script which launches it. It just needs to find a new candidate LibraryPrefs.xml, continue to execute while waiting for the user to manually shutdown Poser (though the launch script could conceivably automate a Quit), detect the Poser process termination and overwrite the overwritten LibraryPrefs.xml with the replacement candidate.
It has occurred to me that there may be specific issues which would prevent any shell launched within Poser from remaining active once Poser terminates, but such things are possible at the Unix shell level.
Verbosity: Profusely promulgating Graham's number epics of complete and utter verbiage by the metric monkey barrel.