Skip to content

Commit

Permalink
[BEAM-13051] Fixed no-value-for-parameter warning for missing default…
Browse files Browse the repository at this point in the history
… values
  • Loading branch information
roger-mike committed Jan 21, 2022
1 parent 12253cb commit 6000dc1
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 3 deletions.
8 changes: 7 additions & 1 deletion sdks/python/apache_beam/io/avroio_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,13 @@ def tearDown(self):
os.remove(path)
self._temp_files = []

def _write_data(self, directory, prefix, codec, count, sync_interval):
def _write_data(
self,
directory=None,
prefix=None,
codec=None,
count=None,
sync_interval=None):
raise NotImplementedError

def _write_pattern(self, num_files, return_filenames=False):
Expand Down
2 changes: 1 addition & 1 deletion sdks/python/apache_beam/io/filesystem.py
Original file line number Diff line number Diff line change
Expand Up @@ -257,7 +257,7 @@ def _read_from_internal_buffer(self, read_fn):
self._read_buffer.seek(0, os.SEEK_END) # Allow future writes.
return result

def read(self, num_bytes):
def read(self, num_bytes=None):
# type: (int) -> bytes
if not self._decompressor:
raise ValueError('decompressor not initialized')
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -216,7 +216,7 @@ def __init__(
'InfluxDB')
self.filters = filters

def publish_metrics(self, result, extra_metrics: dict):
def publish_metrics(self, result, extra_metrics: dict = None):
metric_id = uuid.uuid4().hex
metrics = result.metrics().query(self.filters)

Expand Down

0 comments on commit 6000dc1

Please sign in to comment.