regions icon indicating copy to clipboard operation
regions copied to clipboard

visual should validate keys/values

Open astrofrog opened this issue 5 years ago • 3 comments

Currently, the .visual property is just a free-form dictionary which allows things such as:

region.visual['banana'] = 'apple'

We should make sure we validate the keys/values for this dictionary and make it easy for users to find out the keys that can be set (perhaps by setting some sensible defaults)

astrofrog avatar Jul 23 '20 09:07 astrofrog

Ideally visual should maybe even be a Visual class with property-based access (we could keep dict-like access for a while then deprecate it)

astrofrog avatar Jul 23 '20 09:07 astrofrog

:+1: but I want maximal easter eggs in this.

keflavich avatar Jul 23 '20 11:07 keflavich

Changing .visual to a dataclass might make sense as well...

adonath avatar Jul 19 '24 20:07 adonath