MCPcopy Index your code
hub / github.com/RustPython/RustPython / skip

Method skip

Lib/wave.py:190–214  ·  view source on GitHub ↗

Skip the rest of the chunk. If you are not interested in the contents of the chunk, this method should be called so that the file points to the start of the next chunk.

(self)

Source from the content-addressed store, hash-verified

188 return data
189
190 def skip(self):
191 """Skip the rest of the chunk.
192 If you are not interested in the contents of the chunk,
193 this method should be called so that the file points to
194 the start of the next chunk.
195 """
196
197 if self.closed:
198 raise ValueError("I/O operation on closed file")
199 if self.seekable:
200 try:
201 n = self.chunksize - self.size_read
202 # maybe fix alignment
203 if self.align and (self.chunksize & 1):
204 n = n + 1
205 self.file.seek(n, 1)
206 self.size_read = self.size_read + n
207 return
208 except OSError:
209 pass
210 while self.size_read < self.chunksize:
211 n = min(8192, self.chunksize - self.size_read)
212 dummy = self.read(n)
213 if not dummy:
214 raise EOFError
215
216
217class Wave_read:

Callers 15

closeMethod · 0.95
initfpMethod · 0.45
skip_unless_internalhashFunction · 0.45
skipdecFunction · 0.45
test_dbm.pyFile · 0.45
test_connect_starttlsMethod · 0.45
UserListTestClass · 0.45
symlink_testFunction · 0.45
test_locks.pyFile · 0.45
writes_bytecode_filesFunction · 0.45

Calls 3

readMethod · 0.95
minFunction · 0.85
seekMethod · 0.45

Tested by 8

skip_unless_internalhashFunction · 0.36
skipdecFunction · 0.36
test_connect_starttlsMethod · 0.36
symlink_testFunction · 0.36
test_c_cleandocMethod · 0.36