code: def context_exists(self, name):
          
          contexts = self.data['contexts']
          for context in contexts:
              if context['name'] == name:
                  return True
          return False
docs: Check if a given context exists.