MCPcopy
hub / github.com/dask/dask / test_errors

Function test_errors

dask/bag/tests/test_text.py:128–135  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

126
127
128def test_errors():
129 with filetexts({".test.foo": b"Jos\xe9\nAlice"}, mode="b"):
130 with pytest.raises(UnicodeDecodeError):
131 read_text(".test.foo", encoding="ascii").compute()
132
133 result = read_text(".test.foo", encoding="ascii", errors="ignore")
134 result = result.compute(scheduler="sync")
135 assert result == ["Jos\n", "Alice"]
136
137
138def test_complex_delimiter():

Callers

nothing calls this directly

Calls 3

filetextsFunction · 0.90
read_textFunction · 0.90
computeMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…