Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-16-2025 06:31 AM
Hello @halox6000,
You could temporarily redirect console output to a null device for these write operations.
Try this out:
@contextlib.contextmanager
def silence_dbutils():
with contextlib.redirect_stdout(io.StringIO()):
yield
# Usage in your code
with silence_dbutils():
dbutils.fs.put("/path/to/your/file.txt", "Your content here", True)