File tree Expand file tree Collapse file tree 2 files changed +2
-6
lines changed
Expand file tree Collapse file tree 2 files changed +2
-6
lines changed Original file line number Diff line number Diff line change @@ -185,7 +185,6 @@ def __next__(self):
185185 # print and move on to next response byte
186186 print ("Unknown event type:" + chunk )
187187 continue
188-
189188
190189 # Check buffer size before writing to prevent unbounded memory consumption
191190 chunk_size = len (chunk ["PayloadPart" ]["Bytes" ])
@@ -195,7 +194,6 @@ def __next__(self):
195194 f"Line buffer exceeded maximum size of { self .MAX_BUFFER_SIZE } bytes. "
196195 f"No newline found in stream."
197196 )
198-
199-
197+
200198 self .buffer .seek (0 , io .SEEK_END )
201199 self .buffer .write (chunk ["PayloadPart" ]["Bytes" ])
Original file line number Diff line number Diff line change @@ -137,7 +137,6 @@ def __init__(self, root_path):
137137 super (LocalFileDataSource , self ).__init__ ()
138138
139139 self .root_path = os .path .abspath (root_path )
140-
141140
142141 # Validate that the path is not in restricted locations
143142 for restricted_path in self .RESTRICTED_PATHS :
@@ -146,8 +145,7 @@ def __init__(self, root_path):
146145 f"Local Mode does not support mounting from restricted system paths. "
147146 f"Got: { root_path } "
148147 )
149-
150-
148+
151149 if not os .path .exists (self .root_path ):
152150 raise RuntimeError ("Invalid data source: %s does not exist." % self .root_path )
153151
You can’t perform that action at this time.
0 commit comments