def run_grant_dataset_view_access(self,
                                      source_project,
                                      source_dataset,
                                      view_project,
                                      view_dataset,
                                      view_table):

        # we don't want to clobber any existing accesses, so we have to get
        # info on the dataset before we can add view access
        source_dataset_resource = self.service.datasets().get(projectId=source_project,
                                                              datasetId=source_dataset).execute()
        access = source_dataset_resource['access'] if 'access' in source_dataset_resource else []
        view_access = {'view': {'projectId': view_project,
                                'datasetId': view_dataset,
                                'tableId': view_table}}
        # check to see if the view we want to add already exists.
        if view_access not in access:
            logging.info('granting table %s:%s.%s authorized view access to %s:%s dataset.',
                         view_project, view_dataset, view_table,
                         source_project, source_dataset)
            access.append(view_access)
            return self.service.datasets().patch(projectId=source_project,
                                                 datasetId=source_dataset,
                                                 body={'access': access}).execute()
        else:
            # if view is already in access, do nothing.
            logging.info('table %s:%s.%s already has authorized view access to %s:%s dataset.',
                         view_project, view_dataset, view_table,
                         source_project, source_dataset)
            return source_dataset_resource
No unknown attributes.
dataset/ETHPy150Open airbnb/airflow/airflow/contrib/hooks/bigquery_hook.py/BigQueryBaseCursor.run_grant_dataset_view_access--crossover with--dataset/ETHPy150Open typesupply/woffTools/Lib/woffTools/test/test_validate.py/metadataAbstractElementUnknownAttributesTest2