nsot icon indicating copy to clipboard operation
nsot copied to clipboard

Implement default values for Attributes

Open coxley opened this issue 10 years ago • 3 comments

Somewhat similar mindset as #84, having attribute defaults is pretty important for required attributes. May have a handful and attributes that are required, but may have a sane default that should be used before yelling at the user.

coxley avatar Sep 12 '15 23:09 coxley

First of all, I like this idea. I feel like this could be complicated to implement, but only because if multi=True is set on an Attribute, then it behaves as a list type, so the default value must also be a list type if multi=True.

jathanism avatar Oct 30 '15 05:10 jathanism

Could the check that judges if value is compatible with multi not be re-used for default_value?

coxley avatar Oct 30 '15 07:10 coxley

Yeah, probably.

jathanism avatar Oct 30 '15 16:10 jathanism