fix setting attributes on a context