Closed DavidGoldwasser closed 4 years ago
Here is console log from SketchUp. I manually made some model objects after making a new model to confirm openstudio loaded correctly, then tried to use PathWatcher
OS:Version,
{13227370-f2d2-4f6d-8b16-50846f1b0725}, !- Handle
3.0.0-rc1; !- Version Identifier
OS:Building,
{808cf52c-483d-47a0-ba08-6994ddce4f3e}, !- Handle
This is a test, !- Name
, !- Building Sector Type
, !- North Axis {deg}
, !- Nominal Floor to Floor Height {m}
, !- Space Type Name
, !- Default Construction Set Name
; !- Default Schedule Set Name
OS:Site,
{48e1a3ec-a9c6-4ffb-83bb-aa176151a2d0}, !- Handle
Site 1, !- Name
, !- Latitude {deg}
, !- Longitude {deg}
, !- Time Zone {hr}
, !- Elevation {m}
; !- Terrain
OS:Space,
{fa805f67-ee31-4825-bfca-a6dd9c49650e}, !- Handle
Space 1; !- Name
> puts OpenStudio::Model::Model
OpenStudio::Model::Model
> puts OpenStudio::Model
OpenStudio::Model
> puts OpenStudio::PathWatcher
Error: #<NameError: uninitialized constant OpenStudio::PathWatcher>
<main>:in `<main>'
SketchUp:1:in `eval'
> puts OpenStudio::Modeleditor
Error: #<NameError: uninitialized constant OpenStudio::Modeleditor>
<main>:in `<main>'
SketchUp:1:in `eval'
@DavidGoldwasser is that with Openstudio installer or with OpenStudioApplication installer?
@jmarrec I was able to reproduce the error with the CLI in both installers.
I see the problem. model_editor
was moved to the OpenStudioApplication project, and it's probably not linking correctly to the openstudio.so (generated from this OpenStudio
project) so it's not available...
Seems like @macumber has been working on something similar https://github.com/NREL/OpenStudioApplication/pull/50
Those path watcher tests should be moved out of the open studio repository, they depend on a Qt functionality so are only available in the os app repo. You would have to require openstudio_modeleditor.rb to get them to work.
@macumber that is good to know. So someone can't just install SketchUp plugin and point it to core OpenStudio, then need to have the OpenStudio application installed. In some ways the Plugin then is kind of a sub-application to the OpenStudio Application.
Moved to NREL/OpenStudioApplication via https://github.com/NREL/OpenStudio/pull/3808
The test below runs successfully in 2.9, but not in 3.0. In both cases I'm running the script by calling
openstudio PathWatcher_Test.rb
and using the ruby that comes with the CLI.https://github.com/NREL/OpenStudio/blob/develop3/ruby/test/PathWatcher_Test.rb#L34
Here is the log from OpenStudio-3.0.0-rc1
Here is the successful run from 2.9
I didn't identify this through the test, but rather through trying to setup the stand alone SketchUp plugin for 3.0.0-rc1. For reference I can load OpenStudio in SketchUp's ruby, and access and use model methods, so I feel confident should be able to get the plugin working.