MCPcopy
hub / github.com/marimo-team/marimo / write_bytes

Method write_bytes

marimo/_runtime/watch/_file.py:96–104  ·  view source on GitHub ↗

Write the file as bytes.

(self, value: bytes)

Source from the content-addressed store, hash-verified

94 return data
95
96 def write_bytes(self, value: bytes) -> int:
97 """Write the file as bytes."""
98 response = self._value.write_bytes(value)
99 data = self._value.read_bytes()
100 write_side_effect(f"write_bytes:{data!r}")
101 with self._debounce_lock:
102 self._debounced = True
103 self._set_value(self._value)
104 return response
105
106 def __repr__(self) -> str:
107 """Return a string representation of the file state."""

Callers

nothing calls this directly

Calls 2

write_side_effectFunction · 0.90
read_bytesMethod · 0.45

Tested by

no test coverage detected