ladybug-tools / honeybee-radiance-command

🐝 ⚡️ :abc: Honeybee wrapper around Radiance commands which is used by honeybee-radiance
https://www.ladybug.tools/honeybee-radiance-command/docs/
GNU Affero General Public License v3.0
0 stars 6 forks source link

Parsing options from a string does not result in proper assignment in case of joined options. #222

Closed ghost closed 2 years ago

ghost commented 2 years ago

If the option contains a joined string option like the case below,

def test_from_string():
    options=RmtxopOptions()
    options.update_from_string('-fa -v')
    assert options.v==True
    assert options.f=='a'

The final test assert options.f=='a' fails. I guess this is because the parsing is not refined enough to figure out which options are string joined.

ghost commented 2 years ago

Update: I guess this can be fixed if one overrides the method from the OptionsCollection class. Haven't done that yet because I am wondering if this problem exists in other classes as well.

mostaphaRoudsari commented 2 years ago

Interesting! It actually tries to work with joined cases too: https://github.com/ladybug-tools/honeybee-radiance-command/blob/231de913d0ad2f743bf0f169d3104a98bcee7f50/honeybee_radiance_command/options/optionbase.py#L445-L452

github-actions[bot] commented 2 years ago

:tada: This issue has been resolved in version 1.20.1 :tada:

The release is available on:

Your semantic-release bot :package::rocket: