Skip to content
This repository was archived by the owner on Mar 6, 2026. It is now read-only.

Commit 535aba6

Browse files
authored
Add templates for flake8, coveragerc, noxfile, and black. (#6642)
1 parent 9d99c54 commit 535aba6

9 files changed

Lines changed: 195 additions & 189 deletions

File tree

.coveragerc

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,3 +11,6 @@ exclude_lines =
1111
def __repr__
1212
# Ignore abstract methods
1313
raise NotImplementedError
14+
omit =
15+
*/gapic/*.py
16+
*/proto/*.py

.flake8

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
[flake8]
2+
ignore = E203, E266, E501, W503
23
exclude =
34
# Exclude generated code.
45
**/proto/**

google/cloud/bigquery/dataset.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -98,9 +98,9 @@ def __eq__(self, other):
9898
if not isinstance(other, AccessEntry):
9999
return NotImplemented
100100
return (
101-
self.role == other.role and
102-
self.entity_type == other.entity_type and
103-
self.entity_id == other.entity_id)
101+
self.role == other.role
102+
and self.entity_type == other.entity_type
103+
and self.entity_id == other.entity_id)
104104

105105
def __ne__(self, other):
106106
return not self == other
@@ -531,8 +531,8 @@ def from_api_repr(cls, resource):
531531
google.cloud.bigquery.dataset.Dataset:
532532
Dataset parsed from ``resource``.
533533
"""
534-
if ('datasetReference' not in resource or
535-
'datasetId' not in resource['datasetReference']):
534+
if ('datasetReference' not in resource
535+
or 'datasetId' not in resource['datasetReference']):
536536
raise KeyError('Resource lacks required identity information:'
537537
'["datasetReference"]["datasetId"]')
538538
project_id = resource['datasetReference']['projectId']

0 commit comments

Comments
 (0)