code: def dry_run(self, context=None, query_params=None):
      
  
      context = context or google.datalab.Context.default()
      api = _api.Api(context)
      try:
        query_result = api.jobs_insert_query(self.sql, dry_run=True,
                                             table_definitions=self.data_sources,
                                             query_params=query_params)
      except Exception as e:
        raise e
      return query_result['statistics']['query']
docs: Dry run a query, to check the validity of the query and return some useful statistics.
  
      Args:
        context: an optional Context object providing project_id and credentials. If a specific
            project id or credentials are unspecified, the default ones configured at the global
            level are used.
        query_params: a dictionary containing query parameter types and values, passed to BigQuery.
  
      Returns:
        A dict with 'cacheHit' and 'totalBytesProcessed' fields.
      Raises:
        An exception if the query was malformed.