code: def check_required_aesthetics(required, present, name):
      missing_aes = set(required) - set(present)
  
      if missing_aes:
          msg = "{} requires the following missing aesthetics: {}"
          raise PlotnineError(msg.format(name, ", ".join(missing_aes)))
  
imports: from __future__ import annotations
  import inspect
  import itertools
  import warnings
  from collections import defaultdict
  from collections.abc import Iterable, Sequence
  from contextlib import suppress
  from typing import TYPE_CHECKING, cast, overload
  from warnings import warn
  import numpy
  import pandas
  from pandas.core.groupby import DataFrameGroupBy
  from ..exceptions import PlotnineError, PlotnineWarning
  from ..mapping import aes
label_desc: Use image node_id 11 for calling a global function with example usage: check_required_aesthetics(required, present, name) without return types