Suppress Maya's logging output (not stdout)

45 views
Skip to first unread message

Matteo Di Lena

unread,
Jan 27, 2025, 7:28:33 AMJan 27
to Python Programming for Autodesk Maya
Hi all!

I've been trying to find ways to suppress outputs of certain commands - such as blendShape, undo - without success, so I was wondering if anyone ever managed to get that working. I can pretty much shut everything inside the script editor by redirecting `sys.stdout` to `StringIO()`, but those things mentioned above will just stay around and pollute the output.

Thanks for any help!

Matteo

Ravi Jagannadhan

unread,
Jan 27, 2025, 8:58:28 AMJan 27
to python_in...@googlegroups.com
What about redirecting stderr as well?

“There are no dumb questions” - Carl Sagan

From: python_in...@googlegroups.com <python_in...@googlegroups.com> on behalf of Matteo Di Lena <dilena...@gmail.com>
Sent: Monday, January 27, 2025 4:28:33 AM
To: Python Programming for Autodesk Maya <python_in...@googlegroups.com>
Subject: [Maya-Python] Suppress Maya's logging output (not stdout)
 
--
You received this message because you are subscribed to the Google Groups "Python Programming for Autodesk Maya" group.
To unsubscribe from this group and stop receiving emails from it, send an email to python_inside_m...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/python_inside_maya/168dc9e3-c048-4ff6-9a61-f36fea74c657n%40googlegroups.com.

Matteo Di Lena

unread,
Jan 27, 2025, 9:15:58 AMJan 27
to Python Programming for Autodesk Maya
Yeah, I tried redirecting everything just to make sure I wasn't missing a thing: stdin, stdout, stderr, even __stdin__, __stdout__, __stderr__, even though I knew the dunder methods were reserved to the actual console output.
Reply all
Reply to author
Forward
0 new messages