Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

subprocess.Popen() should allow capturing output and sending it to stdout and stderr #91378

Open
pprindeville mannequin opened this issue Apr 4, 2022 · 1 comment
Open
Labels
stdlib Python modules in the Lib dir topic-subprocess Subprocess issues. type-feature A feature request or enhancement

Comments

@pprindeville
Copy link
Mannequin

pprindeville mannequin commented Apr 4, 2022

BPO 47222
Nosy @gpshead, @pprindeville
PRs
  • gh-91378: Allow subprocess pass-thru with stdout/stderr capture #32344
  • Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

    Show more details

    GitHub fields:

    assignee = None
    closed_at = None
    created_at = <Date 2022-04-04.22:52:49.296>
    labels = ['type-feature', 'library', '3.11']
    title = 'subprocess.Popen() should allow capturing output and sending it to stdout and stderr'
    updated_at = <Date 2022-04-05.21:08:52.185>
    user = 'https://github.com/pprindeville'

    bugs.python.org fields:

    activity = <Date 2022-04-05.21:08:52.185>
    actor = 'pprindeville'
    assignee = 'none'
    closed = False
    closed_date = None
    closer = None
    components = ['Library (Lib)']
    creation = <Date 2022-04-04.22:52:49.296>
    creator = 'pprindeville'
    dependencies = []
    files = []
    hgrepos = []
    issue_num = 47222
    keywords = ['patch']
    message_count = 1.0
    messages = ['416703']
    nosy_count = 2.0
    nosy_names = ['gregory.p.smith', 'pprindeville']
    pr_nums = ['32344']
    priority = 'normal'
    resolution = None
    stage = 'patch review'
    status = 'open'
    superseder = None
    type = 'enhancement'
    url = 'https://bugs.python.org/issue47222'
    versions = ['Python 3.11']

    @pprindeville
    Copy link
    Mannequin Author

    pprindeville mannequin commented Apr 4, 2022

    I'd like to see handlers exposes for the stdout and stderr pipe-reading threads so that I could customize what's done with the data as it's read.

    I might, for instance, want to:

    (1) accumulate it into a buffer;
    (2) copy it onto sys.stdout or sys.stderr, respectively;
    (3) send it to a logging object;

    or some combination of the above, possibly all of them.

    @pprindeville pprindeville mannequin added 3.11 only security fixes stdlib Python modules in the Lib dir type-feature A feature request or enhancement labels Apr 4, 2022
    @ezio-melotti ezio-melotti transferred this issue from another repository Apr 10, 2022
    @gpshead gpshead removed the 3.11 only security fixes label Nov 23, 2022
    @vstinner vstinner added the topic-subprocess Subprocess issues. label Jul 8, 2024
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Labels
    stdlib Python modules in the Lib dir topic-subprocess Subprocess issues. type-feature A feature request or enhancement
    Projects
    None yet
    Development

    No branches or pull requests

    2 participants