Skip to content

Should we have a 'silent' cell magic? #16

@ideabucket

Description

@ideabucket

I was thinking about #4 again in light of PR #15 and trying to work out when the echo-all behaviour is most annoying. For me, it's usually when I want to avoid the screen filling up with a bunch of echoed commands that have little or no output. For example, if I'm putting together an etable it looks something like this:

quietly regress…
estimates store…

quietly regress…
estimates store…

…

etable…

Or in a setup block—since pystata doesn't pick up profile.do, every notebook I make starts with:

version 17
set varabbrev off
global data_root…
…

and other throat-clearing.

So I was wondering: what if we just added a cell magic, e.g. *%silent, that tells the kernel not to print the output of that particular cell unless an exception is thrown? I'm happy to take a crack at implementing this but I thought I'd put it up for discussion first.

@hugetim, would this be any good for your use case?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions