SMS dit: Disorder and defects in functional molecular frameworks