Skip to content

Commit

Permalink
allow_param_shape_none
Browse files Browse the repository at this point in the history
  • Loading branch information
robfalck committed Aug 24, 2023
1 parent b5473be commit c5936c1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions dymos/phase/options.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import numpy as np

import openmdao.api as om
from ..utils.misc import _unspecified
from ..utils.misc import _unspecified, _none_or_unspecified


class ControlOptionsDictionary(om.OptionsDictionary):
Expand Down Expand Up @@ -224,7 +224,7 @@ def check_valid_shape(name, value):
Shape to check, should be a Iterable, Number, list, or tuple.
"""
if name == 'shape':
if value is not _unspecified and not isinstance(value, (Iterable, Number, list, tuple)):
if value not in _none_or_unspecified and not isinstance(value, (Iterable, Number, list, tuple)):
raise ValueError(f"Option '{name}' with value {value} is not valid.")


Expand Down

0 comments on commit c5936c1

Please sign in to comment.