code: def _replace_scalars_in_args(self, args):
          
          _check_type('args', args, list)
          new_args = []
          for arg in args:
              if isinstance(arg, list):
                  to_append = self._replace_scalars_in_args(arg)
              elif isinstance(arg, dict):
                  to_append = self._replace_scalars_in_kwargs(arg)
              elif isinstance(arg, string_types):
                  to_append = self._replace_scalar(arg)
              else:
                  to_append = arg
              new_args.append(to_append)
          return new_args
docs: Replace scalars in arguments list